From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932185AbcGFNxj (ORCPT ); Wed, 6 Jul 2016 09:53:39 -0400 Received: from mout.kundenserver.de ([217.72.192.75]:53859 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755145AbcGFNxh (ORCPT ); Wed, 6 Jul 2016 09:53:37 -0400 From: Arnd Bergmann To: Josh Triplett Cc: Michal Marek , "Yann E. MORIN" , Masahiro Yamada , Darren Hart , linux-kbuild@vger.kernel.org, kernel-build-reports@lists.linaro.org, Michal Marek , Thiago Macieira , linux-kernel@vger.kernel.org Subject: Re: [PATCH] [RFC] Kbuild: avoid "make tinyconfig" warnings Date: Wed, 06 Jul 2016 15:56:25 +0200 Message-ID: <7677316.bvNVmygFDv@wuerfel> User-Agent: KMail/5.1.3 (Linux/4.4.0-22-generic; KDE/5.18.0; x86_64; ; ) In-Reply-To: <20160704195815.GA10294@x> References: <20160704142608.2069991-1-arnd@arndb.de> <20160704195156.GA10164@x> <20160704195815.GA10294@x> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Provags-ID: V03:K0:LU5aZOX4NHLrBn2j0QVOSkwB3Av4Ng8SImLs942cb3zokKe21GY KzQoneqX0nMDkQxemIBfcGX7wigWmMml/nNUUvcgbel5xGHXmlt95ChU0GtZJ/jMj1uOof5 FKqOFBdV5I5DLKaYfu7hf5H+3IVkxcPfaoxR69oQGiDABQWfvxTrvUsX6AuiznjdSLltOhf 6twjDs3txLUO5izOuichg== X-UI-Out-Filterresults: notjunk:1;V01:K0:vdEXqs3uDSk=:XgeHvG68POWI9DY+k77u/Y ohadSeqv1CP07YUbTidrKStXnqIBFXJrYW06xjyxMiD+MD/GKHc3xttGdHDl1PzYLsSbcJ6SU qKU3XIhgRR8Xhn23RXh2xK3DTapTh9vQlrC85mfKmAxP1YH83V7O3ryY/BE8IEzdZS6zToe77 N7rwEeOXAppzr99qcZ7Hnz3adpQbwRzm4PU+b/NV9lMA6bGyfL0pr6u170F5vkJZgy96cbsde 2xVx2dXHAtmc+20dIYGPDLQGcFjf4yXCY5d7qtLCnwVzIgmHAExhhD3jRa3HbGb9CMm5kG0fC MjWfekyudLRB+vQzE9z83EN388y+gALE9UMKqx3m/G2QHDJNfWaeHfRvIhhcti3UIKwNnCTtw jYV9wysalQ7ulSUsa5vwjRFeX8Uy52aIxlunw0yIsqRe/ZPMB1w1wzyQwErvTqGYdWg9/NQ67 xCnovrWLn2AbROjTe4Me1qfS0SGbxbvHGp0X+Vw7g5i+pmrJr/pbrjNLcOzPDU/KoHO4k+FSC HvKgNX+KUlCqxOAYWj4P/kF8ChfuE8vnsfM10oiKrilhWSjJBJL986psYqFZYXAVuFt3P+jvQ wiuGrlahn95YGFZSiyxNhba0+CfNniQg4B6cWTiSgx9wBcaPJsMIE/LuzbBc73OZO0SrRYNie M2W5Px5HWWVRb+E28ksymw86CjBURTR1oINlrZDe0VqlSVJxthp5GerLbO8OxctsohcGaaJct V6LKd6IFTyzF4v94 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Monday, July 4, 2016 12:58:15 PM CEST Josh Triplett wrote: > On Mon, Jul 04, 2016 at 12:51:56PM -0700, Josh Triplett wrote: > > On Mon, Jul 04, 2016 at 04:25:55PM +0200, Arnd Bergmann wrote: > > > The introduction of "make *.config" as a shorthand for merging configuration > > > files unfortunately introduced some build warnings that we see in every > > > single run of the various build bots testing tinyconfig: > > > > > > .config:966:warning: override: NOHIGHMEM changes choice state > > > .config:965:warning: override: SLOB changes choice state > > > .config:963:warning: override: KERNEL_XZ changes choice state > > > .config:962:warning: override: CC_OPTIMIZE_FOR_SIZE changes choice state > > > .config:933:warning: override: SLOB changes choice state > > > .config:930:warning: override: CC_OPTIMIZE_FOR_SIZE changes choice state > > > .config:870:warning: override: SLOB changes choice state > > > .config:868:warning: override: KERNEL_XZ changes choice state > > > .config:867:warning: override: CC_OPTIMIZE_FOR_SIZE changes choice state > > > > > > This changes the behavior for tinyconfig again, so we call the special > > > allnoconfig target directly, with the fragment as the KCONFIG_ALLCONFIG > > > file so it gets merged into the configuration. The disadvantage of > > > this approach is that we cannot pass another KCONFIG_ALLCONFIG on > > > the command line, that would again have to be done using the mergeconfig > > > script afterwards. > > > > > > Signed-off-by: Arnd Bergmann > > > Fixes: 63a91033d52e ("kbuild: add generic mergeconfig target, %.config") > > > Link: https://storage.kernelci.org/mainline/v4.7-rc6/x86-tinyconfig/build.log > > > > Thanks for fixing this. > > Reviewed-by: Josh Triplett > > > > As another possibility, which would preserve the ability to use > > KCONFIG_ALLCONFIG, what about adding a parameter to mergeconfig to > > disable this warning? I've seen many other uses of mergeconfig in > > production systems that have the same problem. > > Actually, I just realized something: does this actually do the right > thing if both tiny.config files exist? The documentation for > KCONFIG_ALLCONFIG doesn't suggest that it can take two files as > arguments. And if it can, this also need quotes; otherwise, this will > expand to "... allnoconfig KCONFIG=path/to/a/tiny.config > another/path/to/a/tiny.config". You are right, my patch doesn't work. I can think of a few other ways to work around this, though none seems perfect: - add a flag to the kconfig tool to ignore 'choice' symbol overrides and not warn about them (as you suggested). This may be problematic if there are cases in which the warning is actually helpful. - drop the feature of allowing multiple tiny.config files to be combined and instead have the x86 file include everything from the architecture independent file. This would only be a small annoyance, but it doesn't solve the other cases you mention in which we see similar warnings. - merge the fragments first and then use the combined fragment as the KCONFIG_ALLCONFIG file. - change merge_config.sh to do a 'savedefconfig' step before applying the fragment, so it doesn't warn about choice statements that are overridden from their default, as opposed to having conflicting choices. Arnd