Bluetooth: Controller: Include mem and ecb in-system tests

Include mem and ecb implementation in-system tests.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
This commit is contained in:
Vinayak Kariappa Chettimada 2024-09-15 15:21:32 +02:00 committed by Benjamin Cabé
parent 17846ed1f4
commit 9678ff2041
8 changed files with 18 additions and 9 deletions

View file

@ -15,6 +15,7 @@
#include <zephyr/bluetooth/hci_types.h>
#include "hal/cpu.h"
#include "hal/ecb.h"
#include "hal/ccm.h"
#include "hal/cntr.h"
#include "hal/ticker.h"
@ -760,7 +761,19 @@ int ll_init(struct k_sem *sem_rx)
}
#if defined(CONFIG_BT_CTLR_TEST)
err = mem_ut();
if (err) {
return err;
}
err = ecb_ut();
if (err) {
return err;
}
#if defined(CONFIG_BT_CTLR_CHAN_SEL_2)
lll_chan_sel_2_ut();
#endif /* CONFIG_BT_CTLR_CHAN_SEL_2 */
#endif /* CONFIG_BT_CTLR_TEST */
return 0;

View file

@ -137,7 +137,7 @@ uint8_t mem_nz(uint8_t *src, uint16_t len)
/**
* @brief Unit test
*/
uint32_t mem_ut(void)
int mem_ut(void)
{
#define BLOCK_SIZE MROUND(10)
#define BLOCK_COUNT 10

View file

@ -64,4 +64,4 @@ uint16_t mem_index_get(const void *mem, const void *mem_pool, uint16_t mem_size)
void mem_rcopy(uint8_t *dst, uint8_t const *src, uint16_t len);
uint8_t mem_nz(uint8_t *src, uint16_t len);
uint32_t mem_ut(void);
int mem_ut(void);

View file

@ -29,7 +29,6 @@ CONFIG_BT_CTLR_SCAN_REQ_RSSI=y
CONFIG_BT_CTLR_SCAN_INDICATION=y
CONFIG_BT_CTLR_PROFILE_ISR=y
CONFIG_BT_CTLR_DEBUG_PINS=y
CONFIG_BT_CTLR_TEST=y
CONFIG_BT_TICKER_EXT=n
CONFIG_BT_TICKER_SLOT_AGNOSTIC=y
CONFIG_BT_TICKER_PREFER_START_BEFORE_STOP=y

View file

@ -1 +1,4 @@
CONFIG_TEST_LL_INTERFACE=y
# This one bsim test is covering mem, ecb and channel selection unit testing
CONFIG_BT_CTLR_TEST=y

View file

@ -20,7 +20,5 @@ CONFIG_BT_CTLR_ISO_TX_BUFFER_SIZE=255
CONFIG_BT_CTLR_ADV_ISO_PDU_LEN_MAX=247
CONFIG_BT_CTLR_SYNC_ISO_PDU_LEN_MAX=251
CONFIG_BT_CTLR_TEST=y
CONFIG_BT_BUF_ACL_TX_SIZE=251
CONFIG_BT_BUF_ACL_RX_SIZE=255

View file

@ -7,8 +7,6 @@ CONFIG_BT_PER_ADV=y
CONFIG_BT_PER_ADV_SYNC=y
CONFIG_BT_CTLR_ADV_EXT=y
CONFIG_BT_CTLR_TEST=y
CONFIG_BT_ATT_PREPARE_COUNT=2
CONFIG_BT_GATT_CLIENT=y
CONFIG_BT_L2CAP_DYNAMIC_CHANNEL=y

View file

@ -20,5 +20,3 @@ CONFIG_BT_CTLR_ADV_ISO_PDU_LEN_MAX=251
CONFIG_BT_CTLR_SYNC_ISO_PDU_LEN_MAX=251
CONFIG_BT_CTLR_ISO_VENDOR_DATA_PATH=y
CONFIG_BT_CTLR_TEST=y