summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHeiko Carstens <heiko.carstens@de.ibm.com>2007-02-05 21:17:16 +0100
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2007-02-05 21:17:16 +0100
commitc59d744bd8a0e283daf6726881e4c9aa4bd25261 (patch)
tree89c5b76c34555ad0883512d26aef21c11d7868f9
parent444f0e5489e7ac4bca5c4748d7d846c352a5cd03 (diff)
downloadop-kernel-dev-c59d744bd8a0e283daf6726881e4c9aa4bd25261.zip
op-kernel-dev-c59d744bd8a0e283daf6726881e4c9aa4bd25261.tar.gz
[S390] sclp: don't call local_bh_disable/_local_bh_enable if in_interrupt()
local_bh_disable/_local_bh_enable must not be called if in_irq() is true. Besides that if in_interrupt() is true bottom halves are disabled anyway. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
-rw-r--r--drivers/s390/char/sclp.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/s390/char/sclp.c b/drivers/s390/char/sclp.c
index 3457a9a..027cdc1 100644
--- a/drivers/s390/char/sclp.c
+++ b/drivers/s390/char/sclp.c
@@ -402,6 +402,7 @@ sclp_sync_wait(void)
unsigned long flags;
unsigned long cr0, cr0_sync;
u64 timeout;
+ int irq_context;
/* We'll be disabling timer interrupts, so we need a custom timeout
* mechanism */
@@ -414,7 +415,9 @@ sclp_sync_wait(void)
}
local_irq_save(flags);
/* Prevent bottom half from executing once we force interrupts open */
- local_bh_disable();
+ irq_context = in_interrupt();
+ if (!irq_context)
+ local_bh_disable();
/* Enable service-signal interruption, disable timer interrupts */
trace_hardirqs_on();
__ctl_store(cr0, 0, 0);
@@ -435,7 +438,8 @@ sclp_sync_wait(void)
}
local_irq_disable();
__ctl_load(cr0, 0, 0);
- _local_bh_enable();
+ if (!irq_context)
+ _local_bh_enable();
local_irq_restore(flags);
}
OpenPOWER on IntegriCloud