From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758659AbdLRNpy (ORCPT ); Mon, 18 Dec 2017 08:45:54 -0500 Received: from mout.kundenserver.de ([212.227.17.24]:60032 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752688AbdLRNpv (ORCPT ); Mon, 18 Dec 2017 08:45:51 -0500 From: Arnd Bergmann To: Thomas Gleixner Cc: Arnd Bergmann , Ingo Molnar , "H. Peter Anvin" , x86@kernel.org, Andy Lutomirski , Borislav Petkov , Peter Zijlstra , Thomas Garnier , Ricardo Neri , linux-kernel@vger.kernel.org Subject: [PATCH] x86: hide unused allocate_percpu_fixmap_ptes Date: Mon, 18 Dec 2017 14:43:50 +0100 Message-Id: <20171218134417.3000184-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:msRKBmZ2aO7aiQckDywyXGl3xgXKS2DmtNYhvsIW/6M/ytC5OYn iBu7Fw1wojSDpTRnH1B3wZnIGwsoI9cgWgFn4ZwYvDxEwgF6ZQoJ4+LoTRBDshRkX16UMNL 7qFKzbcMoqdGxRfB9llul/POQmUNk1Bc0xhFez7k9/S7Q3CPF5BzLOMK5fiDIdAQXUHLhoL AkoAKxVogwY8j5xeSLd3w== X-UI-Out-Filterresults: notjunk:1;V01:K0:TUnTvX22MXg=:jsoXAqX545027ApShDr+xf x0QL+UhgISW7HL+NCc0A4XQ5m4Ji0Iqx2hMPQfPr7msEnIT5yYM6VDMjM8rSHtQLEF5WBGhG1 1OPopeYYDiAG+2lKKPLx6n/Pdoock88L6v9oh6/XyqDqXPYxWUm/Gb6EEmEHTGSjFZu7ZKAOh msnhUe8uZR2y69sPUnhh5wKo9w1a/Dn2uNatHuMbRmZEChvIFEr2nuc+UO6wAIdiNvcFdjSvR 3Jb8cC5MNM738d3hqODf4b402npvbunRw9HsgIwRoXgWFL/1YhdsYG+Gy2Rl5zbOOE9TsRB4G rfXTouVyIbb1dwjUDZdGuRJ72opnFsMPs1wzx73rzbEZzUuRXy5O8P5ZXAk3DUsij3cmwSGvd aK+xYOIVzDWhOo2SHwi2pMS4Mza7m0hdESdUR/EOykvuTmiLFApzNbI7NFmt8sXGy5oTO06pc QolqS1iZEjb90Jq2wvwPnhNSGirErS7Bx4Y+WM9S9i+5VUVcPX6TLVZEN1R2/7SD/YAarcFHO VQUXJPLRcIWtnF7zd0WD9tvQ+QyosSARMw2p+7DCjYejGkzu629qBgc1dgp046Km2o0VvzxL8 WJSV3Eu8MUdBIwz9OV6jf0QF1wn+avDKh92QRYrBqm+blmgN+ixXWYctghn/LKz+xRaiOPVv3 i4fet97iwlm0pbL9sbqVo+ZQHApZENn8oKX/gZnygpBznzAbVI7YvQ8Yj8FMrD6xF0oB8HqPk SmtieEgl6UwpWsJCpYkNpUBEzdhG3K3/NPLlig== Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The new function is not always used, causing a warning whenever CONFIG_CPU_SUP_INTEL is disabled: arch/x86/kernel/cpu/common.c:522:20: error: 'allocate_percpu_fixmap_ptes' defined but not used [-Werror=unused-function] Hide it in the same #ifdef. Fixes: 3015f86f838c ("x86/fixmap: Add debugstore entries to cpu_entry_area") Signed-off-by: Arnd Bergmann --- arch/x86/kernel/cpu/common.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c index 6444f91e8d3c..6f354416a67f 100644 --- a/arch/x86/kernel/cpu/common.c +++ b/arch/x86/kernel/cpu/common.c @@ -519,11 +519,13 @@ static DEFINE_PER_CPU_PAGE_ALIGNED(struct entry_stack_page, * Force the population of PMDs for not yet allocated per cpu * memory like debug store buffers. */ +#ifdef CONFIG_CPU_SUP_INTEL static void __init allocate_percpu_fixmap_ptes(int idx, int pages) { for (; pages; pages--, idx--) __set_fixmap(idx, 0, PAGE_NONE); } +#endif static void __init set_percpu_fixmap_pages(int idx, void *ptr, int pages, pgprot_t prot) -- 2.9.0