From patchwork Tue Jul 18 16:58:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Michal_Such=C3=A1nek?= X-Patchwork-Id: 122156 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:c923:0:b0:3e4:2afc:c1 with SMTP id j3csp1897563vqt; Tue, 18 Jul 2023 10:23:08 -0700 (PDT) X-Google-Smtp-Source: APBJJlG/rbJXWP2EStCHwTeW78dQR6vQBqGP6MzGadEh32oIfzCv00vxqEIbUcgcZO4ez7vHYuOX X-Received: by 2002:a17:906:1d5:b0:987:4e89:577f with SMTP id 21-20020a17090601d500b009874e89577fmr400343ejj.24.1689700987965; Tue, 18 Jul 2023 10:23:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689700987; cv=none; d=google.com; s=arc-20160816; b=WMQJL9UOgb5LpidW1OpdY5tbk/EGujLbZTxm4WK9LpUdvvV2Ht339Lx0O4toMPiIe7 aqqDzO99G5ih0Q9HEhP21oR7Pj+r6CL6qcuKhPEGTSCGsBw+faDX2icd5d9U7I+ZimoN efYjcctYpuCk+q4EVVlJlnHXLJgORRX/nQNeAVJk3xPTeWzYkryKfM2meZNkt3VXV9EC 7gsHNeYmAI9PQKkzXazbpeSyUucLobmUZwR/3vX+OK4NUdMxksZm0mKvIitAmEP1An/0 zORh3dDxcaqpKe7+GTh//Po7aF3aKjCnZOQBzDpayk8FRfp3nbMi54zIJgaQ1Vb/pmbd zobA== 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 :message-id:date:subject:cc:to:from:dkim-signature:dkim-signature; bh=OjGGhMViPLhUrPIXcS8z7NODS9q5SOF67JHp0ks1PI4=; fh=dD+9AN046j8n9gjo4PXiEMm7HPkIRBb0wkxe5qg+w7w=; b=fAjchx2OOugizB8xldItfUt6lf5GPLWKOvuZLvWGvcdYBu50QMq7LV/E/Y81CytQKA CNmXnEM6LhOLpy4P8wvwhWstLxnaZwwkgXLMXFELWUAgsyJLIvc++BS7KGP/SzS6BoEK gtH2aeoTI/rkNpMZ1RDTeqk1+FXfIhZ1pinXUEEzcVSzd45tEDhbRQlTX9P1m+PrglO7 xaHwTncreRkqo9ifXMaEvuK8nnJuA/4557VVtpNRMbhVAJwvVFtcgIW6CWXKp6uxJiYF +8BBZUS+jLSkIUAhHYya2Xd2MDcz9l1INKWGBCwuqDuv7MMKe0duwSCvGi5MEo1hM0Qk 1Rcg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=Z1AD8OXw; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=ssCmNkTz; 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=suse.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id jr1-20020a170906a98100b00992c7f7356dsi1581298ejb.8.2023.07.18.10.22.44; Tue, 18 Jul 2023 10:23:07 -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=@suse.de header.s=susede2_rsa header.b=Z1AD8OXw; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=ssCmNkTz; 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=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233676AbjGRRBW (ORCPT + 99 others); Tue, 18 Jul 2023 13:01:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35526 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233586AbjGRRBD (ORCPT ); Tue, 18 Jul 2023 13:01:03 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E25B730DA; Tue, 18 Jul 2023 09:59:51 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id DCB8021881; Tue, 18 Jul 2023 16:58:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1689699535; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=OjGGhMViPLhUrPIXcS8z7NODS9q5SOF67JHp0ks1PI4=; b=Z1AD8OXwd6DHhwZq/f7992l/3BmBVSoKE5G67annpEQNKuLGK7S9JZ1/N8Y1KIiihVmDxR Pf8a1q8vXuMPTje3oYe6Z868UncHiG9bLZsMamx3n3sIINFXM6yQ6jYgCZb2Zbo1HiWDm8 ixfhtr1iGOMpnJMC5O7FDuSDfOJwKZQ= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1689699535; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=OjGGhMViPLhUrPIXcS8z7NODS9q5SOF67JHp0ks1PI4=; b=ssCmNkTziPWWcXWWv3q2FZ/WICV6qp5Fl7Z3F45oSeXgThh2qMgWACclIFF/tneCRqkaHX YbdiUSthM8trrvDQ== Received: from kitsune.suse.cz (kitsune.suse.cz [10.100.12.127]) by relay2.suse.de (Postfix) with ESMTP id ABC082C142; Tue, 18 Jul 2023 16:58:55 +0000 (UTC) From: Michal Suchanek To: linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org Cc: Michal Suchanek , Masahiro Yamada Subject: [PATCH] Revert "kbuild: Hack for depmod not handling X.Y versions" Date: Tue, 18 Jul 2023 18:58:43 +0200 Message-ID: <20230718165848.14392-1-msuchanek@suse.de> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1771779903454681401 X-GMAIL-MSGID: 1771779903454681401 Remove hack for ancient version of module-init-tools that was added in Linux 3.0. Since then module-init-tools was replaced with kmod. This hack adds an additional indirection, and causes confusing errors to be printed when depmod fails. Reverts commit 8fc62e594253 ("kbuild: Do not write to builddir in modules_install") Reverts commit bfe5424a8b31 ("kbuild: Hack for depmod not handling X.Y versions") Link: https://lore.kernel.org/linux-modules/CAK7LNAQMs3QBYfWcLkmOQdbbq7cj=7wWbK=AWhdTC2rAsKHXzQ@mail.gmail.com/ Signed-off-by: Michal Suchanek --- scripts/depmod.sh | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/scripts/depmod.sh b/scripts/depmod.sh index 3643b4f896ed..fca689ba4f21 100755 --- a/scripts/depmod.sh +++ b/scripts/depmod.sh @@ -23,33 +23,8 @@ if [ -z $(command -v $DEPMOD) ]; then exit 0 fi -# older versions of depmod require the version string to start with three -# numbers, so we cheat with a symlink here -depmod_hack_needed=true -tmp_dir=$(mktemp -d ${TMPDIR:-/tmp}/depmod.XXXXXX) -mkdir -p "$tmp_dir/lib/modules/$KERNELRELEASE" -if "$DEPMOD" -b "$tmp_dir" $KERNELRELEASE 2>/dev/null; then - if test -e "$tmp_dir/lib/modules/$KERNELRELEASE/modules.dep" -o \ - -e "$tmp_dir/lib/modules/$KERNELRELEASE/modules.dep.bin"; then - depmod_hack_needed=false - fi -fi -rm -rf "$tmp_dir" -if $depmod_hack_needed; then - symlink="$INSTALL_MOD_PATH/lib/modules/99.98.$KERNELRELEASE" - ln -s "$KERNELRELEASE" "$symlink" - KERNELRELEASE=99.98.$KERNELRELEASE -fi - set -- -ae -F System.map if test -n "$INSTALL_MOD_PATH"; then set -- "$@" -b "$INSTALL_MOD_PATH" fi -"$DEPMOD" "$@" "$KERNELRELEASE" -ret=$? - -if $depmod_hack_needed; then - rm -f "$symlink" -fi - -exit $ret +exec "$DEPMOD" "$@" "$KERNELRELEASE"