Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp4705369imw; Tue, 12 Jul 2022 12:44:36 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uGHwgjQzI7Xn1sAu2se5P5Twusj/3NxoSIF2nbCD/MGTY9ajLGOoAAI5Owj+bmptIV2ALP X-Received: by 2002:a05:6402:371a:b0:43a:ece9:ab8e with SMTP id ek26-20020a056402371a00b0043aece9ab8emr6678564edb.126.1657655076672; Tue, 12 Jul 2022 12:44:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1657655076; cv=none; d=google.com; s=arc-20160816; b=iFDshM4rQUVylGAl/8yo6mPNJQK9f7k5uh1q52Ytb3vOWm7Wy8ORDk2kLlAxnqZyUx GZ+aIM2UkPG3LQYT3s8cX8N8DxW4iwuAT5F6nTBQORFy1xRDb3r2RlG/l7gFyBQJiKam qc1qNBP6SrTtQjcbhypzPHrqV3zyUH43p45WMbPGEq6A9KncQdpufvLm8mHlaXRkg+ur B7w54h37ImI7ZJJ6M+DSe8DaKgHqXaOtOYIzZFqvD7cjNWC+L4BvemIWkIjF4jN4Ti0r 16iNRc1UODrEloS4zI9GPv/NwP2ilK/HetpIbcczCp4xrceJOsy4WPxC6UJh6C2KmUiG f43w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=BvrhB+2CBZbWF228UatUJZ156qpRl6lAnYxZgyuedNM=; b=wUaGhcvcon1gDVDCgXwvGygHc+Sj7R8iJyILN5ZM2dVfnlXJx8Zrersle066PpSo5t 9Vzm/oziTjfehRZOzLqo7SOh2e0sM4EsaHQd4O8u0Ph0/a0k1gzmrjRi8cW3wonVgeVn DbKajIf/H8XBDEQniRgx7qxXIoCfSqA5Mb7cgf7ufyrJaffd/mhXKzmT8fzB5M7hQQY3 fts0FiBfA880RxyI+ILmSsxuapvghlCC7WNgSGGvNoTRzcR2jlrmY2VVsUEXx3FVUm+k oG1gnZiPzo1qKGUgmzbYhrhlwlMnlyWDtYlnZvpfhp2mH/rgxgqOJ+V+3TAca3BaPC0s 6Cuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=e6jnVWlL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id sg41-20020a170907a42900b00726c7fc61dfsi17167953ejc.103.2022.07.12.12.44.09; Tue, 12 Jul 2022 12:44:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=e6jnVWlL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234372AbiGLSq2 (ORCPT + 99 others); Tue, 12 Jul 2022 14:46:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33184 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234184AbiGLSpl (ORCPT ); Tue, 12 Jul 2022 14:45:41 -0400 Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1836FDC184; Tue, 12 Jul 2022 11:42:39 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sin.source.kernel.org (Postfix) with ESMTPS id 008D2CE1D8E; Tue, 12 Jul 2022 18:42:38 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 93A2DC3411C; Tue, 12 Jul 2022 18:42:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1657651356; bh=QLUaL63/ytWAUClgmAMMnqPtqDpfAEvNGe4wTT9p+hI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=e6jnVWlLKetyoDbIi2OX0GBSPPhwK+1nnFKhTe49gJEyLAeTAhK/u8FUb10Ppn6FA H6WhjEefc1W4kn+Tc476AJIs9IpdCmjWcttYdxJlXAs6cdFcNuxlqRfk7k06LU3N4O t45vf8MVPRenaNcfRCAbcVfPFhNhCN/e+E4dvVMI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, "Peter Zijlstra (Intel)" , Borislav Petkov , Josh Poimboeuf , Alexei Starovoitov , Thadeu Lima de Souza Cascardo , Ben Hutchings Subject: [PATCH 5.10 052/130] x86/asm: Fixup odd GEN-for-each-reg.h usage Date: Tue, 12 Jul 2022 20:38:18 +0200 Message-Id: <20220712183248.839689209@linuxfoundation.org> X-Mailer: git-send-email 2.37.0 In-Reply-To: <20220712183246.394947160@linuxfoundation.org> References: <20220712183246.394947160@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peter Zijlstra commit b6d3d9944bd7c9e8c06994ead3c9952f673f2a66 upstream. Currently GEN-for-each-reg.h usage leaves GEN defined, relying on any subsequent usage to start with #undef, which is rude. Signed-off-by: Peter Zijlstra (Intel) Reviewed-by: Borislav Petkov Acked-by: Josh Poimboeuf Tested-by: Alexei Starovoitov Link: https://lore.kernel.org/r/20211026120310.041792350@infradead.org Signed-off-by: Thadeu Lima de Souza Cascardo Signed-off-by: Ben Hutchings Signed-off-by: Greg Kroah-Hartman --- arch/x86/include/asm/asm-prototypes.h | 2 +- arch/x86/lib/retpoline.S | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) --- a/arch/x86/include/asm/asm-prototypes.h +++ b/arch/x86/include/asm/asm-prototypes.h @@ -19,9 +19,9 @@ extern void cmpxchg8b_emu(void); #ifdef CONFIG_RETPOLINE -#undef GEN #define GEN(reg) \ extern asmlinkage void __x86_indirect_thunk_ ## reg (void); #include +#undef GEN #endif /* CONFIG_RETPOLINE */ --- a/arch/x86/lib/retpoline.S +++ b/arch/x86/lib/retpoline.S @@ -55,10 +55,10 @@ SYM_FUNC_END(__x86_indirect_thunk_\reg) #define __EXPORT_THUNK(sym) _ASM_NOKPROBE(sym); EXPORT_SYMBOL(sym) #define EXPORT_THUNK(reg) __EXPORT_THUNK(__x86_indirect_thunk_ ## reg) -#undef GEN #define GEN(reg) THUNK reg #include - #undef GEN + #define GEN(reg) EXPORT_THUNK(reg) #include +#undef GEN