Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1030195iob; Fri, 13 May 2022 20:17:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJytT9PKWBGcSMg2jF+t7IGA+BaUgQ3f8C5rQh20amYQSvskKAKOR4RBIvwzZ/muD4shpYRa X-Received: by 2002:a05:6000:1f0a:b0:20c:f50e:8eb6 with SMTP id bv10-20020a0560001f0a00b0020cf50e8eb6mr3217576wrb.715.1652498229193; Fri, 13 May 2022 20:17:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652498229; cv=none; d=google.com; s=arc-20160816; b=RiMkp83b/VFmRsgnCbKkeB0kEFX0KRIEI7fRjY0j+rPVBjHsLUjEPBWpSwG0Ed1/J6 U63gEbzQV6o9pP1hNYzXqc6AZP++iHCDjLgeSj+ieSS/PRLVyrPtfYbFkoR9qEbosKhN kmEPPRfyUtP9Ojb5sN+jtj7ktLaQNwXEnVFk90VtYC1inSC5np/nAEj6aZtmZ14TtLpk txn9rj2v6FgNmOtZ9wEaElmbx0PgO0SF1QNqkTLwoem6gogme2JCInICx5TSGTkLP379 BJH0NXwJrWZ23iM9owKG5yJ1Fu8+yFM4pE1BNvbEzU2igX853Q16cgiGepYfu8f8yh58 pqug== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-filter; bh=9Q6mTn1bAGbkjgZhALJ6nTHBDHzsRRSkgxWQCfuUF6o=; b=fWDKPag5XkWvQNBJoj87eYNmvmBpyVrrRLUj1XUA7F6ouKXIFAN/DbXqwISO3Gbi5E L9xdyWg0lQP9ehtiPfYKljFmHNWusW8gD9AzvyvbtRKRGkKuBdHS5g7NM/I/rFY1ZVM/ 7/NV4TnKdrcLxsAhWkLpWKYDPW6T8oCpTO1UGWw3e5k4ECYydqt8Tk3qWq4anK3KgHu0 i3ZY0YR2j7RceQ9N2cr/Q42w5P4wUz+ymO3GADXdFwQ2E8fslU4vbopzjrV3Vk/Qm5Zw ydxJgpbROITAP9N6z0wP0nAYEkiitATjxh4JKU+URHuksVYTX8U+Ren5lohou0/UpA57 6uFA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=whFtsEsp; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id v21-20020a05600c215500b00394356c3ce9si3640538wml.20.2022.05.13.20.17.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 May 2022 20:17:09 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=whFtsEsp; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 538AA3ABF28; Fri, 13 May 2022 16:55:48 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1379971AbiEMLmm (ORCPT + 99 others); Fri, 13 May 2022 07:42:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39312 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1379962AbiEMLmR (ORCPT ); Fri, 13 May 2022 07:42:17 -0400 Received: from conuserg-07.nifty.com (conuserg-07.nifty.com [210.131.2.74]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 703F041611; Fri, 13 May 2022 04:42:13 -0700 (PDT) Received: from grover.sesame (133-32-177-133.west.xps.vectant.ne.jp [133.32.177.133]) (authenticated) by conuserg-07.nifty.com with ESMTP id 24DBeEwd008349; Fri, 13 May 2022 20:40:18 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-07.nifty.com 24DBeEwd008349 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1652442019; bh=9Q6mTn1bAGbkjgZhALJ6nTHBDHzsRRSkgxWQCfuUF6o=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=whFtsEspc/QO7yhgWHzcrhF8CSTpr4/K7GubZ1k3pXPHngIOmWX1Bg3G3E9BT4G9r vDeq+KtUyMHJrUQ2RXmTnWl7x4Q0J+gBTbmDWLOXqm0/eyW70pi6CydWhjWMnbTOR5 LXln7JkIpyWBgqy+4Wr14rjvy5vF44LDFeEVCtkFGmP/xVHhoRc0UdKYSFRxQBb6LE tExxXn0tiIRu2Oqt5frj98+5mgfKw4kcHfI+CXZIrle/imk4dKBi0gRMX2Wq2z0kk8 G8xgM/60nUIb5oxj6Onyc4jifXi23ZJ0NxCENT7C4BC2AA3k+g2462IvHOUh5WmF7S iv4XkKxDnM6lw== X-Nifty-SrcIP: [133.32.177.133] From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Nathan Chancellor , Nick Desaulniers , Nicolas Schier , Peter Zijlstra , linux-modules@vger.kernel.org, llvm@lists.linux.dev, Ard Biesheuvel , Sami Tolvanen , Masahiro Yamada Subject: [PATCH v6 04/10] genksyms: adjust the output format to modpost Date: Fri, 13 May 2022 20:39:24 +0900 Message-Id: <20220513113930.10488-5-masahiroy@kernel.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20220513113930.10488-1-masahiroy@kernel.org> References: <20220513113930.10488-1-masahiroy@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE, T_SCC_BODY_TEXT_LINE autolearn=no 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 Make genksyms output symbol versions in the format modpost expects, so the 'sed' is unneeded. This commit makes *.symversions completely unneeded. I will keep *.symversions in .gitignore and 'make clean' for a while. Otherwise, 'git status' might be surprising. Signed-off-by: Masahiro Yamada Reviewed-by: Nicolas Schier Tested-by: Nathan Chancellor --- (no changes since v2) Changes in v2: - New patch scripts/Makefile.build | 6 ------ scripts/genksyms/genksyms.c | 2 +- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/scripts/Makefile.build b/scripts/Makefile.build index dff9220135c4..461998a2ad2b 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@ -165,16 +165,10 @@ ifdef CONFIG_MODVERSIONS # o modpost will extract versions from that file and create *.c files that will # be compiled and linked to the kernel and/or modules. -genksyms_format := __crc_\(.*\) = \(.*\); - gen_symversions = \ if $(NM) $@ 2>/dev/null | grep -q __ksymtab; then \ $(call cmd_gensymtypes_$(1),$(KBUILD_SYMTYPES),$(@:.o=.symtypes)) \ - > $@.symversions; \ - sed -n 's/$(genksyms_format)/$(pound)SYMVER \1 \2/p' $@.symversions \ >> $(dot-target).cmd; \ - else \ - rm -f $@.symversions; \ fi cmd_gen_symversions_c = $(call gen_symversions,c) diff --git a/scripts/genksyms/genksyms.c b/scripts/genksyms/genksyms.c index 67b23cc0df0f..f5dfdb9d80e9 100644 --- a/scripts/genksyms/genksyms.c +++ b/scripts/genksyms/genksyms.c @@ -680,7 +680,7 @@ void export_symbol(const char *name) if (flag_dump_defs) fputs(">\n", debugfile); - printf("__crc_%s = 0x%08lx;\n", name, crc); + printf("#SYMVER %s 0x%08lx\n", name, crc); } } -- 2.32.0