zephyr/drivers/pinmux
Ulf Magnusson eddd98f811 kconfig: Replace some single-symbol 'if's with 'depends on'
I think people might be reading differences into 'if' and 'depends on'
that aren't there, like maybe 'if' being needed to "hide" a symbol,
while 'depends on' just adds a dependency.

There are no differences between 'if' and 'depends on'. 'if' is just a
shorthand for 'depends on'. They work the same when it comes to creating
implicit menus too.

The way symbols get "hidden" is through their dependencies not being
satisfied ('if'/'depends on' get copied up as a dependency on the
prompt).

Since 'if' and 'depends on' are the same, an 'if' with just a single
symbol in it can be replaced with a 'depends on'. IMO, it's best to
avoid 'if' there as a style choice too, because it confuses people into
thinking there's deep Kconfig magic going on that requires 'if'.

Going for 'depends on' can also remove some nested 'if's, which
generates nicer symbol information and docs, because nested 'if's really
are so simple/dumb that they just add the dependencies from both 'if's
to all symbols within.

Replace a bunch of single-symbol 'if's with 'depends on' to despam the
Kconfig files a bit and make it clearer how things work. Also do some
other minor related dependency refactoring.

The replacement isn't complete. Will fix up the rest later. Splitting it
a bit to make it more manageable.

(Everything above is true for choices, menus, and comments as well.)

Detected by tweaking the Kconfiglib parsing code. It's impossible to
detect after parsing, because 'if' turns into 'depends on'.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2020-02-08 08:32:42 -05:00
..
stm32 drivers: pinmux: stm32f4: add CAN_2 pins 2020-01-30 14:27:28 -05:00
CMakeLists.txt arm: Removed support for CC2650 2020-01-18 09:27:55 -06:00
Kconfig arm: Removed support for CC2650 2020-01-18 09:27:55 -06:00
Kconfig.beetle kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.cc13xx_cc26xx kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.esp32 kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.hsdk kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.intel_s1000 kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.mcux kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.mcux_lpc kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.rv32m1 kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.sam0 kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.sifive kconfig: Replace some single-symbol 'if's with 'depends on' 2020-02-08 08:32:42 -05:00
Kconfig.stm32 kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
Kconfig.xec kconfig: Clean up header comments and make them consistent 2019-11-04 17:31:27 -05:00
dummy.c
pinmux.h
pinmux_cc13xx_cc26xx.c cleanup: include/: move misc/__assert.h to sys/__assert.h 2019-06-27 22:55:49 -04:00
pinmux_esp32.c esp32: pinmux: Add Device tree support 2019-11-04 19:45:50 +01:00
pinmux_hsdk.c arc: hsdk: add pinmux driver support and doc enhancement 2019-09-17 20:40:38 +08:00
pinmux_intel_s1000.c cleanup: include/: move pinmux.h to drivers/pinmux.h 2019-06-27 22:55:49 -04:00
pinmux_mchp_xec.c driver/pinumx: Adding missing braces for XEC driver 2019-08-02 23:24:34 +03:00
pinmux_mcux.c cleanup: include/: move pinmux.h to drivers/pinmux.h 2019-06-27 22:55:49 -04:00
pinmux_mcux_lpc.c cleanup: include/: move pinmux.h to drivers/pinmux.h 2019-06-27 22:55:49 -04:00
pinmux_rv32m1.c cleanup: include/: move pinmux.h to drivers/pinmux.h 2019-06-27 22:55:49 -04:00
pinmux_sam0.c pinmux: sam0: Add support for PORTD 2019-11-06 17:49:28 -08:00
pinmux_sifive.c drivers: sifiv: make them 64-bit compatible 2019-08-08 00:29:24 -04:00