From patchwork Fri May 28 03:49:13 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 12286149 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1CC1BC47087 for ; Fri, 28 May 2021 03:51:54 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CF7406139A for ; Fri, 28 May 2021 03:51:53 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CF7406139A Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=e2uD9JL9uFVnZ/G8SI62DUcqHFpls0lbJNJsVZNRC9Y=; b=KUibJ7uW03Tpmh 4GREBi6ElEhTYdBMJzK0m6jTuvc+GgDyNUoxiqBLQ7vElNT9m5ar5+FzrID4Nmv0Cr9AcomOI3HQJ k4XWV2OUH6aCKPWHlqZDL8FLB0nQyj0OCoJ9k7tlvwnpYpdZMOyc6iNsJ/YrI7dKp6F83ma128uPX O1QnHLn+KyMPWUyrf+bxiuUNUdyIyRy5MYObhrQEV1HzxJzLU7jUrH/E7844QUfQYHIg6LzGNRRUV 6jyjy2iuZDglBSuNYFjn8SJIysqrJFQlDc3vzAl64Mx6vwk+ZVDtGzapUPw296rlos0U1uYVMy+G5 UeqzJqCAQ9YjBSVA4gFg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lmTVz-00BhDA-6M; Fri, 28 May 2021 03:50:27 +0000 Received: from conuserg-11.nifty.com ([210.131.2.78]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lmTVt-00BhAl-HO for linux-arm-kernel@lists.infradead.org; Fri, 28 May 2021 03:50:25 +0000 Received: from localhost.localdomain (133-32-232-101.west.xps.vectant.ne.jp [133.32.232.101]) (authenticated) by conuserg-11.nifty.com with ESMTP id 14S3nfb7025846; Fri, 28 May 2021 12:49:42 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-11.nifty.com 14S3nfb7025846 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1622173782; bh=nOwm0twLETAPHRynLa6fcg+8wECFXm1xLxM6UXBaq0c=; h=From:To:Cc:Subject:Date:From; b=eC3OPtc0ytnCD/7/zZXQSeVf/To0a0yY/+wUdhPSvru5cqh75ucrtQgtiOSLwD+r8 NCwBp+u7vzMetvgXKOgLFJK9NqYwgFqDPuc2Ig+BKgmlRrM/jITbcArosX/WLEoCEZ f9ftJQDNTlc+BZI+UTSW3jBgHdqNniWaB0oQKAvZ253ErzJJpPbLHXB1/cik/E4EWg 5ykkwYnUsMnmj98plCxh2/NOPTXMW/nncZA86GcyD7YHs65TJe77a1/Eqao+JphKTb ic37sVg0yIN5tm9EPQ5u+ju91u5AbI2UhBoxHGA6Hz4GTCMuxw3sBofn+BQw3y6c0L 80hKnOFePJVOw== X-Nifty-SrcIP: [133.32.232.101] From: Masahiro Yamada To: patches@arm.linux.org.uk Cc: linux-kernel@vger.kernel.org, Masahiro Yamada , Linus Walleij , Russell King , linux-arm-kernel@lists.infradead.org Subject: [PATCH] ARM: simplify the build rule of mach-types.h Date: Fri, 28 May 2021 12:49:13 +0900 Message-Id: <20210528034913.2157657-1-masahiroy@kernel.org> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210527_205021_811477_1A7719B1 X-CRM114-Status: GOOD ( 10.00 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The directory of mach-types.h is created a couple of lines above: _dummy := $(shell [ -d '$(kapi)' ] || mkdir -p '$(kapi)') \ The 'mkdir -p' command is redundant. scripts/Kbuild.include defines real-prereqs as a shorthand for $(filter-out $(PHONY),$^). Let's use it to simplify the code. Signed-off-by: Masahiro Yamada --- arch/arm/tools/Makefile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/arm/tools/Makefile b/arch/arm/tools/Makefile index 87de1f63f649..057639019059 100644 --- a/arch/arm/tools/Makefile +++ b/arch/arm/tools/Makefile @@ -33,8 +33,7 @@ _dummy := $(shell [ -d '$(kapi)' ] || mkdir -p '$(kapi)') \ $(shell [ -d '$(uapi)' ] || mkdir -p '$(uapi)') quiet_cmd_gen_mach = GEN $@ - cmd_gen_mach = mkdir -p $(dir $@) && \ - $(AWK) -f $(filter-out $(PHONY),$^) > $@ + cmd_gen_mach = $(AWK) -f $(real-prereqs) > $@ $(kapi)/mach-types.h: $(src)/gen-mach-types $(src)/mach-types FORCE $(call if_changed,gen_mach)