Starting from commit 47b8ff194c1fd73d58dc ("entry: Explicitly flush
pending rcuog wakeup before last rescheduling point"), if
CONFIG_GENERIC_ENTRY is enabled, tick_nohz_user_enter_prepare() should
be called before returning to user.
As for now, CONFIG_GENERIC_ENTRY is not available on ARM, so this commit
will not change the vmlinux.
Signed-off-by: Xie Yuanbin <qq570070308@gmail.com>
---
arch/arm/kernel/entry.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/arm/kernel/entry.c b/arch/arm/kernel/entry.c
index 60e5c250da88..5de345e9146f 100644
--- a/arch/arm/kernel/entry.c
+++ b/arch/arm/kernel/entry.c
@@ -1,5 +1,6 @@
// SPDX-License-Identifier: GPL-2.0-only
#include <linux/linkage.h>
+#include <linux/tick.h>
#include <linux/rseq_entry.h>
#include <linux/irq-entry-common.h>
#include <linux/kstack_erase.h>
@@ -14,6 +15,8 @@
asmlinkage __section(".entry.text")
void arm_exit_to_user_mode_no_work_pending(void)
{
+ if (IS_ENABLED(CONFIG_GENERIC_ENTRY))
+ tick_nohz_user_enter_prepare();
rseq_irqentry_exit_to_user_mode();
exit_to_user_mode();
#ifdef CONFIG_KSTACK_ERASE
--
2.51.0