From: Laurent Dufour <ldufour@linux.ibm.com> To: mpe@ellerman.id.au Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-next@vger.kernel.org, Sachin Sant <sachinp@linux.ibm.com> Subject: [PATCH] watchdog: Fix build error when CONFIG_SOFTLOCKUP_DETECTOR is not set Date: Wed, 27 Jul 2022 11:21:09 +0200 [thread overview] Message-ID: <20220727092109.31362-1-ldufour@linux.ibm.com> (raw) Sachin reported the following build error when CONFIG_SOFTLOCKUP_DETECTOR is not set: kernel/watchdog.c:597:20: error: static declaration of 'lockup_detector_reconfigure' follows non-static declaration static inline void lockup_detector_reconfigure(void) ^~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from kernel/watchdog.c:17: ./include/linux/nmi.h:125:6: note: previous declaration of 'lockup_detector_reconfigure' was here void lockup_detector_reconfigure(void); ^~~~~~~~~~~~~~~~~~~~~~~~~~~ The definition of lockup_detector_reconfigure should be exported even in that case, and __lockup_detector_reconfigure should remain static. Fixes: 24a1260705b7 ("watchdog: export lockup_detector_reconfigure") Reported-by: Sachin Sant <sachinp@linux.ibm.com> Signed-off-by: Laurent Dufour <ldufour@linux.ibm.com> --- kernel/watchdog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/watchdog.c b/kernel/watchdog.c index 90e6c41d5e33..41596c415111 100644 --- a/kernel/watchdog.c +++ b/kernel/watchdog.c @@ -590,7 +590,7 @@ static __init void lockup_detector_setup(void) } #else /* CONFIG_SOFTLOCKUP_DETECTOR */ -void __lockup_detector_reconfigure(void) +static void __lockup_detector_reconfigure(void) { cpus_read_lock(); watchdog_nmi_stop(); @@ -598,7 +598,7 @@ void __lockup_detector_reconfigure(void) watchdog_nmi_start(); cpus_read_unlock(); } -static inline void lockup_detector_reconfigure(void) +void lockup_detector_reconfigure(void) { __lockup_detector_reconfigure(); } -- 2.37.1
WARNING: multiple messages have this Message-ID (diff)
From: Laurent Dufour <ldufour@linux.ibm.com> To: mpe@ellerman.id.au Cc: linux-next@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org, Sachin Sant <sachinp@linux.ibm.com> Subject: [PATCH] watchdog: Fix build error when CONFIG_SOFTLOCKUP_DETECTOR is not set Date: Wed, 27 Jul 2022 11:21:09 +0200 [thread overview] Message-ID: <20220727092109.31362-1-ldufour@linux.ibm.com> (raw) Sachin reported the following build error when CONFIG_SOFTLOCKUP_DETECTOR is not set: kernel/watchdog.c:597:20: error: static declaration of 'lockup_detector_reconfigure' follows non-static declaration static inline void lockup_detector_reconfigure(void) ^~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from kernel/watchdog.c:17: ./include/linux/nmi.h:125:6: note: previous declaration of 'lockup_detector_reconfigure' was here void lockup_detector_reconfigure(void); ^~~~~~~~~~~~~~~~~~~~~~~~~~~ The definition of lockup_detector_reconfigure should be exported even in that case, and __lockup_detector_reconfigure should remain static. Fixes: 24a1260705b7 ("watchdog: export lockup_detector_reconfigure") Reported-by: Sachin Sant <sachinp@linux.ibm.com> Signed-off-by: Laurent Dufour <ldufour@linux.ibm.com> --- kernel/watchdog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/watchdog.c b/kernel/watchdog.c index 90e6c41d5e33..41596c415111 100644 --- a/kernel/watchdog.c +++ b/kernel/watchdog.c @@ -590,7 +590,7 @@ static __init void lockup_detector_setup(void) } #else /* CONFIG_SOFTLOCKUP_DETECTOR */ -void __lockup_detector_reconfigure(void) +static void __lockup_detector_reconfigure(void) { cpus_read_lock(); watchdog_nmi_stop(); @@ -598,7 +598,7 @@ void __lockup_detector_reconfigure(void) watchdog_nmi_start(); cpus_read_unlock(); } -static inline void lockup_detector_reconfigure(void) +void lockup_detector_reconfigure(void) { __lockup_detector_reconfigure(); } -- 2.37.1
next reply other threads:[~2022-07-27 9:21 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-07-27 9:21 Laurent Dufour [this message] 2022-07-27 9:21 ` [PATCH] watchdog: Fix build error when CONFIG_SOFTLOCKUP_DETECTOR is not set Laurent Dufour 2022-07-27 10:10 ` Sachin Sant 2022-07-27 10:10 ` Sachin Sant 2022-07-27 11:38 ` Michael Ellerman 2022-07-27 11:38 ` Michael Ellerman 2022-07-27 14:20 ` Laurent Dufour 2022-07-27 14:20 ` Laurent Dufour 2022-07-28 3:18 ` Michael Ellerman 2022-07-28 3:18 ` Michael Ellerman
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20220727092109.31362-1-ldufour@linux.ibm.com \ --to=ldufour@linux.ibm.com \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-next@vger.kernel.org \ --cc=linuxppc-dev@lists.ozlabs.org \ --cc=mpe@ellerman.id.au \ --cc=sachinp@linux.ibm.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.