File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change
1
+ /* SPDX-License-Identifier: GPL-2.0 */
2
+
3
+ #ifndef __ASM_CSKY_IRQ_WORK_H
4
+ #define __ASM_CSKY_IRQ_WORK_H
5
+
6
+ static inline bool arch_irq_work_has_interrupt (void )
7
+ {
8
+ return true;
9
+ }
10
+ extern void arch_irq_work_raise (void );
11
+ #endif /* __ASM_CSKY_IRQ_WORK_H */
Original file line number Diff line number Diff line change 12
12
#include <linux/delay.h>
13
13
#include <linux/err.h>
14
14
#include <linux/irq.h>
15
+ #include <linux/irq_work.h>
15
16
#include <linux/irqdomain.h>
16
17
#include <linux/of.h>
17
18
#include <linux/sched/task_stack.h>
@@ -35,6 +36,7 @@ enum ipi_message_type {
35
36
IPI_EMPTY ,
36
37
IPI_RESCHEDULE ,
37
38
IPI_CALL_FUNC ,
39
+ IPI_IRQ_WORK ,
38
40
IPI_MAX
39
41
};
40
42
@@ -53,6 +55,9 @@ static irqreturn_t handle_ipi(int irq, void *dev)
53
55
if (ops & (1 << IPI_CALL_FUNC ))
54
56
generic_smp_call_function_interrupt ();
55
57
58
+ if (ops & (1 << IPI_IRQ_WORK ))
59
+ irq_work_run ();
60
+
56
61
BUG_ON ((ops >> IPI_MAX ) != 0 );
57
62
}
58
63
@@ -108,6 +113,13 @@ void smp_send_reschedule(int cpu)
108
113
send_ipi_message (cpumask_of (cpu ), IPI_RESCHEDULE );
109
114
}
110
115
116
+ #ifdef CONFIG_IRQ_WORK
117
+ void arch_irq_work_raise (void )
118
+ {
119
+ send_ipi_message (cpumask_of (smp_processor_id ()), IPI_IRQ_WORK );
120
+ }
121
+ #endif
122
+
111
123
void __init smp_prepare_boot_cpu (void )
112
124
{
113
125
}
You can’t perform that action at this time.
0 commit comments