lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 26 Aug 2014 09:54:17 -0400
From:	Don Zickus <dzickus@...hat.com>
To:	Stephen Rothwell <sfr@...b.auug.org.au>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	linux-next@...r.kernel.org, linux-kernel@...r.kernel.org,
	Ulrich Obergfell <uobergfe@...hat.com>,
	Andrew Jones <drjones@...hat.com>
Subject: Re: linux-next: build failure after merge of the akpm tree

On Tue, Aug 26, 2014 at 05:18:18PM +1000, Stephen Rothwell wrote:
> Hi Andrew,
> 
> After merging the akpm tree, today's linux-next build (sparc64
> defconfig) failed like this:
> 
> kernel/built-in.o: In function `proc_dowatchdog':
> (.text+0x6a620): undefined reference to `watchdog_hardlockup_detector_is_enabled'
> kernel/built-in.o: In function `proc_dowatchdog':
> (.text+0x6a6a8): undefined reference to `watchdog_enable_hardlockup_detector'
> kernel/built-in.o: In function `proc_dowatchdog':
> (.text+0x6a79c): undefined reference to `watchdog_enable_hardlockup_detector'
> 
> Caused by commit 72355eed4bd7 ("kernel/watchdog.c: control hard lockup
> detection default").  This build has CONFIG_HAVE_NMI_WATCHDOG=y,
> CONFIG_HARDLOCKUP_DETECTOR not set.

:-(  I was trying to figure out why touch_nmi_watchdog doesn't break the
same way until I noticed sparc has its own personal implementation of this
function (instead of using kernel/watchdog.c's version).

We are going to have to split the include/linux/nmi.h changes out into its
own #ifdef area.  I am not sure my brain is quite ready to untangle the
sparc implementation of the watchdog stuff and try to make it use the
generic one yet.

This patch I believe fixes the compile problem for now.

Not sure the proper way to post this or who to send this too.

------8<------
From: Don Zickus <dzickus@...hat.com>
Date: Tue, 26 Aug 2014 09:50:21 -0400
Subject: [PATCH] watchdog, nmi: Fix compile issues on sparc

Sparc doesn't use HARDLOCKUP_DETECTOR the same way x86 does.  As a result break
out the new functions

watchdog_hardlockup_detector_is_enabled
watchdog_enable_hardlockup_detector

into their own #if defined area.  This resolves the compile issue where
CONFIG_NMI_WATCHDOG=y and CONFIG_HARDLOCKUP_DETECTOR is not set on sparc.

Signed-off-by: Don Zickus <dzickus@...hat.com>
---
 include/linux/nmi.h |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/include/linux/nmi.h b/include/linux/nmi.h
index 72aacf4..f82a5bf 100644
--- a/include/linux/nmi.h
+++ b/include/linux/nmi.h
@@ -17,14 +17,18 @@
 #if defined(CONFIG_HAVE_NMI_WATCHDOG) || defined(CONFIG_HARDLOCKUP_DETECTOR)
 #include <asm/nmi.h>
 extern void touch_nmi_watchdog(void);
-extern void watchdog_enable_hardlockup_detector(bool val);
-extern bool watchdog_hardlockup_detector_is_enabled(void);
 #else
 static inline void touch_nmi_watchdog(void)
 {
 	touch_softlockup_watchdog();
 }
-static inline void watchdog_enable_hardlockup_detector(bool)
+#endif
+
+#if defined(CONFIG_HARDLOCKUP_DETECTOR)
+extern void watchdog_enable_hardlockup_detector(bool val);
+extern bool watchdog_hardlockup_detector_is_enabled(void);
+#else
+static inline void watchdog_enable_hardlockup_detector(bool val)
 {
 }
 static inline bool watchdog_hardlockup_detector_is_enabled(void)
-- 
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ