]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit - arch/powerpc/kernel/exceptions-64s.S
powerpc: Add code to handle soft-disabled doorbells on server
authorIan Munsie <imunsie@au1.ibm.com>
Wed, 14 Nov 2012 18:49:48 +0000 (18:49 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 10 Jan 2013 04:09:07 +0000 (15:09 +1100)
commitfe9e1d54e3ea2e5134d7aaa233441f9229326ef6
treeb8347ea44bef6ad8c8a615a26a9a8124745f50f3
parent919ca8681f48ce81848c76f0ed66edb1bb99209b
powerpc: Add code to handle soft-disabled doorbells on server

This patch adds the logic to properly handle doorbells that come in when
interrupts have been soft disabled and to replay them when interrupts
are re-enabled:

- masked_##_H##interrupt is modified to leave interrupts enabled when a
  doorbell has come in since doorbells are edge sensitive and as such
  won't be automatically re-raised.

- __check_irq_replay now tests if a doorbell happened on book3s, and
  returns either 0xe80 or 0xa00 depending on whether we are the
  hypervisor or not.

- restore_check_irq_replay now tests for the two possible server
  doorbell vector numbers to replay.

- __replay_interrupt also adds tests for the two server doorbell vector
  numbers, and is modified to use a compare instruction rather than an
  andi. on the single bit difference between 0x500 and 0x900.

The last two use a CPU feature section to avoid needlessly testing
against the hypervisor vector if it is not the hypervisor, and vice
versa.

Signed-off-by: Ian Munsie <imunsie@au1.ibm.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/kernel/entry_64.S
arch/powerpc/kernel/exceptions-64s.S
arch/powerpc/kernel/irq.c