mirror of
https://github.com/torvalds/linux.git
synced 2026-03-08 01:04:41 +01:00
s390/irq/idle: Remove psw bits early
Remove wait, io, external interrupt bits early in do_io_irq()/do_ext_irq() when previous context was idle. This saves one conditional branch and is closer to the original old assembly code. Reviewed-by: Sven Schnelle <svens@linux.ibm.com> Signed-off-by: Heiko Carstens <hca@linux.ibm.com> Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
This commit is contained in:
parent
257c14e5a1
commit
d8b5cf9c63
1 changed files with 6 additions and 8 deletions
|
|
@ -147,8 +147,10 @@ void noinstr do_io_irq(struct pt_regs *regs)
|
|||
bool from_idle;
|
||||
|
||||
from_idle = test_and_clear_cpu_flag(CIF_ENABLED_WAIT);
|
||||
if (from_idle)
|
||||
if (from_idle) {
|
||||
update_timer_idle();
|
||||
regs->psw.mask &= ~(PSW_MASK_EXT | PSW_MASK_IO | PSW_MASK_WAIT);
|
||||
}
|
||||
|
||||
irq_enter_rcu();
|
||||
|
||||
|
|
@ -174,9 +176,6 @@ void noinstr do_io_irq(struct pt_regs *regs)
|
|||
|
||||
set_irq_regs(old_regs);
|
||||
irqentry_exit(regs, state);
|
||||
|
||||
if (from_idle)
|
||||
regs->psw.mask &= ~(PSW_MASK_EXT | PSW_MASK_IO | PSW_MASK_WAIT);
|
||||
}
|
||||
|
||||
void noinstr do_ext_irq(struct pt_regs *regs)
|
||||
|
|
@ -186,8 +185,10 @@ void noinstr do_ext_irq(struct pt_regs *regs)
|
|||
bool from_idle;
|
||||
|
||||
from_idle = test_and_clear_cpu_flag(CIF_ENABLED_WAIT);
|
||||
if (from_idle)
|
||||
if (from_idle) {
|
||||
update_timer_idle();
|
||||
regs->psw.mask &= ~(PSW_MASK_EXT | PSW_MASK_IO | PSW_MASK_WAIT);
|
||||
}
|
||||
|
||||
irq_enter_rcu();
|
||||
|
||||
|
|
@ -209,9 +210,6 @@ void noinstr do_ext_irq(struct pt_regs *regs)
|
|||
irq_exit_rcu();
|
||||
set_irq_regs(old_regs);
|
||||
irqentry_exit(regs, state);
|
||||
|
||||
if (from_idle)
|
||||
regs->psw.mask &= ~(PSW_MASK_EXT | PSW_MASK_IO | PSW_MASK_WAIT);
|
||||
}
|
||||
|
||||
static void show_msi_interrupt(struct seq_file *p, int irq)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue