From nobody Sat Feb 7 23:12:35 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 03524C77B7A for ; Fri, 19 May 2023 09:43:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230302AbjESJn4 (ORCPT ); Fri, 19 May 2023 05:43:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48264 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230290AbjESJnW (ORCPT ); Fri, 19 May 2023 05:43:22 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8A84E213A for ; Fri, 19 May 2023 02:41:31 -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 dfw.source.kernel.org (Postfix) with ESMTPS id 62314655A8 for ; Fri, 19 May 2023 09:40:53 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3C9A3C433EF; Fri, 19 May 2023 09:40:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684489252; bh=sczsbRpuY6qul0O2IVlTqPIb+oBjrjpfMfChzCygpVA=; h=From:To:Cc:Subject:Date:From; b=DDLt1yXsc4kiSMPPgaoLRVpN1ga2Jv10Ch5WxuSZ/NGfEMjcXINZ2rm5YShP05rhK CwNvEBpoLIf1AYj+LZ2loA306P1ZEwe2YNdSkgIPFjQhk7bTIrp4+olzDAw/ooqht2 uJX6wY6WHiOsNcFjOQlHHUh1sB28ua4s0acCDfR/UfEk8W9z2wSwANhgxIjcghnvCF 9cFqLTHhwNVuyxKfBuJqaobFUXx/s/rSlXUdrZx40vTXgJcVUGk9MfdxfeF+nKiI3j fORBXXpWQrj553ABJycTVZ219zTqxzk4vKIWx4AYptnv5t31/Jz+VucbynL6Sge9gV jEAvP7FnwD8vQ== From: Arnd Bergmann To: Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, Peter Zijlstra Cc: Arnd Bergmann , "H. Peter Anvin" , Kees Cook , Song Liu , Nadav Amit , linux-kernel@vger.kernel.org Subject: [PATCH] x86: alternative: add __alt_reloc_selftest prototype Date: Fri, 19 May 2023 11:40:27 +0200 Message-Id: <20230519094035.11259-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Arnd Bergmann The newly introduced selftest function causes a warning when -Wmissing-prot= otypes is enabled: arch/x86/kernel/alternative.c:1461:32: error: no previous prototype for '__= alt_reloc_selftest' [-Werror=3Dmissing-prototypes] Since it's only used locally, add the prototype directly in front of it. Fixes: 270a69c4485d ("x86/alternative: Support relocations in alternatives") Signed-off-by: Arnd Bergmann --- arch/x86/kernel/alternative.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative.c index 93aa95afd005..4338bd74b663 100644 --- a/arch/x86/kernel/alternative.c +++ b/arch/x86/kernel/alternative.c @@ -1458,6 +1458,7 @@ static noinline void __init int3_selftest(void) =20 static __initdata int __alt_reloc_selftest_addr; =20 +extern void __init __alt_reloc_selftest(void *arg); __visible noinline void __init __alt_reloc_selftest(void *arg) { WARN_ON(arg !=3D &__alt_reloc_selftest_addr); --=20 2.39.2