From patchwork Thu Feb 15 15:16:56 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 128481 Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp1860067ljc; Thu, 15 Feb 2018 07:17:55 -0800 (PST) X-Google-Smtp-Source: AH8x2243jhMuKl8eQkFCwpsHG16/8nJ+qqqW1rOQnEJqq348irPjy/ZpgqTLA7tWniSIyopETgr5 X-Received: by 10.101.101.19 with SMTP id x19mr2503296pgv.347.1518707875499; Thu, 15 Feb 2018 07:17:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518707875; cv=none; d=google.com; s=arc-20160816; b=LA9enGcvrSn83C1wLqQXnyqeX6g1oRe91Pp/X999j7xIah3IezFhUPNSFdeg+LQPBR 6UXnfZgCfxjUTC8XApg045Fitrvf+LuL21p1ddwtDU7YO/jbSHnm2DzDj0xMqE/+1B4s 0+7Eg9XisP6iAExk67sBVWAzGQhzAV/PdSf446hmlyXVACbWRBlhx6sPDUflOgEEpM3d ISDSFIClZyNWVpgW2OF19KP7+j9sUrmNdBQH125+H78cayDMiqkUgPyeebghpHIsZzlC xYYUNzlUWRCs5hLr4fThH7UrYibWn/Gm43juN2qGoSwY5fArYouRvg5hq1TD+LscEKA/ vOcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=+t8H48aTCJ/7PuBQovkPR8uZcmaa7TdWloCY0e9G6iM=; b=sAl7w2ydSNkGFAyGDHJC+5tMj4YbmgQJhH9ZeFiZRAWnTtAlwqBSOKDlKzJu/4tgRE xCGP7FuQ96WflQKOcd1Gi6yomnj7Ur94b1bNxcaI1MXq+b0RHyU4SfXo2J27jpMEkOBh /LBzQzcZZNU7ku0gPTqA/F0TDA2RJEihrwWoJG+PerzF/MFljMH8pCaLmb24lUhGobcl ri4AFFWPzQHnD0DbId/I5737g6B5UfV3dmUyAqJ59Qz/yk2ZqZF6ZWGTwSjUw56utTGS dchn6U5q4fSq3fZuv1fe5HerTPhJnmoA3159XQQL/QTgwMsMkPCuGQuHljAzRqMb4ntq DfGw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 3-v6si1335354plt.307.2018.02.15.07.17.55; Thu, 15 Feb 2018 07:17:55 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1033676AbeBOPRy (ORCPT + 10 others); Thu, 15 Feb 2018 10:17:54 -0500 Received: from mout.kundenserver.de ([212.227.17.13]:46733 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1033088AbeBOPRx (ORCPT ); Thu, 15 Feb 2018 10:17:53 -0500 Received: from wuerfel.lan ([95.208.111.237]) by mrelayeu.kundenserver.de (mreue104 [212.227.15.145]) with ESMTPA (Nemesis) id 0MWjbX-1fJg6E2fBz-00Xsoa; Thu, 15 Feb 2018 16:17:13 +0100 From: Arnd Bergmann To: stable@vger.kernel.org Cc: x86@kernel.org, Dave Hansen , Ben Hutchings , Arnd Bergmann , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Greg Kroah-Hartman , Borislav Petkov , Hugh Dickins , linux-kernel@vger.kernel.org Subject: [PATCH 1/2] [stable-4.9] x86: fix build without CONFIG_X86_VSYSCALL_EMULATION Date: Thu, 15 Feb 2018 16:16:56 +0100 Message-Id: <20180215151710.1473117-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:h8PYdX4vUhO5lA7sMXfex+JEYEq0gSc10qodm/Mf7r6DGa1bHXb VUZ7e351d8i011IuLVRgHqws5usV2Sp9NAzX1J5O/LO81qq6hJy4DIrp/uaH6T/OBfjxoEW IGubTV7BYptUXHtfh0VNNc8DDQiYSz8OWVchGz0ldyp7lVAQqF8lcCNuNj20edF8xdyc12R gHG+g2QP6lA6/dpfBiibg== X-UI-Out-Filterresults: notjunk:1; V01:K0:uvigUY2wKMc=:hOgF03DJuu5bIkiN3BiIfT yPF8du2oHtj1pHGK9cWULJic/vWvqiV552BBNuNv139XQuwBVyXF2j3Y0ezmd2HAoqOlHH9L4 JbCAbP8v72/Dn8HyQw8NYhr8J1JRITP6Q9BwKWju1xxjiOkwfugdnColzWMyxu1rqVKNumn/C V4R4/ufrgJhloAfpcTOj0SG3JVJtsR7cCFfzQMWebpDLRT0G6siY0XJvS2mWgcpP/co0J21L8 yag6bKhMAfRm/Q7ieFZuGo5zRMmUsx6GerPg1NFqXdvZqLUT2KLJv29WIYgZ4RUcfybbNKT2D adnon343XWZ3+MWFoxoKnVxcgg8KmAhlhr0o6GMPycivzd5sfgvJpzytN120k+s4hYx1KMUzM lsmx+94W5u+m5j+cVHe2tx2wVf8lLZMjcCa5cax9JTQJxm5CN3OzTndOgK0ubhBCTdIT9QgKw oFlIiXy8E1EntRkO/VfCI3m+U730aOzDKPPCYuuJ0k1hj6+s1MtKWNgMaStoZk4kaom3LopAx lU2WUBrNo8xgxB7OX8pgv0dsY7EOoBWNzKvDjW0aNX6pgFWOCMUajvXR0hJKFfcjCxLRvzKRB YKX16Vf/pOL3B9MbrAxrBFEgXW7074hUZsCrxqKo7QW6imun3wwuA9Wa3np24QmtDtq4i+c3I o7W+wFUOqCmd3puQWMw4MrPnTRKq19D734F4yjtrkmWT7/1nwFwZYHAO3c42tUppbj+6IAI/g Z2VoxiTPUuunVGDDuy0S8+YN5DB8EgjvuSuGbw== Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org I ran into a 4.9 build regression in randconfig testing, starting with the KAISER patches: arch/x86/mm/kaiser.c: In function 'kaiser_init': arch/x86/mm/kaiser.c:347:8: error: 'vsyscall_pgprot' undeclared (first use in this function); did you mean 'massage_pgprot'? This is easy enough to fix, we just need to make the declaration visible outside of the #ifdef. This works because the code using it is optimized away when vsyscall_enabled() returns false at compile time. Fixes: 9a0be5afbfbb ("vsyscall: Fix permissions for emulate mode with KAISER/PTI") Signed-off-by: Arnd Bergmann --- arch/x86/include/asm/vsyscall.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- 2.9.0 diff --git a/arch/x86/include/asm/vsyscall.h b/arch/x86/include/asm/vsyscall.h index 9ee85066f407..c98c21b7f4cd 100644 --- a/arch/x86/include/asm/vsyscall.h +++ b/arch/x86/include/asm/vsyscall.h @@ -13,7 +13,6 @@ extern void map_vsyscall(void); */ extern bool emulate_vsyscall(struct pt_regs *regs, unsigned long address); extern bool vsyscall_enabled(void); -extern unsigned long vsyscall_pgprot; #else static inline void map_vsyscall(void) {} static inline bool emulate_vsyscall(struct pt_regs *regs, unsigned long address) @@ -23,4 +22,6 @@ static inline bool emulate_vsyscall(struct pt_regs *regs, unsigned long address) static inline bool vsyscall_enabled(void) { return false; } #endif +extern unsigned long vsyscall_pgprot; + #endif /* _ASM_X86_VSYSCALL_H */