hc
2024-11-01 2f529f9b558ca1c1bd74be7437a84e4711743404
kernel/include/linux/kernel.h
....@@ -15,6 +15,7 @@
1515 #include <linux/typecheck.h>
1616 #include <linux/printk.h>
1717 #include <linux/build_bug.h>
18
+#include <asm-generic/irq_pipeline.h>
1819 #include <asm/byteorder.h>
1920 #include <asm/div64.h>
2021 #include <uapi/linux/kernel.h>
....@@ -195,9 +196,12 @@
195196
196197 #ifdef CONFIG_PREEMPT_VOLUNTARY
197198 extern int _cond_resched(void);
198
-# define might_resched() _cond_resched()
199
+# define might_resched() do { \
200
+ check_inband_stage(); \
201
+ _cond_resched(); \
202
+ } while (0)
199203 #else
200
-# define might_resched() do { } while (0)
204
+# define might_resched() check_inband_stage()
201205 #endif
202206
203207 #ifdef CONFIG_DEBUG_ATOMIC_SLEEP