ksummit.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab@s-opensource.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Christoph Hellwig <hch@infradead.org>,
	ksummit <ksummit-discuss@lists.linuxfoundation.org>,
	Cristina Moraru <cristina.moraru09@gmail.com>,
	Michal Hocko <mhocko@kernel.org>
Subject: Re: [Ksummit-discuss] [TECH TOPIC] is Kconfig a bit hard sometimes?
Date: Thu, 29 Jun 2017 07:23:20 -0300	[thread overview]
Message-ID: <20170629072320.22ac0049@vento.lan> (raw)
In-Reply-To: <CA+55aFxDyj-9koeDemqUvxYrLyKxV8Xggy=ad_EQmGrfEef_gg@mail.gmail.com>

Em Tue, 27 Jun 2017 14:36:44 -0700
Linus Torvalds <torvalds@linux-foundation.org> escreveu:

> On Tue, Jun 27, 2017 at 2:16 PM, Olof Johansson <olof@lixom.net> wrote:
> >
> > It sounds to me like you want to turn it from option/driver selection
> > to feature selection, where features could be stuff like:
> >
> > So, a meta config layer if seen in the context of our current config system.  
> 
> Yes.
> 
> Most people are really bad at knowing details, but they may well know
> some big-picture stuff. They can certainly answer questions like "do
> you have a laptop", and "does it have a PCMCIA card slot".
> 
> They might even be able to answer some HW specifics ("Is it 64-bit?"
> "Is the CPU an Intel/AMD or ARM chip?").

Perhaps we could add some "hint" questions at the very beginning of Kconfig
that would give some hints about the kind of usage the user expects.

E. g. asking if the Kernel is for the local machine. If so, it could look at
the cpu model at /proc/cpuinfo and take a set of defaults for that
specific model.

It could also have menu selections that would allow to select the type
of usage (customer PC, laptop, server, custom hardware, ...) and the
distro, in order to load some specific set of defaults for ARCH and
core-dependent features, and allow taking some "hints" at driver's level.

With those hints subsystem Kconfigs could use such information to take
automatic decisions about what should be enabled by default, and even
hide technical questions.

That's easier said than done, as implementing the hints logic can be
painful.

If we take such way, one open question is wow to tell Kconfig to read
/proc/cpuinfo or to run lspci/lsusb. Perhaps the simplest way would be
to add some dialect at Kconfig that would make it run a script if 
a Kconfig symbol has its value changed, and restart Kconfig after
the end of the script. This way, such script could internally modify
.config, in order to tweak the defaults.

Thanks,
Mauro

  parent reply	other threads:[~2017-06-29 10:23 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-27 13:58 Sergey Senozhatsky
2017-06-27 17:18 ` Linus Torvalds
2017-06-27 18:44   ` Luis R. Rodriguez
2017-06-27 19:27     ` Linus Torvalds
2017-06-27 20:53       ` Kees Cook
2017-06-27 21:16       ` Olof Johansson
2017-06-27 21:36         ` Linus Torvalds
2017-06-27 23:10           ` Serge E. Hallyn
2017-06-28  0:09             ` Luis R. Rodriguez
2017-06-28  0:14               ` Linus Torvalds
2017-06-28  0:26                 ` Luis R. Rodriguez
2017-06-28  3:54                   ` Stephen Hemminger
     [not found]                 ` <CAFhKne-o0S8fMo_XD_aUk2Rf7VbDhgO+PT_bjnM-9WpKfnWBvw@mail.gmail.com>
     [not found]                   ` <CAFhKne8FE=17wNdp=Svf2Z2tADok6htfYqTABEiZUrCOyeMaYg@mail.gmail.com>
2017-06-28 13:35                     ` Matthew Wilcox
2017-06-28 17:56                 ` Geert Uytterhoeven
2017-06-29 10:02                   ` Mauro Carvalho Chehab
2017-06-28  0:11             ` Linus Torvalds
2017-06-29 10:23           ` Mauro Carvalho Chehab [this message]
2017-06-28 12:58     ` Dan Carpenter
2017-06-30 17:11   ` Steven Rostedt
2017-06-30 17:52   ` Darren Hart
2017-06-30 17:58     ` Darren Hart
2017-07-01 17:24     ` Hannes Reinecke
2017-06-27 20:41 ` Kees Cook
2017-07-06 14:40 ` Dan Carpenter
2017-07-06 14:41   ` [Ksummit-discuss] [PATCH 1/2] kconfig: add a silent option to conf_write() Dan Carpenter
2017-07-06 15:08     ` Steven Rostedt
2017-07-06 14:42   ` [Ksummit-discuss] [PATCH 2/2] kconfig: new command line kernel configuration tool Dan Carpenter
2017-07-07  5:55     ` Krzysztof Kozlowski
2017-07-07  9:02       ` Dan Carpenter
2017-07-09  3:56         ` Linus Walleij
2017-07-09  8:31           ` Geert Uytterhoeven
2017-07-09 17:03             ` Randy Dunlap
2017-07-09 19:43               ` Geert Uytterhoeven
2017-07-09 17:32             ` Frank Rowand
2017-07-10  9:44     ` Geert Uytterhoeven
2017-07-10 11:15       ` Dan Carpenter
2017-07-06 16:41   ` [Ksummit-discuss] [TECH TOPIC] is Kconfig a bit hard sometimes? Linus Torvalds
2017-07-06 17:11     ` Randy Dunlap
2017-07-07 11:36     ` Dan Carpenter
2017-07-10 17:15       ` Luck, Tony
2017-07-10 17:33         ` Alexandre Belloni
2017-07-10 18:28           ` Linus Torvalds
2017-07-10 19:44             ` Randy Dunlap
2017-07-11  6:21             ` Valentin Rothberg
2017-07-06 21:19   ` Laurent Pinchart

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=20170629072320.22ac0049@vento.lan \
    --to=mchehab@s-opensource.com \
    --cc=cristina.moraru09@gmail.com \
    --cc=hch@infradead.org \
    --cc=ksummit-discuss@lists.linuxfoundation.org \
    --cc=mhocko@kernel.org \
    --cc=torvalds@linux-foundation.org \
    /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