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] [day] [month] [year] [list]
Date:	Tue, 10 Feb 2015 13:34:53 +0300
From:	Andrey Ryabinin <a.ryabinin@...sung.com>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	Jim Davis <jim.epost@...il.com>,
	Stephen Rothwell <sfr@...b.auug.org.au>,
	Thomas Gleixner <tglx@...utronix.de>,
	Ingo Molnar <mingo@...hat.com>,
	"H. Peter Anvin" <hpa@...or.com>, x86@...nel.org,
	linux-next <linux-next@...r.kernel.org>,
	linux-kernel <linux-kernel@...r.kernel.org>,
	Andrey Ryabinin <a.ryabinin@...sung.com>
Subject: [PATCH] x86_64-add-kasan-support-fix

Combination of CONFIG_SPARSEMEM_VMEMMAP=n, CONFIG_KASAN=y
cause build error:
	arch/x86/built-in.o: In function `populate_zero_shadow':
	kasan_init_64.c:(.init.text+0xe2cc): undefined reference to
	`vmemmap_alloc_block'
	kasan_init_64.c:(.init.text+0xe3ab): undefined reference to
	`vmemmap_alloc_block'
	kasan_init_64.c:(.init.text+0xe483): undefined reference to
	`vmemmap_alloc_block'
	arch/x86/built-in.o: In function `kasan_init':
	(.init.text+0xe65d): undefined reference to `vmemmap_populate'
	arch/x86/built-in.o: In function `kasan_init':
	(.init.text+0xe6ea): undefined reference to `vmemmap_populate'
	make: *** [vmlinux] Error 1

x86_64-specific part of KASAN depends on SPARSEMEM_VMEMMAP.
Express this in Kconfig.

Signed-off-by: Andrey Ryabinin <a.ryabinin@...sung.com>
Reported-by: Jim Davis <jim.epost@...il.com>
---
 arch/x86/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 1607c46..1e78e3c 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -85,7 +85,7 @@ config X86
 	select HAVE_CMPXCHG_LOCAL
 	select HAVE_CMPXCHG_DOUBLE
 	select HAVE_ARCH_KMEMCHECK
-	select HAVE_ARCH_KASAN if X86_64
+	select HAVE_ARCH_KASAN if X86_64 && SPARSEMEM_VMEMMAP
 	select HAVE_USER_RETURN_NOTIFIER
 	select ARCH_BINFMT_ELF_RANDOMIZE_PIE
 	select HAVE_ARCH_JUMP_LABEL
-- 
2.3.0

--
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