From patchwork Sun Jun 23 16:13:27 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 167525 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp3184910ilk; Sun, 23 Jun 2019 09:13:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqxGa40iSORYofTq+tmK+QV0V+vyHkch+uuturwjySWy4uEM28dnyabfZxBQjYsA+kAnb52W X-Received: by 2002:a17:90a:26ef:: with SMTP id m102mr19196165pje.50.1561306421672; Sun, 23 Jun 2019 09:13:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561306421; cv=none; d=google.com; s=arc-20160816; b=xhyPAKjTTm9YSVk6p0SGKfadkNvc3PlVRUEleLApnKyE76+lCzLn2bkVMtbMchpDel nsJoXbsV8HSy8G6DapaMJGs1nNhpeFlbAQ7yrBgGyfOFgKgJNz00ZQDO3zcXVlFoJ5Cx NOZFyzORh85cs4NBhgaNSH45NAV8TMufq9KYsTLxJ9Qv28k+daZoQJaR00sQpXgOp0jl sA/MR8uIrlGfi0m8N8aG2lS5Byay1HzyqrSfM7Uo1W96M8THGT5WvYAvXxrNDZ9DTSYy j+fOYWvY4xYNeG997wpYJtgA4wUhh7YQDkNJ/CsVpIn8+kMpVXNAzIIZLFpEwffJFMIG 2grg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:dkim-filter; bh=jqiQ1y5oNfRR0g7lME/nEDNqOJEW6bjlbalGJ20HGQ0=; b=TJNpJrCyt8J2KMqEdmMbPh8lJTcr9Pa/FbLwQeCzg/ARxgrRaSd+wfR0PkeqCI5Aqc vlxRcBKr2e3L38M17D7BHr55e9apvpGUJmi9f8nentZNn9aTS07VLlRAjBCend/kFvNm gtwhfzmdHVBaE3MbSh8GnAOBb1IJ8wy0pdpvkWtZ0YOyLT82ZXcJ1qIwwDp1uGkAVQjD 7fnI4/bI5xGxd7YYSKGXYeY60aglPzTZX/Rnm6r18p8Ko6egpFaM8WxZLP4vog7X1cDI lPWhwhRL7H/xyR4KayaNITLYja390FvnaagTvht5OCZLVlxvXhJ2hJEcvHGxsmSgXgGE VhTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=xDxG0siw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i18si8449153pfr.65.2019.06.23.09.13.41; Sun, 23 Jun 2019 09:13:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=xDxG0siw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726702AbfFWQNj (ORCPT + 30 others); Sun, 23 Jun 2019 12:13:39 -0400 Received: from conuserg-09.nifty.com ([210.131.2.76]:23058 "EHLO conuserg-09.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726647AbfFWQNi (ORCPT ); Sun, 23 Jun 2019 12:13:38 -0400 Received: from grover.flets-west.jp (softbank126125154139.bbtec.net [126.125.154.139]) (authenticated) by conuserg-09.nifty.com with ESMTP id x5NGDU0w024279; Mon, 24 Jun 2019 01:13:30 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-09.nifty.com x5NGDU0w024279 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1561306410; bh=jqiQ1y5oNfRR0g7lME/nEDNqOJEW6bjlbalGJ20HGQ0=; h=From:To:Cc:Subject:Date:From; b=xDxG0siw4cbp7po2wAgeT49KgFRCeqsPlrhZEwuZggbYGoHPmGabUijA79H8aOPgE 043ZeuEXYhloNDl93C987jGila8l9k6Y/w8ggnmssC4Bi84UxraxZcDh3fE+dD9Sqc 3gMDLiFYOK7Go3ya81r/l+RVnLl614U3qJI0IdHweL8YBZ0WY6mgyKwjGEM0fK0L9i T+kBWj4+seEbUFVV7O8kBFQ6/2B1yknD4ywlPF1PVT4OJ5Q0z6BE/XcwPEtSl6Y+9Y GplBE7YI11RrvZollgtMH3zvUysZa23pN6m++1tg+gNrJ90BOOB9Z0srA1pN6yea+F Wf5HvEaiFhrZg== X-Nifty-SrcIP: [126.125.154.139] From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: Masahiro Yamada , Michal Marek , linux-kernel@vger.kernel.org Subject: [PATCH 1/2] kbuild: fix missed rebuild of modules.builtin Date: Mon, 24 Jun 2019 01:13:27 +0900 Message-Id: <20190623161328.22461-1-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Unlike modules.order, modules.builtin is not rebuilt every time. Once modules.builtin is created, it will not be updated until auto.conf or tristate.conf is changed. So, it misses to notice a change in Makefile, for example, renaming of modules. Kbuild must always descend into directories for modules.builtin too. Signed-off-by: Masahiro Yamada --- Makefile | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) -- 2.17.1 diff --git a/Makefile b/Makefile index 9514dac2660a..19c33bc69bb1 100644 --- a/Makefile +++ b/Makefile @@ -1289,12 +1289,16 @@ modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $(Q)$(CONFIG_SHELL) $(srctree)/scripts/modules-check.sh -modules.builtin: $(vmlinux-dirs:%=%/modules.builtin) - $(Q)$(AWK) '!x[$$0]++' $^ > $(objtree)/modules.builtin +modbuiltin-dirs := $(addprefix _modbuiltin_, $(vmlinux-dirs)) -%/modules.builtin: include/config/auto.conf include/config/tristate.conf - $(Q)$(MAKE) $(modbuiltin)=$* +modules.builtin: $(modbuiltin-dirs) + $(Q)$(AWK) '!x[$$0]++' $(addsuffix /$@, $(vmlinux-dirs)) > $@ +PHONY += $(modbuiltin-dirs) +# tristate.conf is not included from this Makefile. Add it as a prerequisite +# here to make it self-healing in case somebody accidentally removes it. +$(modbuiltin-dirs): include/config/tristate.conf + $(Q)$(MAKE) $(modbuiltin)=$(patsubst _modbuiltin_%,%,$@) # Target to prepare building external modules PHONY += modules_prepare From patchwork Sun Jun 23 16:13:28 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 167526 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp3184958ilk; Sun, 23 Jun 2019 09:13:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqxn84jI+PlwDEUfGdsI91ZLUHALvKRCa6AYNStZrSxKE06tBWY6SrIaoM+kNmwJCQH62kGT X-Received: by 2002:a63:4c15:: with SMTP id z21mr871486pga.87.1561306424885; Sun, 23 Jun 2019 09:13:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561306424; cv=none; d=google.com; s=arc-20160816; b=qtraUlle/kD70mClK3E4n6goKEZQKhturQOOFu35GHj3BQaE+aPU1PAHRh0Y78M8TD JuzqWNQWvFDqMDTaYFBRL1fxYzWxODYi/V6Kh7cvxWUrbhkqJALvEHDjc+XzVy7hXnrq 9qvbStxCC0N98i73HkRjXB5oEavRQaoMtnF41CQqyk+XY6JUjLmKhUJpnJlGybX96p7p 2raqWIkiS5IshGC8LTOxbLFKct5YZ+dtg50zNYgVWwb9eu+Siz5h7yBShEGfZG2SrSQr UDDRZjoEyfRPlNiBng+eNrVvFd8H2tMv7X/H0VbAqKq7zmMdBynfVxZej6d7hMghrtMX UGVA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter; bh=meEmv4m9X6eizB8GzJ2MviWJJ0JI6pOOoAMXbmBaZcU=; b=F/RnD/Er73faUMfbm2KWhXjzFNa5v2g6fPGpd7AcyWF2l0WuXeld9GQQ+3xOx45xzq 6s/0dciEmCcTkJhuYvI9OdVT/OKMrlqFvmCiLoVHGjZBtr+NGzoTT4eC3jIicEH85W5v WG5evoiNZJc1Q8CWQkjJriZL3LX/PgLApFPQK955soWs5UpLQUnvF7nYvO5pb6E+rup6 VwVGJgGL/jKm74GlXM10Lf1gIrRojETv7fhbghc0/qtHIkjGXT1H4eRO31ZKvy3FKadN cT15d5IsO2J82H8XIuBZBTkmG2jih2JfJDM893sOoE0q0oB/3JhleJpBhAc2zpBr21GF VW5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=QVWGkYTb; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b20si3065319pfo.108.2019.06.23.09.13.44; Sun, 23 Jun 2019 09:13:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=QVWGkYTb; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726675AbfFWQNj (ORCPT + 30 others); Sun, 23 Jun 2019 12:13:39 -0400 Received: from conuserg-09.nifty.com ([210.131.2.76]:23057 "EHLO conuserg-09.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726631AbfFWQNi (ORCPT ); Sun, 23 Jun 2019 12:13:38 -0400 Received: from grover.flets-west.jp (softbank126125154139.bbtec.net [126.125.154.139]) (authenticated) by conuserg-09.nifty.com with ESMTP id x5NGDU0x024279; Mon, 24 Jun 2019 01:13:31 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-09.nifty.com x5NGDU0x024279 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1561306411; bh=meEmv4m9X6eizB8GzJ2MviWJJ0JI6pOOoAMXbmBaZcU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QVWGkYTbzlsmLJsvT0hCaLAXrAk/ju97Hv6WYfmXhx4dz+Oj1w7YGmXDj3tXufIHT 4iWgSuaLRQ87jU2W0Z5MKumZl1tmVqr/TVzBUOj7bUdaZqI37zkpuLPJ39FNmm7AIX Z2TSsKRe5/EgQ23piXwkrvJ+6rwHYseCmSvhStrCEzsZeVgMvQlLftifzN+2SJt/5B CZf5Hr0oy92/sS7TPD0XPx3itJr1+cPR+OVE+rHaeIs8sE9zfBr/JOETG+cPztrl8j uFss/g+w5FIzXAqTbgwmhsysY9MqY1gxRwKWZtnvK5pmgqrc/0KSLweUEoom3ef5+1 /caHML3T4zgeA== X-Nifty-SrcIP: [126.125.154.139] From: Masahiro Yamada To: linux-kbuild@vger.kernel.org Cc: Masahiro Yamada , Michal Marek , linux-kernel@vger.kernel.org Subject: [PATCH 2/2] kbuild: split modules.order build rule out of 'modules' target Date: Mon, 24 Jun 2019 01:13:28 +0900 Message-Id: <20190623161328.22461-2-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190623161328.22461-1-yamada.masahiro@socionext.com> References: <20190623161328.22461-1-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Merge the build rules of modules.order and modules.builtin Signed-off-by: Masahiro Yamada --- Makefile | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) -- 2.17.1 diff --git a/Makefile b/Makefile index 19c33bc69bb1..6bfe22b852f2 100644 --- a/Makefile +++ b/Makefile @@ -1283,16 +1283,18 @@ all: modules # using awk while concatenating to the final file. PHONY += modules -modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin - $(Q)$(AWK) '!x[$$0]++' $(vmlinux-dirs:%=$(objtree)/%/modules.order) > $(objtree)/modules.order +modules: $(if $(KBUILD_BUILTIN),vmlinux) modules.order modules.builtin @$(kecho) ' Building modules, stage 2.'; $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $(Q)$(CONFIG_SHELL) $(srctree)/scripts/modules-check.sh -modbuiltin-dirs := $(addprefix _modbuiltin_, $(vmlinux-dirs)) +modules.order modules.builtin: + $(Q)$(AWK) '!x[$$0]++' $(addsuffix /$@, $(vmlinux-dirs)) > $@ + +modules.order: $(vmlinux-dirs) +modbuiltin-dirs := $(addprefix _modbuiltin_, $(vmlinux-dirs)) modules.builtin: $(modbuiltin-dirs) - $(Q)$(AWK) '!x[$$0]++' $(addsuffix /$@, $(vmlinux-dirs)) > $@ PHONY += $(modbuiltin-dirs) # tristate.conf is not included from this Makefile. Add it as a prerequisite