The patch titled Subject: watchdog: avoid changing cpumask on unregistered smpboot thread has been removed from the -mm tree. Its filename was watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz-fix-2.patch This patch was dropped because it was folded into watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz.patch ------------------------------------------------------ From: Chris Metcalf <cmetcalf@xxxxxxxxxx> Subject: watchdog: avoid changing cpumask on unregistered smpboot thread Also, add a line documenting that you are not supposed to try to do this. The risk, as Ulrich Obergfell pointed out, is that if registration fails due to ENOMEM, there may be no valid cpumask field in the smpboot object, so attempting to modify it in smpboot_update_cpumask_percpu_thread() would crash. In the case of the watchdog this change is fine because we will reset the smpboot cpumask as soon as we successfully manage to register the smpboot thread. Signed-off-by: Chris Metcalf <cmetcalf@xxxxxxxxxx> Cc: Ulrich Obergfell <uobergfe@xxxxxxxxxx> Cc: Don Zickus <dzickus@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- kernel/smpboot.c | 1 + kernel/watchdog.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff -puN kernel/smpboot.c~watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz-fix-2 kernel/smpboot.c --- a/kernel/smpboot.c~watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz-fix-2 +++ a/kernel/smpboot.c @@ -338,6 +338,7 @@ EXPORT_SYMBOL_GPL(smpboot_unregister_per * * The cpumask field in the smp_hotplug_thread must not be updated directly * by the client, but only by calling this function. + * This function can only be called on a registered smp_hotplug_thread. */ int smpboot_update_cpumask_percpu_thread(struct smp_hotplug_thread *plug_thread, const struct cpumask *new) diff -puN kernel/watchdog.c~watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz-fix-2 kernel/watchdog.c --- a/kernel/watchdog.c~watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz-fix-2 +++ a/kernel/watchdog.c @@ -909,7 +909,7 @@ int proc_watchdog_cpumask(struct ctl_tab cpumask_and(&watchdog_cpumask, &watchdog_cpumask, cpu_possible_mask); - if (watchdog_enabled && watchdog_thresh) { + if (watchdog_running) { /* * Failure would be due to being unable to allocate * a temporary cpumask, so we are likely not in a _ Patches currently in -mm which might be from cmetcalf@xxxxxxxxxx are origin.patch smpboot-allow-excluding-cpus-from-the-smpboot-threads.patch watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz.patch watchdog-add-watchdog_cpumask-sysctl-to-assist-nohz-fix-3.patch procfs-treat-parked-tasks-as-sleeping-for-task-state.patch mm-hugetlb-reduce-arch-dependent-code-about-huge_pmd_unshare.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html