From mboxrd@z Thu Jan 1 00:00:00 1970 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 A6DE2EB64DC for ; Sat, 22 Jul 2023 12:00:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230345AbjGVMA4 (ORCPT ); Sat, 22 Jul 2023 08:00:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37644 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230353AbjGVMAv (ORCPT ); Sat, 22 Jul 2023 08:00:51 -0400 Received: from 1wt.eu (ded1.1wt.eu [163.172.96.212]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 2269730C4; Sat, 22 Jul 2023 05:00:47 -0700 (PDT) Received: (from willy@localhost) by pcw.home.local (8.15.2/8.15.2/Submit) id 36MC0bDQ017318; Sat, 22 Jul 2023 14:00:37 +0200 Date: Sat, 22 Jul 2023 14:00:37 +0200 From: Willy Tarreau To: Zhangjin Wu Cc: thomas@t-8ch.de, arnd@arndb.de, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, Thomas =?iso-8859-1?Q?Wei=DFschuh?= Subject: Re: [PATCH v1 4/8] selftests/nolibc: add extra config file customize support Message-ID: <20230722120037.GA17311@1wt.eu> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 19, 2023 at 05:14:07AM +0800, Zhangjin Wu wrote: > The default DEFCONFIG_ may not always work for all architectures, > some architectures require to add extra kernel config options, this adds > a new 'extconfig' target for this requirement. > > It allows to customize extra kernel config options via the common > common.config and the architecture specific .config, at last > trigger 'allnoconfig' to let them take effect with missing config > options as disabled. > > The scripts/kconfig/merge_config.sh tool is used to merge the extra > config files. > > Suggested-by: Thomas Weißschuh > Link: https://lore.kernel.org/lkml/67eb70d4-c9ff-4afc-bac7-7f36cc2c81bc@t-8ch.de/ > Signed-off-by: Zhangjin Wu > --- > tools/testing/selftests/nolibc/Makefile | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selftests/nolibc/Makefile > index f42adef87e12..08a5ca5f418b 100644 > --- a/tools/testing/selftests/nolibc/Makefile > +++ b/tools/testing/selftests/nolibc/Makefile > @@ -39,6 +39,9 @@ DEFCONFIG_s390 = defconfig > DEFCONFIG_loongarch = defconfig > DEFCONFIG = $(DEFCONFIG_$(ARCH)) > > +# extra kernel config files under configs/, include common + architecture specific > +EXTCONFIG = common.config $(ARCH).config > + > # optional tests to run (default = all) > TEST = > > @@ -162,6 +165,10 @@ initramfs: nolibc-test > defconfig: > $(Q)$(MAKE) -C $(srctree) ARCH=$(ARCH) CC=$(CC) CROSS_COMPILE=$(CROSS_COMPILE) mrproper $(DEFCONFIG) prepare > > +extconfig: > + $(Q)$(srctree)/scripts/kconfig/merge_config.sh -O "$(srctree)" -m "$(srctree)/.config" $(foreach c,$(EXTCONFIG),$(wildcard $(CURDIR)/configs/$c)) > + $(Q)$(MAKE) -C $(srctree) ARCH=$(ARCH) CC=$(CC) CROSS_COMPILE=$(CROSS_COMPILE) KCONFIG_ALLCONFIG="$(srctree)/.config" allnoconfig > + Please also mention this entry in the "help" message. Other than that, OK. Willy