From patchwork Mon Nov 14 11:43:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Slaby X-Patchwork-Id: 13042185 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 68928C4332F for ; Mon, 14 Nov 2022 11:49:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236861AbiKNLtD (ORCPT ); Mon, 14 Nov 2022 06:49:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41278 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236625AbiKNLsY (ORCPT ); Mon, 14 Nov 2022 06:48:24 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 28BF026577; Mon, 14 Nov 2022 03:45:43 -0800 (PST) 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 BBC0361090; Mon, 14 Nov 2022 11:45:42 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 600C5C433C1; Mon, 14 Nov 2022 11:45:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1668426342; bh=LDDWnbc0G82XezA7Wy98vToKYOH6Yv/7cEWA4wpWfUg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=T7n13i8yGgCA6xfsV2rnP2Sn2LRC3XAIWA67SLNgXWXfb/KLM+FpdCj3dH7Y7MK0K ZFpnJPsia5D9y+j37HQE+wvcQCcPCYKPwpaIDH51AgBam6gDc6YnjzSOGzjhAQtPPZ BuV4mFX63jbFtrHwGzWF9uefmuk5uCwWd1AOjOwgT4jwgucnZo4DcyvqVMncXkX/Xi ww1vFk+Vd4oYdxIVzT2mt40FyMs70o9Y5xW55gLvnX0UaCWguDqZvgBrD98tHkTAfc qiUDD4bphIEkYCn0zqfMmUAy4ulNVj39L1XzJ3XsV5tmWEYlmcMH5X/1DnAGDPj/st KXI7Ob2C7SEtQ== From: "Jiri Slaby (SUSE)" To: linux-kernel@vger.kernel.org Cc: Andi Kleen , Masahiro Yamada , Michal Marek , Nick Desaulniers , linux-kbuild@vger.kernel.org, Martin Liska , Jiri Slaby Subject: [PATCH 43/46] scripts, lto: check C symbols for modversions Date: Mon, 14 Nov 2022 12:43:41 +0100 Message-Id: <20221114114344.18650-44-jirislaby@kernel.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221114114344.18650-1-jirislaby@kernel.org> References: <20221114114344.18650-1-jirislaby@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org From: Andi Kleen The gcc LTO nm doesn't output assembler symbols, which makes the symversions check fail because ksymtab is defined in assembler. Instead, check for a C symbol that is generated too. Cc: Masahiro Yamada Cc: Michal Marek Cc: Nick Desaulniers Cc: linux-kbuild@vger.kernel.org Signed-off-by: Andi Kleen Signed-off-by: Martin Liska Signed-off-by: Jiri Slaby --- scripts/Makefile.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 9b522c9efcb6..dafa8aeed9c2 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@ -173,7 +173,7 @@ ifdef CONFIG_MODVERSIONS # be compiled and linked to the kernel and/or modules. gen_symversions = \ - if $(NM) $@ 2>/dev/null | grep -q __ksymtab; then \ + if $(NM) $@ 2>/dev/null | grep -q __kstrtab; then \ $(call cmd_gensymtypes_$(1),$(KBUILD_SYMTYPES),$(@:.o=.symtypes)) \ >> $(dot-target).cmd; \ fi