On Fri 2021-11-12 13:14:34, Zqiang wrote:
If the nohz_full is enabled, when update watchdog_mask, theI am not familiar with nozh_full code but this looks fine.
nohz_full cores should be ignored.
Signed-off-by: Zqiang <qiang.zhang1211@xxxxxxxxx>
---
kernel/watchdog.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/kernel/watchdog.c b/kernel/watchdog.c
index ad912511a0c0..3ef11a94783c 100644
--- a/kernel/watchdog.c
+++ b/kernel/watchdog.c
@@ -628,7 +628,9 @@ void lockup_detector_soft_poweroff(void)
static void proc_watchdog_update(void)
{
/* Remove impossible cpus to keep sysctl output clean. */
- cpumask_and(&watchdog_cpumask, &watchdog_cpumask, cpu_possible_mask);
+ cpumask_and(&watchdog_cpumask, &watchdog_cpumask,
housekeeping_cpumask(HK_FLAG_TIMER));
+ if (cpumask_empty(&watchdog_cpumask))But this looks looks wrong. Is there any reason for this?
+ return;
We need to stop the watchdog when it was running before.
I mean that lockup_detector_reconfigure() must be called anytime
when the mask has changed even when it became empty.
lockup_detector_reconfigure();Best Regards,
}
Petr