summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-12-18 18:09:46 +0300
committerTom Rini <trini@konsulko.com>2022-01-25 01:36:29 +0300
commit65d7fcec5a05be15694613c6db709ede19bce85b (patch)
tree2601d853b15c00e6b91607f71c425aaff075d653 /doc
parent84067a5890f186a925dcf89f8402abaf12f09b45 (diff)
downloadu-boot-65d7fcec5a05be15694613c6db709ede19bce85b.tar.xz
moveconfig: Allow querying board configuration
It is useful to be able to find out which boards define a particular option, or combination of options. This is not as easy as grepping the defconfig files since many options are implied by others. Add a -f option to the moveconfig tool to permit this. Update the documentation to cover this, including a better title for the doc page. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'doc')
-rw-r--r--doc/develop/moveconfig.rst25
1 files changed, 23 insertions, 2 deletions
diff --git a/doc/develop/moveconfig.rst b/doc/develop/moveconfig.rst
index dcd4d927e4..2f53ea52b7 100644
--- a/doc/develop/moveconfig.rst
+++ b/doc/develop/moveconfig.rst
@@ -1,7 +1,7 @@
.. SPDX-License-Identifier: GPL-2.0+
-moveconfig
-==========
+moveconfig - Migrating and querying CONFIG options
+==================================================
Since Kconfig was introduced to U-Boot, we have worked on moving
config options from headers to Kconfig (defconfig).
@@ -129,6 +129,24 @@ To process CONFIG_CMD_FPGAD only for a subset of configs based on path match::
./tools/moveconfig.py -Cy CONFIG_CMD_FPGAD -d -
+Finding boards with particular CONFIG combinations
+--------------------------------------------------
+
+You can use `moveconfig.py` to figure out which boards have a CONFIG enabled, or
+which do not. To use it, first build a database::
+
+ ./tools/moveconfig.py -b
+
+Then you can run queries using the `-f` flag followed by a list of CONFIG terms.
+Each term is CONFIG name, with or without a tilde (~) prefix. The tool searches
+for boards which match the CONFIG name, or do not match if tilde is used. For
+example, to find boards which enabled CONFIG_SCSI but not CONFIG_BLK::
+
+ tools/moveconfig.py -f SCSI ~BLK
+ 3 matches
+ pg_wcom_seli8_defconfig highbank_defconfig pg_wcom_expu1_defconfig
+
+
Finding implied CONFIGs
-----------------------
@@ -235,6 +253,9 @@ Available options
Specify a file containing a list of defconfigs to move. The defconfig
files can be given with shell-style wildcards. Use '-' to read from stdin.
+ -f, --find
+ Find boards with a given config combination
+
-n, --dry-run
Perform a trial run that does not make any changes. It is useful to
see what is going to happen before one actually runs it.