[folded-merged] watchdog-delete-old-declarations-for-watchdog_softhardlockup_user_enabled-make-static.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The quilt patch titled
     Subject: watchdog: delete old declarations for watchdog_soft,hardlockup_user_enabled + make static
has been removed from the -mm tree.  Its filename was
     watchdog-delete-old-declarations-for-watchdog_softhardlockup_user_enabled-make-static.patch

This patch was dropped because it was folded into watchdog-hardlockup-rename-some-nmi-watchdog-constants-function.patch

------------------------------------------------------
From: Tom Rix <trix@xxxxxxxxxx>
Subject: watchdog: delete old declarations for watchdog_soft,hardlockup_user_enabled + make static
Date: Thu, 25 May 2023 16:28:32 -0700

smatch reports
kernel/watchdog.c:40:19: warning: symbol
  'watchdog_hardlockup_user_enabled' was not declared. Should it be static?
kernel/watchdog.c:41:19: warning: symbol
  'watchdog_softlockup_user_enabled' was not declared. Should it be static?

These variables are only used in their defining file, so they should
be static.

This problem showed up after the patch ("watchdog/hardlockup: rename some
"NMI watchdog" constants/function") because that rename missed the header
file.  That didn't cause any compile-time errors because, since commit
dd0693fdf054 ("watchdog: move watchdog sysctl interface to watchdog.c"),
nobody outside of "watchdog.c" was actually referring to them.  Thus, not
only should we make these variables static but we should remove the old
declarations in the header file that we missed renaming.

[dianders@xxxxxxxxxxxx: updated subject + commit message; squashed in Petr's suggestion]
Link: https://lkml.kernel.org/r/20230525162822.1.I0fb41d138d158c9230573eaa37dc56afa2fb14ee@changeid
Fixes: 4b95b620dcd5 ("watchdog/hardlockup: rename some "NMI watchdog" constants/function")
Signed-off-by: Tom Rix <trix@xxxxxxxxxx>
Signed-off-by: Douglas Anderson <dianders@xxxxxxxxxxxx>
Reviewed-by: Tom Rix <trix@xxxxxxxxxx>
Suggested-by: Petr Mladek <pmladek@xxxxxxxx>
Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 include/linux/nmi.h |    6 ++----
 kernel/watchdog.c   |    4 ++--
 2 files changed, 4 insertions(+), 6 deletions(-)

--- a/include/linux/nmi.h~watchdog-delete-old-declarations-for-watchdog_softhardlockup_user_enabled-make-static
+++ a/include/linux/nmi.h
@@ -17,8 +17,6 @@ void lockup_detector_soft_poweroff(void)
 void lockup_detector_cleanup(void);
 
 extern int watchdog_user_enabled;
-extern int nmi_watchdog_user_enabled;
-extern int soft_watchdog_user_enabled;
 extern int watchdog_thresh;
 extern unsigned long watchdog_enabled;
 
@@ -68,8 +66,8 @@ static inline void reset_hung_task_detec
  * 'watchdog_enabled' variable. Each lockup detector has its dedicated bit -
  * bit 0 for the hard lockup detector and bit 1 for the soft lockup detector.
  *
- * 'watchdog_user_enabled', 'nmi_watchdog_user_enabled' and
- * 'soft_watchdog_user_enabled' are variables that are only used as an
+ * 'watchdog_user_enabled', 'watchdog_hardlockup_user_enabled' and
+ * 'watchdog_softlockup_user_enabled' are variables that are only used as an
  * 'interface' between the parameters in /proc/sys/kernel and the internal
  * state bits in 'watchdog_enabled'. The 'watchdog_thresh' variable is
  * handled differently because its value is not boolean, and the lockup
--- a/kernel/watchdog.c~watchdog-delete-old-declarations-for-watchdog_softhardlockup_user_enabled-make-static
+++ a/kernel/watchdog.c
@@ -37,8 +37,8 @@ static DEFINE_MUTEX(watchdog_mutex);
 
 unsigned long __read_mostly watchdog_enabled;
 int __read_mostly watchdog_user_enabled = 1;
-int __read_mostly watchdog_hardlockup_user_enabled = WATCHDOG_HARDLOCKUP_DEFAULT;
-int __read_mostly watchdog_softlockup_user_enabled = 1;
+static int __read_mostly watchdog_hardlockup_user_enabled = WATCHDOG_HARDLOCKUP_DEFAULT;
+static int __read_mostly watchdog_softlockup_user_enabled = 1;
 int __read_mostly watchdog_thresh = 10;
 static int __read_mostly watchdog_hardlockup_available;
 
_

Patches currently in -mm which might be from trix@xxxxxxxxxx are

watchdog-hardlockup-rename-some-nmi-watchdog-constants-function.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux