1. 10 7月, 2013 2 次提交
  2. 04 7月, 2013 23 次提交
  3. 03 7月, 2013 3 次提交
  4. 29 6月, 2013 1 次提交
  5. 28 6月, 2013 2 次提交
  6. 27 6月, 2013 1 次提交
  7. 26 6月, 2013 1 次提交
  8. 25 6月, 2013 4 次提交
    • Y
      kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG · 8357b485
      Yann E. MORIN 提交于
      Currently, randconfig does randomise choice entries, unless KCONFIG_ALLCONFIG
      is specified.
      
      For example, given those two files (Thomas' test-case):
      
          ---8<--- Config.test.in
          config OPTIONA
              bool "Option A"
      
          choice
              prompt "This is a choice"
      
          config CHOICE_OPTIONA
              bool "Choice Option A"
      
          config CHOICE_OPTIONB
              bool "Choice Option B"
      
          endchoice
      
          config OPTIONB
              bool "Option B"
          ---8<--- Config.test.in
      
          ---8<--- config.defaults
          CONFIG_OPTIONA=y
          ---8<--- config.defaults
      
      And running:
          ./scripts/kconfig/conf --randconfig Config.test.in
      
      does properly randomise the two choice symbols (and the two booleans).
      
      However, running:
          KCONFIG_ALLCONFIG=config.defaults \
          ./scripts/kconfig/conf --randconfig Config.test.in
      
      does *not* reandomise the two choice entries, and only CHOICE_OPTIONA
      will ever be selected. (OPTIONA will always be set (expected), and
      OPTIONB will be be properly randomised (expected).)
      
      This patch defers setting that a choice has a value until a symbol for
      that choice is indeed set, so that choices are properly randomised when
      KCONFIG_ALLCONFIG is set, but not if a symbol for that choice is set.
      Reported-by: NThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: N"Yann E. MORIN" <yann.morin.1998@free.fr>
      Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Cc: Michal Marek <mmarek@suse.cz>
      Cc: Sam Ravnborg <sam@ravnborg.org>
      Cc: Sedat Dilek <sedat.dilek@gmail.com>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Stephen Rothwell <sfr@canb.auug.org.au>
      
      ---
      Changes v3 -> v4
        - fix previous issue where some choices would not be set, which would
          cause silentoldconfig to ask for them and was then breaking this
          workflow (as reported by Arnd and Sedat):
              KCONFIG_ALLCONFIG=foo.defconfig make randconfig
              make silentoldconfig </dev/nullo
          which I have tested (3h28min!) with:
              touch defconfig
              for(( i=0; i<10000; i++ )); do
                  KCONFIG_ALLCONFIG=$(pwd)/defconfig make randconfig >/dev/null 2>&1
                  make silentoldconfig </dev/null >/dev/null 2>&1 || break
              done
          which did not break at all.
        - change done in v3 (below) is already fixed by a previous patch
      
      Changes v2 -> v3
        - ensure only one symbol is set in a choice
      
      Changes v1 -> v2:
        - further postpone setting that a choice has a value until
          one is indeed set
        - do not print symbols that are part of an invisible choice
      8357b485
    • Y
      kconfig: loop as long as we changed some symbols in randconfig · 3b9a19e0
      Yann E. MORIN 提交于
      Because of choice-in-a-choice constructs, it can happen that not all
      symbols are assigned a value during randconfig, leading in rare cases
      to this situation:
      
          ---8<--- choice-in-choice.in
          choice
              bool "A/B/C"
          config A
              bool "A"
      
          config B
              bool "B"
          if B
          choice
              bool "E/F"
          config E
              bool "E"
          config F
              bool "F"
          endchoice
          endif # B
      
          config C
              bool "C"
          endchoice
          ---8<---
      
          $ ./scripts/kconfig/conf --randconfig choice-in-choice.in
          [--SNIP--]
          $ ./scripts/kconfig/conf --silentoldconfig choice-in-choice.in </dev/null
          [--SNIP--]
          A/B/C
            1. A (A)
          > 2. B (B)
            3. C (C)
          choice[1-3]: 2
            E/F
            > 1. E (E) (NEW)
              2. F (F) (NEW)
            choice[1-2]: aborted!
      
          Console input/output is redirected. Run 'make oldconfig' to update
          configuration.
      
      Fix this by looping in randconfig for as long as some symbol gets assigned
      a value.
      
      Note: this was spotted with the USB EHCI Debug Device Gadget (USB_G_DBGP),
      which uses this choice-in-a-choice construct, and exhibits this problem.
      The example above is just a stripped-down minimalist test-case.
      Signed-off-by: N"Yann E. MORIN" <yann.morin.1998@free.fr>
      3b9a19e0
    • Y
      kconfig/[mn]conf: make it explicit in the search box that a regexp is possible · a1ce636f
      Yann E. MORIN 提交于
      Reported-by: NJean Delvare <jdelvare@suse.de>
      Signed-off-by: N"Yann E. MORIN" <yann.morin.1998@free.fr>
      Cc: Jean Delvare <jdelvare@suse.de>
      Cc: Michal Marek <mmarek@suse.cz>
      a1ce636f
    • Y
      kconfig: sort found symbols by relevance · 193b40ae
      Yann E. MORIN 提交于
      When searching for symbols, return the symbols sorted by relevance.
      
      Sorting is done as thus:
        - first, symbols that match exactly
        - then, alphabetical sort
      
      Since the search can be a regexp, it is possible that more than one symbol
      matches exactly. In this case, we can't decide which to sort first, so we
      fallback to alphabeticall sort.
      
      Explain this (new!) sorting heuristic in the documentation.
      Reported-by: NJean Delvare <jdelvare@suse.de>
      Signed-off-by: N"Yann E. MORIN" <yann.morin.1998@free.fr>
      Cc: Jean Delvare <jdelvare@suse.de>
      Cc: Michal Marek <mmarek@suse.cz>
      Cc: Roland Eggner <edvx1@systemanalysen.net>
      Cc: Wang YanQing <udknight@gmail.com>
      
      --
      Changes v1->v2:
        - drop the previous, complex heuristic in favour of a simpler heuristic
          that is both easier to understand, *and* to maintain (Jean)
        - explain sorting heuristic in the doc  (Jean)
      193b40ae
  9. 24 6月, 2013 2 次提交
    • M
      kbuild: fix error when building from src rpm · c398ff00
      Mike Marciniszyn 提交于
      The following issue can be reproduced with Linus' tree on
      an x86_64 server.
      
      >+ cp /home/user/rpmbuild-test/BUILDROOT/kernel-3.9.2.x86_64/boot/vmlinuz-3.9.2
      >cp: missing destination file operand after
      >/home/user/rpmbuild-test/BUILDROOT/kernel-3.9.2-1.x86_64/boot/vmlinuz-3.9.2'
      >Try `cp --help' for more information.
      >error: Bad exit status from /var/tmp/rpm-tmp.R4o0iI (%install)
      
      Here are the commands to reproduce:
      
      make defconfig
      make rpm-pkg
      
      Use the resulting src rpm to build as follows:
      
      mkdir ~/rpmbuild-test
      cd ~/rpmbuild-test
      rpmbuild --rebuild --define "_topdir `pwd`" -vv ~/rpmbuild/SRPMS/kernel-3.10.0_rc1+-1.src.rpm
      
      The issue is because the %install script uses $KBUILD_IMAGE and it hasn't
      been set since it is only available in the kbuild system and not in the
      %install script.
      
      This patch adds a Makefile target to emit the image_name that can be used
      and modifies the mkspec to use the dynamic name in %install.
      Signed-off-by: NMike Marciniszyn <mike.marciniszyn@intel.com>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      c398ff00
    • C
      scripts/setlocalversion on write-protected source tree · cdf2bc63
      Christian Kujau 提交于
      I just stumbled across another[0] issue when scripts/setlocalversion
      operates on a write-protected source tree. Back then[0] the source tree
      was on an read-only NFS share, so "test -w" was introduced before "git
      update-index" was run.
      
      This time, the source tree is on read/write NFS share, but the permissions
      are world-readable and only a specific user (or root) can write.
      Thus, "test -w ." returns "0" and then runs "git update-index",
      producing the following message (on a dirty tree):
      
        fatal: Unable to create '/usr/local/src/linux-git/.git/index.lock': Permission denied
      
      While it says "fatal", compilation continues just fine.
      
      However, I don't think a kernel compilation should alter the source
      tree (or the .git directory) in any way and I don't see how removing
      "git update-index" could do any harm. The Mercurial and SVN routines in
      scripts/setlocalversion don't have any tree-modifying commands, AFAICS.
      So, maybe the patch below would be acceptable.
      
      [0] https://patchwork.kernel.org/patch/29718/Signed-off-by: NChristian Kujau <lists@nerdbynature.de>
      Cc: Nico Schottelius <nico-linuxsetlocalversion@schottelius.org>
      Signed-off-by: NMichal Marek <mmarek@suse.cz>
      cdf2bc63
  10. 19 6月, 2013 1 次提交