[PATCH v5 00/13] kconfig: Add some new macros

Simon Glass
2022-01-22T12:07:46Z

This series adds a few more macros to kconfig, along with a bit of
refactoring of what is there.

It also adds some basic tests for the kconfig macros.

Finally, to make the tests work, it enhances buildman to support changing
CONFIG options on the fly when building.

Changes in v5:
- Use 'source' in subject instead of 'C'

Changes in v4:
- Update stale mention of zero in commit message
- Update stale comments in the header file
- Define the macros even in assembly context
- Expand the series with tests and buildman changes

Changes in v3:
- Add a way to detect use of a non-existent value
- Add new patch to update bloblist to use conditional value

Simon Glass (13):
imx: Don't define __ASSEMBLY__ in source files
mips: Avoid using config_enabled() directly
mmc: fsl: Use brackets around if()
kconfig: Update IS_ENABLED() internals
kconfig: Add support for conditional values
bloblist: Update to use conditional value
patman: Update test_util to run doc tests
buildman: Add a flag to control the traceback
buildman: Make use of test_util
buildman: Add helper functions for updating .config files
buildman: Provide a hint on how to debug thread crashes
buildman: Allow adjusting board config on the fly
test: Add some tests for kconfig.h

arch/arm/mach-imx/Makefile | 2 +-
.../mach-imx/imx8m/imximage-8mm-lpddr4.cfg | 1 -
arch/arm/mach-imx/imx8m/imximage-8mn-ddr4.cfg | 1 -
.../mach-imx/imx8m/imximage-8mn-lpddr4.cfg | 1 -
.../mach-imx/imx8m/imximage-8mp-lpddr4.cfg | 1 -
arch/arm/mach-imx/imx8m/imximage.cfg | 1 -
arch/arm/mach-imx/spl_qspi.cfg | 1 -
arch/arm/mach-imx/spl_sd.cfg | 1 -
arch/mips/lib/cache.c | 2 +-
.../advantech/imx8qm_rom7720_a1/imximage.cfg | 1 -
board/aristainetos/aristainetos2.cfg | 1 -
board/beacon/imx8mm/imximage-8mm-lpddr4.cfg | 1 -
board/beacon/imx8mn/imximage-8mn-lpddr4.cfg | 1 -
board/boundary/nitrogen6x/nitrogen6dl.cfg | 1 -
board/boundary/nitrogen6x/nitrogen6dl2g.cfg | 1 -
board/boundary/nitrogen6x/nitrogen6q.cfg | 1 -
board/boundary/nitrogen6x/nitrogen6q2g.cfg | 1 -
board/boundary/nitrogen6x/nitrogen6s.cfg | 1 -
board/boundary/nitrogen6x/nitrogen6s1g.cfg | 1 -
.../imximage-8mm-lpddr4.cfg | 1 -
board/congatec/cgtqmx8/imximage.cfg | 1 -
board/ea/mx7ulp_com/imximage.cfg | 1 -
.../imx8mm_evk/imximage-8mm-lpddr4.cfg | 1 -
.../imx8mn_evk/imximage-8mn-ddr4.cfg | 1 -
.../imx8mp_evk/imximage-8mp-lpddr4.cfg | 1 -
board/freescale/imx8qm_mek/imximage.cfg | 1 -
.../freescale/imx8qm_mek/uboot-container.cfg | 1 -
board/freescale/imx8qxp_mek/imximage.cfg | 1 -
.../freescale/imx8qxp_mek/uboot-container.cfg | 1 -
board/freescale/imxrt1020-evk/imximage.cfg | 1 -
board/freescale/imxrt1050-evk/imximage.cfg | 1 -
board/freescale/mx6slevk/imximage.cfg | 1 -
board/freescale/mx6sllevk/imximage.cfg | 1 -
board/freescale/mx6sxsabreauto/imximage.cfg | 1 -
board/freescale/mx6sxsabresd/imximage.cfg | 1 -
board/freescale/mx6ullevk/imximage.cfg | 1 -
board/freescale/mx7dsabresd/imximage.cfg | 1 -
board/freescale/mx7ulp_evk/imximage.cfg | 1 -
.../gateworks/venice/imximage-8mm-lpddr4.cfg | 1 -
board/ge/bx50v3/bx50v3.cfg | 1 -
board/kontron/sl-mx8mm/imximage.cfg | 1 -
board/novtech/meerkat96/imximage.cfg | 1 -
.../out4/o4-imx6ull-nano/K4B4G1646D-BCMA.cfg | 1 -
.../o4-imx6ull-nano/MT41K256M16HA-125E.cfg | 1 -
.../phytec/phycore_imx8mm/imximage-8mm-sd.cfg | 1 -
.../phytec/phycore_imx8mp/imximage-8mp-sd.cfg | 1 -
.../ronetix/imx8mq-cm/imximage-8mq-lpddr4.cfg | 1 -
board/siemens/capricorn/imximage.cfg | 1 -
board/siemens/capricorn/uboot-container.cfg | 1 -
board/softing/vining_2000/imximage.cfg | 1 -
board/somlabs/visionsom-6ull/imximage.cfg | 1 -
board/storopack/smegw01/imximage.cfg | 1 -
board/tbs/tbs2910/tbs2910.cfg | 1 -
board/technexion/pico-imx6ul/imximage.cfg | 1 -
.../apalis-imx8/apalis-imx8-imximage.cfg | 1 -
.../apalis-imx8x/apalis-imx8x-imximage.cfg | 1 -
board/toradex/colibri-imx6ull/imximage.cfg | 1 -
.../colibri-imx8x/colibri-imx8x-imximage.cfg | 1 -
board/toradex/colibri_imx7/imximage.cfg | 1 -
board/toradex/verdin-imx8mm/imximage.cfg | 1 -
board/tq/tqma6/tqma6dl.cfg | 1 -
board/tq/tqma6/tqma6q.cfg | 1 -
board/tq/tqma6/tqma6s.cfg | 1 -
board/warp/imximage.cfg | 1 -
board/warp7/imximage.cfg | 1 -
common/bloblist.c | 15 +-
drivers/mmc/fsl_esdhc_imx.c | 2 +-
include/bloblist.h | 10 -
include/linux/kconfig.h | 52 +++-
scripts/Makefile.autoconf | 2 +-
test/Kconfig | 1 +
test/Makefile | 2 +-
test/lib/Kconfig | 23 ++
test/lib/Makefile | 5 +
test/lib/kconfig.c | 58 +++++
test/lib/kconfig_spl.c | 44 ++++
test/py/tests/test_kconfig.py | 34 +++
tools/buildman/README | 49 ++++
tools/buildman/builder.py | 14 +-
tools/buildman/builderthread.py | 32 ++-
tools/buildman/cfgutil.py | 235 ++++++++++++++++++
tools/buildman/cmdline.py | 4 +
tools/buildman/control.py | 6 +-
tools/buildman/func_test.py | 8 +-
tools/buildman/main.py | 29 ++-
tools/buildman/test.py | 123 +++++++++
tools/dtoc/main.py | 2 +-
tools/patman/main.py | 20 +-
tools/patman/test_util.py | 17 +-
89 files changed, 715 insertions(+), 139 deletions(-)
create mode 100644 test/lib/Kconfig
create mode 100644 test/lib/kconfig.c
create mode 100644 test/lib/kconfig_spl.c
create mode 100644 test/py/tests/test_kconfig.py
create mode 100644 tools/buildman/cfgutil.py

--
2.35.0.rc0.227.g00780c9af4-goog