zephyr/subsys/bluetooth/mesh
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
..
access.c Bluetooth: Mesh: Support reliable sending when publishing 2020-02-07 20:42:15 +02:00
access.h Bluetooth: Mesh: Model extension concept 2019-11-07 18:57:32 +02:00
adv.c kernel: overhaul unused stack measurement 2020-02-08 10:02:35 +02:00
adv.h Bluetooth: Mesh: Encrypt friend packets on send 2019-09-16 14:00:57 +03:00
beacon.c Bluetooth: Mesh: Add callback for unprovisioned device beacon 2019-10-30 13:08:09 +01:00
beacon.h
cdb.c Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
cfg_cli.c Bluetooth: Mesh: Fixes Config client send publish message 2019-11-14 14:26:21 +02:00
cfg_srv.c Bluetooth: mesh: Use 24-bit functions 2020-01-02 19:05:27 +01:00
CMakeLists.txt Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
crypto.c Bluetooth: Move Mesh CCM into a separate module 2020-01-30 12:41:45 +02:00
crypto.h Bluetooth: Mesh: Add support for provisioner role over PB-ADV 2019-10-30 13:08:09 +01:00
foundation.h Bluetooth: Mesh: Persistent storage of Virtual Addresses 2019-10-17 12:24:13 +03:00
friend.c Bluetooth: mesh: Use 24-bit functions 2020-01-02 19:05:27 +01:00
friend.h Bluetooth: Mesh: Fix adhering to the configured Friend Queue size 2019-08-19 16:30:31 +03:00
health_cli.c Bluetooth: Mesh: Model message macros 2019-10-08 18:38:43 +03:00
health_srv.c Bluetooth: Mesh: Model message macros 2019-10-08 18:38:43 +03:00
Kconfig kconfig: Replace some single-symbol 'if's with 'depends on' 2020-02-08 08:32:42 -05:00
lpn.c Bluetooth: Mesh: Fix PreviousAddress endianess in Friend Request 2020-01-03 10:14:10 +01:00
lpn.h
main.c Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
mesh.h Bluetooth: Mesh: Model start callback 2020-01-11 18:20:00 +01:00
net.c Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
net.h Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
prov.c Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
prov.h Bluetooth: Mesh: Add support for provisioner role over PB-ADV 2019-10-30 13:08:09 +01:00
proxy.c Bluetooth: host: cfg_write callback to return error code 2020-01-10 17:41:15 +01:00
proxy.h
settings.c Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
settings.h Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
shell.c Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
test.c
test.h
TODO
transport.c Bluetooth: Mesh: Add database for managing nodes and keys 2020-02-05 18:47:41 +02:00
transport.h Bluetooth: Mesh: Add support for provisioner role over PB-ADV 2019-10-30 13:08:09 +01:00