1. 16 11月, 2016 1 次提交
    • N
      Kconfig: Introduce the "imply" keyword · 237e3ad0
      Nicolas Pitre 提交于
      The "imply" keyword is a weak version of "select" where the target
      config symbol can still be turned off, avoiding those pitfalls that come
      with the "select" keyword.
      
      This is useful e.g. with multiple drivers that want to indicate their
      ability to hook into a secondary subsystem while allowing the user to
      configure that subsystem out without also having to unset these drivers.
      
      Currently, the same effect can almost be achieved with:
      
      config DRIVER_A
      	tristate
      
      config DRIVER_B
      	tristate
      
      config DRIVER_C
      	tristate
      
      config DRIVER_D
      	tristate
      
      [...]
      
      config SUBSYSTEM_X
      	tristate
      	default DRIVER_A || DRIVER_B || DRIVER_C || DRIVER_D || [...]
      
      This is unwieldy to maintain especially with a large number of drivers.
      Furthermore, there is no easy way to restrict the choice for SUBSYSTEM_X
      to y or n, excluding m, when some drivers are built-in. The "select"
      keyword allows for excluding m, but it excludes n as well. Hence
      this "imply" keyword.  The above becomes:
      
      config DRIVER_A
      	tristate
      	imply SUBSYSTEM_X
      
      config DRIVER_B
      	tristate
      	imply SUBSYSTEM_X
      
      [...]
      
      config SUBSYSTEM_X
      	tristate
      
      This is much cleaner, and way more flexible than "select". SUBSYSTEM_X
      can still be configured out, and it can be set as a module when none of
      the drivers are configured in or all of them are modular.
      Signed-off-by: NNicolas Pitre <nico@linaro.org>
      Acked-by: NRichard Cochran <richardcochran@gmail.com>
      Acked-by: NThomas Gleixner <tglx@linutronix.de>
      Acked-by: NJohn Stultz <john.stultz@linaro.org>
      Reviewed-by: NJosh Triplett <josh@joshtriplett.org>
      Cc: Paul Bolle <pebolle@tiscali.nl>
      Cc: linux-kbuild@vger.kernel.org
      Cc: netdev@vger.kernel.org
      Cc: Michal Marek <mmarek@suse.com>
      Cc: Edward Cree <ecree@solarflare.com>
      Link: http://lkml.kernel.org/r/1478841010-28605-2-git-send-email-nicolas.pitre@linaro.orgSigned-off-by: NThomas Gleixner <tglx@linutronix.de>
      237e3ad0
  2. 11 5月, 2016 1 次提交
    • D
      kconfig/symbol.c: handle choice_values that depend on 'm' symbols · fa64e5f6
      Dirk Gouders 提交于
      If choices consist of choice_values of type tristate that depend on
      symbols set to 'm', those choice_values are not set to 'n' if the
      choice is changed from 'm' to 'y' (in which case only one active
      choice_value is allowed). Those values are also written to the config
      file causing modules to be built when they should not.
      
      The following config can be used to reproduce and examine the problem;
      with the frontend of your choice set "Choice 0" and "Choice 1" to 'm',
      then set "Tristate Choice" to 'y' and save the configuration:
      
      config modules
      	boolean modules
      	default y
      	option modules
      
      config dependency
      	tristate "Dependency"
      	default m
      
      choice
      	prompt "Tristate Choice"
      	default choice0
      
      config choice0
      	tristate "Choice 0"
      
      config choice1
      	tristate "Choice 1"
      	depends on dependency
      
      endchoice
      
      This patch sets tristate choice_values' visibility that depend on
      symbols set to 'm' to 'n' if the corresponding choice is set to 'y'.
      
      This makes them disappear from the choice list and will also cause the
      choice_values' value set to 'n' in sym_calc_value() and as a result
      they are written as "not set" to the resulting .config file.
      Reported-by: NSebastian Andrzej Siewior <bigeasy@linutronix.de>
      Signed-off-by: NDirk Gouders <dirk@gouders.net>
      Tested-by: NSebastian Andrzej Siewior <bigeasy@linutronix.de>
      Tested-by: NRoger Quadros <rogerq@ti.com>
      Signed-off-by: NMichal Marek <mmarek@suse.com>
      fa64e5f6
  3. 10 5月, 2016 1 次提交
  4. 27 4月, 2016 2 次提交
  5. 26 4月, 2016 4 次提交
  6. 01 2月, 2016 2 次提交
    • A
      unbreak allmodconfig KCONFIG_ALLCONFIG=... · 6b87b70c
      Al Viro 提交于
      	Prior to 3.13 make allmodconfig KCONFIG_ALLCONFIG=/dev/null used
      to be equivalent to make allmodconfig; these days it hardwires MODULES to n.
      In fact, any KCONFIG_ALLCONFIG that doesn't set MODULES explicitly is
      treated as if it set it to n.
      
      	Regression had been introduced by commit cfa98f ("kconfig: do not
      override symbols already set"); what happens is that conf_read_simple()
      does sym_calc_value(modules_sym) on exit, which leaves SYMBOL_VALID set and
      has conf_set_all_new_symbols() skip modules_sym.
      
      	It's pretty easy to fix - simply move that call of sym_calc_value()
      into the callers, except for the ones in KCONFIG_ALLCONFIG handling.
      Objections?
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      Fixes: cfa98f2e ("kconfig: do not override symbols already set")
      Signed-off-by: NMichal Marek <mmarek@suse.com>
      6b87b70c
    • J
      scripts/kconfig: allow building with make 3.80 again · 42f9d3c6
      Jan Beulich 提交于
      Documentation/Changes still lists this as the minimal required version,
      so it ought to remain usable for the time being.
      
      Fixes: d2036f30 ("scripts/kconfig/Makefile: Allow KBUILD_DEFCONFIG to be a target")
      Signed-off-by: NJan Beulich <jbeulich@suse.com>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Signed-off-by: NMichal Marek <mmarek@suse.com>
      42f9d3c6
  7. 11 1月, 2016 1 次提交
  8. 05 1月, 2016 1 次提交
  9. 10 12月, 2015 1 次提交
  10. 03 11月, 2015 2 次提交
  11. 21 10月, 2015 1 次提交
  12. 15 10月, 2015 1 次提交
    • M
      scripts/kconfig/Makefile: Fix KBUILD_DEFCONFIG check when building with O= · bd960f09
      Michael Ellerman 提交于
      My recent commit d2036f30 ("scripts/kconfig/Makefile: Allow
      KBUILD_DEFCONFIG to be a target"), contained a bug in that when it
      checks if KBUILD_DEFCONFIG is a file it forgets to prepend $(srctree) to
      the path.
      
      This causes the build to fail when building out of tree (with O=), and
      when the value of KBUILD_DEFCONFIG is 'defconfig'. In that case we will
      fail to find the 'defconfig' file, because we look in the build
      directory not $(srctree), and so we will call Make again with
      'defconfig' as the target. From there we loop infinitely calling 'make
      defconfig' again and again.
      
      The fix is simple, we need to look for the file under $(srctree).
      
      Fixes: d2036f30 ("scripts/kconfig/Makefile: Allow KBUILD_DEFCONFIG to be a target")
      Reported-by: NOlof Johansson <olof@lixom.net>
      Acked-by: NMichal Marek <mmarek@suse.com>
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      bd960f09
  13. 14 10月, 2015 22 次提交