Skip to content

Commit 3bcaa6f

Browse files
rugeGerritsenaescolar
authored andcommitted
Bluetooth: Controller: Handle return value of ll_deinit()
This call may fail. Handling the return value makes it easier to catch bugs. Signed-off-by: Rubin Gerritsen <[email protected]>
1 parent d7e6d6e commit 3bcaa6f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

subsys/bluetooth/controller/hci/hci_driver.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -881,10 +881,12 @@ static int hci_driver_open(const struct device *dev, bt_hci_recv_t recv)
881881

882882
static int hci_driver_close(const struct device *dev)
883883
{
884+
int err;
884885
struct hci_driver_data *data = dev->data;
885886

886887
/* Resetting the LL stops all roles */
887-
ll_deinit();
888+
err = ll_deinit();
889+
LL_ASSERT(!err);
888890

889891
/* Abort prio RX thread */
890892
k_thread_abort(&prio_recv_thread_data);

0 commit comments

Comments
 (0)