1. 19 6月, 2013 1 次提交
  2. 25 4月, 2013 1 次提交
    • Y
      kconfig: allow specifying the seed for randconfig · 0d8024c6
      Yann E. MORIN 提交于
      For reproducibility, it can be useful to be able to specify the
      seed to use to seed the RNG.
      
      Add a new KCONFIG_SEED environment variable which can be set to
      the seed to use:
          $ make KCONFIG_SEED=42 randconfig
          $ sha1sum .config
          70a128c8dcc61303069e1be352cce64114dfcbca  .config
          $ make KCONFIG_SEED=42 randconfig
          $ sha1sum .config
          70a128c8dcc61303069e1be352cce64114dfcbca  .config
      
      It's very usefull for eg. debugging the kconfig parser.
      Signed-off-by: N"Yann E. MORIN" <yann.morin.1998@free.fr>
      0d8024c6
  3. 19 2月, 2013 1 次提交
  4. 28 9月, 2012 1 次提交
  5. 31 8月, 2012 1 次提交
  6. 08 5月, 2012 1 次提交
    • E
      kbuild: all{no,yes,mod,def,rand}config only read files when instructed to. · 9f420bf0
      Eric W. Biederman 提交于
      Prevent subtle surprises to both people working on the kconfig code
      and people using make allnoconfig allyesconfig allmoconfig and
      randconfig by only attempting to read a config file if
      KCONFIG_ALLCONFIG is set.
      
      Common sense suggests attempting to read the extra config files does
      not make sense unless requested.  The documentation says the code
      won't attempt to read the extra config files unless requested.
      Current usage does not appear to include people depending on the code
      reading the config files without the variable being set So do the
      simple thing and stop reading config files when passed
      all{no,yes,mod,def,rand}config unless KCONFIG_ALLCONFIG environment
      variable is set.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Reported-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      9f420bf0
  7. 05 5月, 2012 1 次提交
    • E
      kconfig: Add error handling to KCONFIG_ALLCONFIG · 5efe241e
      Eric W. Biederman 提交于
      - Only try to read the file specified if KCONFIG_ALL_CONFIG is set to
        something other than the empty string or "1".
      
      - Don't use stat to check the name passed to conf_read_simple so that
        zconf_fopen can find the file in the current directory or in SRCTREE
        removing a extremely source of confusing failure, where KCONFIG_ALL_CONFIG
        was not interpreted with respect to the directory make was called in.
      
      - If conf_read_simple fails complain clearly and stop processing.
        Allowing the simple debugging of typos.
      
      - Clearly document the behavior so it is clear to users which
        values are treated as flags and which values are treated as
        filenames.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      5efe241e
  8. 02 7月, 2011 3 次提交
  9. 07 6月, 2011 2 次提交
  10. 24 4月, 2011 1 次提交
    • B
      kconfig: Avoid buffer underrun in choice input · 3ba41621
      Ben Hutchings 提交于
      Commit 40aee729 ('kconfig: fix default value for choice input')
      fixed some cases where kconfig would select the wrong option from a
      choice with a single valid option and thus enter an infinite loop.
      
      However, this broke the test for user input of the form 'N?', because
      when kconfig selects the single valid option the input is zero-length
      and the test will read the byte before the input buffer.  If this
      happens to contain '?' (as it will in a mips build on Debian unstable
      today) then kconfig again enters an infinite loop.
      Signed-off-by: NBen Hutchings <ben@decadent.org.uk>
      Cc: stable@kernel.org [2.6.17+]
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      3ba41621
  11. 08 4月, 2011 1 次提交
    • B
      kconfig: Avoid buffer underrun in choice input · 466de918
      Ben Hutchings 提交于
      commit 40aee729 ('kconfig: fix default
      value for choice input') fixed some cases where kconfig would select
      the wrong option from a choice with a single valid option and thus
      enter an infinite loop.
      
      However, this broke the test for user input of the form 'N?', because
      when kconfig selects the single valid option the input is zero-length
      and the test will read the byte before the input buffer.  If this
      happens to contain '?' (as it will in a mips build on Debian unstable
      today) then kconfig again enters an infinite loop.
      Signed-off-by: NBen Hutchings <ben@decadent.org.uk>
      Cc: stable@kernel.org [2.6.17+]
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      466de918
  12. 15 12月, 2010 1 次提交
  13. 10 10月, 2010 1 次提交
  14. 20 9月, 2010 2 次提交
  15. 08 9月, 2010 1 次提交
  16. 31 8月, 2010 1 次提交
  17. 13 8月, 2010 1 次提交
  18. 07 8月, 2010 1 次提交
  19. 03 8月, 2010 5 次提交
    • S
      kconfig: add savedefconfig · 7cf3d73b
      Sam Ravnborg 提交于
      savedefconfig will save a minimal config to a file
      named "defconfig".
      
      The config symbols are saved in the same order as
      they appear in the menu structure so it should
      be possible to map them to the relevant menus
      if desired.
      
      The implementation was tested against several minimal
      configs for arm which was created using brute-force.
      
      There was one regression related to default numbers
      which had their valid range further limited by another symbol.
      
      Sample:
      
      config FOO
      	int "foo"
      	default 4
      
      config BAR
      	int "bar"
      	range 0 FOO
      
      If FOO is set to 3 then BAR cannot take a value higher than 3.
      But the current implementation will set BAR equal to 4.
      
      This is seldomly used and the final configuration is OK,
      and the fix was non-trivial.
      So it was documented in the code and left as is.
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Acked-by: NUwe Kleine-König <u.kleine-koenig@pengutronix.de>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      7cf3d73b
    • S
      kconfig: add alldefconfig · 0748cb3e
      Sam Ravnborg 提交于
      alldefconfig create a configuration with all values set
      to their default value (form the Kconfig files).
      
      This may be useful when we try to use more sensible default
      values and may also be used in combination with
      the minimal defconfigs.
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      0748cb3e
    • S
      kconfig: change nonint_oldconfig to listnewconfig · 861b4ea4
      Sam Ravnborg 提交于
      Rename to a name that better match the other kconfig targets.
      
      listnewconfig shall read as:
      
      - list new options compared to current configuration
      
      New options are now written to stdout so one can redirect the output.
      
      Do not exit with an error code if there is new options.
      
      These are feature changes compared to the original
      nonint_oldconfig - but as this feature has not yet been in a
      released kernel it should not matter.
      
      It is still possible to do:
      
      make listnewconfig
      lookup new config options in Kconfig*
      edit .config
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Cc: Aristeu Rozanski <aris@redhat.com>
      Acked-by: NAristeu Rozanski <aris@redhat.com>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      861b4ea4
    • S
      kconfig: rename loose_nonint_oldconfig => oldnoconfig · ef61ca88
      Sam Ravnborg 提交于
      Rename target to something that fall more in line
      with the other kconfig targets.
      
      oldnoconfig shall read as:
      
      - read the old configuration and set all new options to no
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Cc: Aristeu Rozanski <aris@redhat.com>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      ef61ca88
    • S
      kconfig: use long options in conf · 4062f1a4
      Sam Ravnborg 提交于
      The list of options supported by conf is growing
      and their abbreviation did not resemble anything usefull.
      
      So drop the single letter options in favour of long options.
      
      The long options are named equal to what we know from
      the make target.
      The internal implmentation was changed to match this,
      resulting in much more readable code.
      
      Support for short options is dropped - no one is supposed
      to call this program direct anyway.
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      4062f1a4
  20. 12 6月, 2010 1 次提交
  21. 02 6月, 2010 1 次提交
  22. 20 9月, 2009 2 次提交
  23. 10 6月, 2009 1 次提交
  24. 16 3月, 2009 1 次提交
    • I
      kconfig: improve seed in randconfig · b0fe5510
      Ingo Molnar 提交于
      'make randconfig' uses glibc's rand function, and the seed of
      that PRNG is set via:
      
      			srand(time(NULL));
      
      But 'time()' only increases once every second - freezing the
      randconfig result within a single second.
      
      My Nehalem testbox does randconfig much faster than 1 second
       and i have a few scripts that do 'randconfig until condition X'
      loops.
      
      Those scripts currently waste a lot of CPU time due to randconfig
      changing its seed only once per second currently.
      
      Change the seed to be micrseconds based. (I checked the statistical
      spread of the seed - the now.tv_sec*now.tv_usec multiplication
      there further improves it.)
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      [sam: fix for systems where usec is zero - noticed by Geert Uytterhoeven]
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      b0fe5510
  25. 29 9月, 2008 1 次提交
  26. 05 8月, 2008 1 次提交
  27. 26 7月, 2008 3 次提交
    • S
      kconfig: make defconfig is no longer chatty · 09748e17
      Sam Ravnborg 提交于
      make defconfig generated a lot of output
      then noone actually read.
      Use conf_set_all_new_symbols() to generate the default
      configuration and avoid the chatty output.
      
      A typical run now looks like this:
      $ make  defconfig
      *** Default configuration is based on 'i386_defconfig'
      arch/x86/configs/i386_defconfig:13:warning: trying to assign nonexistent symbol SEMAPHORE_SLEEPERS
      arch/x86/configs/i386_defconfig:176:warning: trying to assign nonexistent symbol PREEMPT_BKL
      ...
      arch/x86/configs/i386_defconfig:1386:warning: trying to assign nonexistent symbol INSTRUMENTATION
      $
      
      As an added benefit we now clearly see the warnings generated
      in the start of the process.
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      09748e17
    • S
      kconfig: make oldconfig is now less chatty · cd9140e1
      Sam Ravnborg 提交于
      Previously when running "make oldconfig" we saw all the propmt lines
      from kconfig and noone actully read this.
      
      With this patch the user will only see output if there is new symbols.
      This will be seen as "make oldconfig" runs which does not generate any output.
      
      A typical run now looks like this:
      
      $ make oldconfig
      scripts/kconfig/conf -o arch/x86/Kconfig
      $
      
      If a new symbol is found then we restart the config process like this:
      $ make oldconfig
      scripts/kconfig/conf -o arch/x86/Kconfig
      *
      * Restart config...
      *
      *
      * General setup
      *
      Prompt for development and/or incomplete code/drivers (EXPERIMENTAL) [Y/n/?] y
      Local version - append to kernel release (LOCALVERSION) []
      ...
      
      The bahaviour is similar to what we know when running the implicit
      oldconfig target "make silentoldconfig".
      "make silentoldconfig" are run as part of the kernel build process
      if the configuration has changed.
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      cd9140e1
    • S
      kconfig: speed up all*config + randconfig · f443d2ec
      Sam Ravnborg 提交于
      Drop the chatty mode when we generate the all*config, randconfig
      configurations.
      Ths speeds up the process considerably and noone looked
      at the output anyway.
      This patch uses the conf_set_all_new_symbols() function
      just added to kconfig.
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      f443d2ec
  28. 29 1月, 2008 2 次提交