15 Oct, 2017

1 commit


30 Sep, 2017

1 commit

  • Corresponds to 375506d (File writing nit) from upstream
    (https://github.com/ulfalizer/Kconfiglib).

    Adds proper 'imply' support and fixes a few minor issues, one of which
    previously triggered the following weird warning:

    configs/taurus_defconfig: /tmp/tmpisI45S:6: warning: assignment to SPL_LDSCRIPT changes mode of containing choice from "arch/$(ARCH)/cpu/u-boot-spl.lds" to "y"

    The change in 8639f69 (genconfig.py: Print defconfig next to warnings)
    was reapplied.

    tools/moveconfig.py previously depended on a hack that merged 'select's
    with 'imply's. It was modified to look at the union of
    Symbol.get_selected_symbols() and Symbol.get_implied_symbols(), which
    should give the same behavior.

    tools/genboardscfg.py was verified to produce identical board.cfg's
    before and after the change.

    Signed-off-by: Ulf Magnusson

    Ulf Magnusson
     

12 Sep, 2017

1 commit


23 Jul, 2017

2 commits

  • It is annoying to have to set up and maintain two sets of toolchains, one
    for buildman and one for moveconfig.

    Adjust moveconfig to make use to buildman's toolchains. This should make
    things easier.

    One missing feature is the ability to specify the toolchain on the command
    line with a special environment variable, e.g. CROSS_COMPILE_ARM. I'm not
    sure if that is useful, but if it is it could be implemented in buildman.

    Signed-off-by: Simon Glass
    Reviewed-by: Philipp Tomsich
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • Add an option to specify 'all' to enable all flags. Also print an error
    if an unrecognised flag is used. At present it just prints usage
    information which is not very helpful.

    Signed-off-by: Simon Glass

    Simon Glass
     

12 Jul, 2017

9 commits

  • By using a Kconfig parser we can find the location of each option in the
    Kconfig tree. Using the information from the database we can then
    automatically add an 'imply' option into the right place if requested by
    the user.

    Add a -a option to support adding 'imply' options. Display the location of
    any existing 'imply' option so that progress can be examined. Add a -A
    option to hide any existing 'imply' options so that already-completed
    additions need not be considered further.

    Also add documentation for this feature.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • Sometimes it is useful to display CONFIG_TARGET or CONFIG_CMD configs. Add
    an option to control this.

    Also we generally ignore implying configs which affect fewer than 5
    boards. But sometimes it is useful to show those those, so add an option
    that reduces the minimum to two.

    ERRATUM configs are never useful for implying things, so ignore those.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • It is useful to be able to process only a subset of boards to save time.
    Often that subset is defined by the defconfig files in a git commit. This
    change allows things like:

    # Build the database
    ./tools.moveconfig.py -b

    # Find some implying configs
    ./tools/moveconfig.py -i CONFIG_X

    # Add some 'imply' statements to Kconfig files
    ./tools/moveconfig.py -i CONFIG_X -a CONFIG_A,CONFIG_B

    # Reprocess the defconfig files to see if we can drop some changes
    git show --stat | ./tools/moveconfig.py -s -d -

    # Update the commit, with fewer defconfig changes
    gii commit -au

    Where the commit contains defconfig files, this will reprocess them to
    take account of the imply statements that you added.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • Some CONFIG options can be implied by others and this can help to reduce
    the size of the defconfig files. For example, CONFIG_X86 implies
    CONFIG_CMD_IRQ, so we can put 'imply CMD_IRQ' under 'config X86' and
    all x86 boards will have that option, avoiding adding CONFIG_CMD_IRQ to
    each of the x86 defconfig files.

    Add a -i option which searches for such options.

    Signed-off-by: Simon Glass
    Reviewed-by: Heiko Schocher

    Simon Glass
     
  • Add a -b option which scans all the defconfigs and builds a database of
    all the CONFIG options used by each. This is useful for querying later.

    At present this only works with the separate -b option, which does not
    move any configs. It would be possible to adjust the script to build the
    database automatically when moving configs, but this might not be useful
    as the database does not change that often.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • This filename is used a few times. Move it to a constant before adding
    further uses.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • The newest clean-up features are not mentioned in the docs. Fix this and
    add a few hints for particular workflows that are hopefully helpful.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • Support passes in a defconfig filename of '-' to read the list from stdin
    instead of from a file.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • It is convenient to provide the full patch to the defconfig files in some
    situations, e.g. when the file was generated by a shell command (e.g.
    'ls configs/zynq*').

    Add support for this, and move the globbing code into a function with its
    own documentation.

    Signed-off-by: Simon Glass

    Simon Glass
     

07 Jul, 2017

1 commit

  • AVR32 is gone. It's already more than two years for no support in Buildroot,
    even longer there is no support in GCC (last version is heavily patched 4.2.4).

    Linux kernel v4.12 got rid of it (and v4.11 didn't build successfully).

    There is no good point to keep this support in U-Boot either.

    Reviewed-by: Simon Glass
    Reviewed-by: Tom Rini
    Reviewed-by: Heiko Schocher
    Signed-off-by: Andy Shevchenko

    Andy Shevchenko
     

08 May, 2017

3 commits


18 Apr, 2017

1 commit


24 Oct, 2016

1 commit

  • Supporting shell-style wildcards for the --defconfigs option will be
    useful to run the moveconfig tool against a specific platform. For
    example, "uniphier*" in the file passed by --defconfigs option will
    be expanded to defconfig files that start with "uniphier". This is
    easier than listing out all defconfig files you are interested in.

    Signed-off-by: Masahiro Yamada
    Reviewed-by: Joe Hershberger

    Masahiro Yamada
     

17 Sep, 2016

2 commits

  • The moveconfig tool is quite clever and generally produces results that
    are suitable for sending as a patch without further work. The main required
    step is to add the changes to a commit.

    Add an option to do this automatically. This allows moveconfig to be used
    from a script to convert multiple CONFIG options, once per commit.

    Signed-off-by: Simon Glass

    Simon Glass
     
  • At present it is not easy to use moveconfig from a script since it asks
    for user input a few times. Add a -y option to skip this and assume that
    'y' was entered.

    Signed-off-by: Simon Glass

    Simon Glass
     

07 Sep, 2016

4 commits


27 Aug, 2016

2 commits


05 Aug, 2016

8 commits


22 Jun, 2016

4 commits

  • There are some cases where config options are moved, but they are
    ripped off at the final savedefconfig stage:

    - The moved option is not user-configurable, for example, due to
    a missing prompt in the Kconfig entry

    - The config was not defined in the original config header despite
    the Kconfig specifies it as non-bool type

    - The config define in the header contains reference to another
    macro, for example:
    #define CONFIG_CONS_INDEX (CONFIG_SYS_LPC32XX_UART - 2)
    The current moveconfig does not support recursive macro expansion.

    In these cases, the conversion is very likely to be an unexpected
    result. That is why I decided to display the log in yellow color
    in commit 5da4f857beac ("tools: moveconfig: report when CONFIGs are
    removed by savedefconfig").

    It would be nice to display the list of suspicious boards when the
    tool finishes processing. It is highly recommended to check the
    defconfigs once again when this message is displayed.

    Signed-off-by: Masahiro Yamada
    Reviewed-by: Joe Hershberger

    Masahiro Yamada
     
  • Since commit 1d085568b3de ("tools: moveconfig: display log atomically
    in more readable format"), the function color_text() is clever enough
    to exclude LF from escape sequences. Exploit it for removing the
    "for" loops from Slots.show_failed_boards().

    Also, display "(the list has been saved in moveconfig.failed)" if
    there are failed boards.

    Signed-off-by: Masahiro Yamada
    Reviewed-by: Joe Hershberger

    Masahiro Yamada
     
  • The subprocess.Popen() does not change the child process's working
    directory if cwd=None is given. Let's exploit this fact to refactor
    the source directory handling.

    We no longer have to pass "-C " to the sub-process
    because self.current_src_dir tracks the source tree against which we
    want to run defconfig/autoconf.

    The flag self.use_git_ref is not necessary either because we can know
    the current state by checking whether the self.current_src_dir is a
    valid string or None.

    Signed-off-by: Masahiro Yamada

    Masahiro Yamada
     
  • The class WorkDir can be used in a very generic way, but currently
    it is only used for containing a reference source directory.

    This commit changes it for a more dedicated use. The move_config
    function can be more readable by enclosing the git-clone and git-
    checkout in the class constructor.

    Signed-off-by: Masahiro Yamada
    Reviewed-by: Joe Hershberger

    Masahiro Yamada