From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755959AbbJAHKl (ORCPT ); Thu, 1 Oct 2015 03:10:41 -0400 Received: from terminus.zytor.com ([198.137.202.10]:44317 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755602AbbJAHKh (ORCPT ); Thu, 1 Oct 2015 03:10:37 -0400 Date: Thu, 1 Oct 2015 00:09:37 -0700 From: tip-bot for Andrey Ryabinin Message-ID: Cc: matt.fleming@intel.com, a.p.zijlstra@chello.nl, torvalds@linux-foundation.org, tglx@linutronix.de, efault@gmx.de, sedat.dilek@gmail.com, peterz@infradead.org, linux-kernel@vger.kernel.org, ryabinin.a.a@gmail.com, mingo@kernel.org, hpa@zytor.com Reply-To: peterz@infradead.org, sedat.dilek@gmail.com, linux-kernel@vger.kernel.org, ryabinin.a.a@gmail.com, mingo@kernel.org, hpa@zytor.com, matt.fleming@intel.com, a.p.zijlstra@chello.nl, torvalds@linux-foundation.org, efault@gmx.de, tglx@linutronix.de In-Reply-To: <1443544814-20122-1-git-send-email-ryabinin.a.a@gmail.com> References: <1443544814-20122-1-git-send-email-ryabinin.a.a@gmail.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/urgent] x86, efi, kasan: Fix build failure on !KASAN && KMEMCHECK=y kernels Git-Commit-ID: 4ac86a6dcec1c3878de9747bf5a2aa4455be69e3 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 4ac86a6dcec1c3878de9747bf5a2aa4455be69e3 Gitweb: http://git.kernel.org/tip/4ac86a6dcec1c3878de9747bf5a2aa4455be69e3 Author: Andrey Ryabinin AuthorDate: Tue, 29 Sep 2015 19:40:14 +0300 Committer: Ingo Molnar CommitDate: Wed, 30 Sep 2015 09:29:53 +0200 x86, efi, kasan: Fix build failure on !KASAN && KMEMCHECK=y kernels With KMEMCHECK=y, KASAN=n we get this build failure: arch/x86/platform/efi/efi.c:673:3: error: implicit declaration of function ‘memcpy’ [-Werror=implicit-function-declaration] arch/x86/platform/efi/efi_64.c:139:2: error: implicit declaration of function ‘memcpy’ [-Werror=implicit-function-declaration] arch/x86/include/asm/desc.h:121:2: error: implicit declaration of function ‘memcpy’ [-Werror=implicit-function-declaration] Don't #undef memcpy if KASAN=n. Reported-by: Ingo Molnar Reported-by: Sedat Dilek Signed-off-by: Andrey Ryabinin Cc: Linus Torvalds Cc: Matt Fleming Cc: Mike Galbraith Cc: Peter Zijlstra Cc: Peter Zijlstra Cc: Thomas Gleixner Fixes: 769a8089c1fd ("x86, efi, kasan: #undef memset/memcpy/memmove per arch") Link: http://lkml.kernel.org/r/1443544814-20122-1-git-send-email-ryabinin.a.a@gmail.com Signed-off-by: Ingo Molnar --- arch/x86/include/asm/efi.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/x86/include/asm/efi.h b/arch/x86/include/asm/efi.h index ab5f1d4..ae68be9 100644 --- a/arch/x86/include/asm/efi.h +++ b/arch/x86/include/asm/efi.h @@ -86,6 +86,7 @@ extern u64 asmlinkage efi_call(void *fp, ...); extern void __iomem *__init efi_ioremap(unsigned long addr, unsigned long size, u32 type, u64 attribute); +#ifdef CONFIG_KASAN /* * CONFIG_KASAN may redefine memset to __memset. __memset function is present * only in kernel binary. Since the EFI stub linked into a separate binary it @@ -95,6 +96,7 @@ extern void __iomem *__init efi_ioremap(unsigned long addr, unsigned long size, #undef memcpy #undef memset #undef memmove +#endif #endif /* CONFIG_X86_32 */