linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Michal Marek <mmarek@suse.cz>,
	Francis Galiegue <fgaliegue@gmail.com>,
	Andi Kleen <ak@linux.intel.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	linux-kbuild@vger.kernel.org,
	ppc-dev <linuxppc-dev@lists.ozlabs.org>,
	Li Zefan <lizf@cn.fujitsu.com>,
	LKML <linux-kernel@vger.kernel.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	Josh Triplett <josh@joshtriplett.org>,
	Vadim Bendebury <vbendeb@google.com>,
	Nir Tzachar <nir.tzachar@gmail.com>, Trevor Keith <tsrk@tsrk.net>,
	Jiri Kosina <jkosina@suse.cz>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linus <torvalds@linux-foundation.org>,
	Cheng Renquan <crquan@gmail.com>
Subject: Re: [RFC][PATCH] kconfig: implement select with values
Date: Tue, 27 Jul 2010 00:17:17 +0200	[thread overview]
Message-ID: <20100726221717.GA22439@merkur.ravnborg.org> (raw)
In-Reply-To: <20100720043706.3813715a.sfr@canb.auug.org.au>

On Tue, Jul 20, 2010 at 04:37:06AM +1000, Stephen Rothwell wrote:
> This is a fairly brute force approach to allowing a Kconfig "select"
> to specify an excplicit value for the selected config sybmol.
> 
> The syntax of select is changed to:
> 
> 	"select" <symbol> [<expr>] ["if" expr]
> 
> The approach taken is to add a list of <value, dependency expression>
> pairs to the symbol and check them whenever the reverse depends (from
> a current-style select) are checked.

I do not see the need for this feature.
I have read most of the postings in the defconfig battle and
I saw Linus' select suggestion.

But we can do almost all of this today (or tomorrow).

Consider following Kconfig file:

    config USB_SUPPORT
            def_bool n

    config NET
            def_bool y

    source arch/x86/Kconfig

We use the feature that we can specify the same
config option several times.
And the first default value that is "visible"
will be used.

So it allows us to enable and disable any option.

And if we for example want to set a specific LOG_BUF_SHIFT
we use the same trick:

    config LOG_BUF_SHIFT
            int
            default 14


Now in the original suggestion of Linus he used:

    KBUILD_KCONFIG=Mykconfig make allnoconfig

And "allnoconfig" would make the modified defaults useless.

But the soon-to-be-introduced alldefconfig is more sensible.

alldefconfig uses default values for everything.

So with alldefconfig I think we have all the features we need
to create sensible default configs in the Kconfig language.

And therefore I do not see the need for the extension to select.
For the same reason I did not look closer at the implementation.

	Sam

  reply	other threads:[~2010-07-26 22:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-19 18:37 [RFC][PATCH] kconfig: implement select with values Stephen Rothwell
2010-07-26 22:17 ` Sam Ravnborg [this message]
2010-07-26 22:47   ` Grant Likely
2010-07-27  6:45     ` Sam Ravnborg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100726221717.GA22439@merkur.ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=ak@linux.intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=catalin.marinas@arm.com \
    --cc=crquan@gmail.com \
    --cc=fgaliegue@gmail.com \
    --cc=jkosina@suse.cz \
    --cc=josh@joshtriplett.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=lizf@cn.fujitsu.com \
    --cc=mmarek@suse.cz \
    --cc=nir.tzachar@gmail.com \
    --cc=rostedt@goodmis.org \
    --cc=sfr@canb.auug.org.au \
    --cc=torvalds@linux-foundation.org \
    --cc=tsrk@tsrk.net \
    --cc=vbendeb@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).