summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/irq_work.c11
-rw-r--r--kernel/smp.c1
2 files changed, 12 insertions, 0 deletions
diff --git a/kernel/irq_work.c b/kernel/irq_work.c
index 9f19c05c9962..73eabcbdcd50 100644
--- a/kernel/irq_work.c
+++ b/kernel/irq_work.c
@@ -263,6 +263,17 @@ void irq_work_run(void)
}
EXPORT_SYMBOL_GPL(irq_work_run);
+void irq_work_run_cpu(unsigned int cpu)
+{
+ if (WARN_ON_ONCE(!cpumask_test_cpu(cpu, cpu_dying_mask)))
+ return;
+
+ if (!IS_ENABLED(CONFIG_PREEMPT_RT))
+ return;
+
+ irq_work_run_list(per_cpu_ptr(&lazy_list, cpu));
+}
+
void irq_work_tick(void)
{
struct llist_head *raised = this_cpu_ptr(&raised_list);
diff --git a/kernel/smp.c b/kernel/smp.c
index b696bcc60c08..8f530a094c30 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -87,6 +87,7 @@ int smpcfd_dead_cpu(unsigned int cpu)
free_cpumask_var(cfd->cpumask);
free_cpumask_var(cfd->cpumask_ipi);
+ irq_work_run_cpu(cpu);
return 0;
}