kconfig: Change how BT affects SYSTEM_WORKQUEUE_PRIORITY

Invalid configurations should be detected during configuration instead
of during compilation whenever possible.

This patch replaces a BUILD_ASSERT on CONFIG_SYSTEM_WORKQUEUE_PRIORITY
with what is intended to be an equivalent Kconfig restriction.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
This commit is contained in:
Sebastian Bøe 2018-06-14 09:53:00 +02:00 committed by Anas Nashif
commit d62117e5b8
2 changed files with 5 additions and 7 deletions

View file

@ -35,6 +35,11 @@ config BT_CUSTOM
endchoice
# The Bluetooth subsystem requires the system workqueue to execute at
# a cooperative priority.
config SYSTEM_WORKQUEUE_PRIORITY
range -256 -1
if BT_HCI
config BT_HCI_RAW

View file

@ -11,13 +11,6 @@
#include <zephyr.h>
/* The Bluetooth subsystem requires the system workqueue to execute at a
* cooperative priority to function correctly. If this build assert triggers
* verify your configuration to ensure that cooperative threads are enabled
* and that the system workqueue priority is negative (cooperative).
*/
BUILD_ASSERT(CONFIG_SYSTEM_WORKQUEUE_PRIORITY < 0);
/* The Bluetooth subsystem requires the Tx thread to execute at higher priority
* than the Rx thread as the Tx thread needs to process the acknowledgements
* before new Rx data is processed. This is a necessity to correctly detect