Bluetooth: controller: Added support for vendor ticker nodes

With BT_CTLR_USER_TICKER_ID_RANGE it is possible for vendors to add a
number of ticker nodes for proprietary purposes. The feature depends on
BT_CTLR_USER_EXT.

Signed-off-by: Morten Priess <mtpr@oticon.com>
This commit is contained in:
Morten Priess 2020-05-07 11:45:33 +02:00 committed by Carles Cufí
commit 3ed658e9ed
3 changed files with 24 additions and 1 deletions

View file

@ -882,6 +882,15 @@ config BT_CTLR_USER_EVT_RANGE
Number of event types reserved for proprietary use. The range
is typically used when BT_CTLR_USER_EXT is in use.
config BT_CTLR_USER_TICKER_ID_RANGE
int "Range of ticker id constants reserved for proprietary ticker nodes"
depends on BT_CTLR_USER_EXT
default 0
range 0 10
help
Number of ticker ids reserved for proprietary use. The range
is typically used when BT_CTLR_USER_EXT is in use.
config BT_RX_USER_PDU_LEN
int "Maximum supported proprietary PDU buffer length"
depends on BT_CTLR_USER_EXT

View file

@ -54,6 +54,13 @@ enum {
1),
#endif /* CONFIG_BT_CONN */
#if defined(CONFIG_BT_CTLR_USER_EXT) && \
(CONFIG_BT_CTLR_USER_TICKER_ID_RANGE > 0)
TICKER_ID_USER_BASE,
TICKER_ID_USER_LAST = (TICKER_ID_USER_BASE +
CONFIG_BT_CTLR_USER_TICKER_ID_RANGE - 1),
#endif /* CONFIG_BT_CTLR_USER_EXT */
TICKER_ID_MAX,
};

View file

@ -98,11 +98,18 @@
#define FLASH_TICKER_USER_APP_OPS 0
#endif
#if defined(CONFIG_BT_CTLR_USER_EXT)
#define USER_TICKER_NODES CONFIG_BT_CTLR_USER_TICKER_ID_RANGE
#else
#define USER_TICKER_NODES 0
#endif
#define TICKER_NODES (TICKER_ID_ULL_BASE + \
BT_ADV_TICKER_NODES + \
BT_SCAN_TICKER_NODES + \
BT_CONN_TICKER_NODES + \
FLASH_TICKER_NODES)
FLASH_TICKER_NODES + \
USER_TICKER_NODES)
#define TICKER_USER_APP_OPS (TICKER_USER_THREAD_OPS + \
FLASH_TICKER_USER_APP_OPS)
#define TICKER_USER_OPS (TICKER_USER_LLL_OPS + \