mirror of
https://kernel.googlesource.com/pub/scm/linux/kernel/git/torvalds/linux
synced 2025-10-05 16:32:29 +10:00
irq: Call tick_irq_enter() inside HARDIRQ_OFFSET
Now that account_hardirq_enter() is called after HARDIRQ_OFFSET has been incremented, there is nothing left that prevents us from also moving tick_irq_enter() after HARDIRQ_OFFSET is incremented. The desired outcome is to remove the nasty hack that prevents softirqs from being raised through ksoftirqd instead of the hardirq bottom half. Also tick_irq_enter() then becomes appropriately covered by lockdep. Signed-off-by: Frederic Weisbecker <frederic@kernel.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/r/20201202115732.27827-6-frederic@kernel.org
This commit is contained in:
parent
d3759e7184
commit
d14ce74f1f
@ -377,16 +377,12 @@ restart:
|
|||||||
*/
|
*/
|
||||||
void irq_enter_rcu(void)
|
void irq_enter_rcu(void)
|
||||||
{
|
{
|
||||||
if (is_idle_task(current) && !in_interrupt()) {
|
__irq_enter_raw();
|
||||||
/*
|
|
||||||
* Prevent raise_softirq from needlessly waking up ksoftirqd
|
if (is_idle_task(current) && (irq_count() == HARDIRQ_OFFSET))
|
||||||
* here, as softirq will be serviced on return from interrupt.
|
|
||||||
*/
|
|
||||||
local_bh_disable();
|
|
||||||
tick_irq_enter();
|
tick_irq_enter();
|
||||||
_local_bh_enable();
|
|
||||||
}
|
account_hardirq_enter(current);
|
||||||
__irq_enter();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user