From 2945143edd41a266950baa6dd492ed319d71f363 Mon Sep 17 00:00:00 2001 From: Morten Priess Date: Thu, 30 Jan 2020 14:51:39 +0100 Subject: [PATCH] Bluetooth: controller: split: Force central cleanup on MIC error Since a peer MIC failure closes the event, it does not allow a terminate acknowledge. For that reason a peer MIC fail for central role must force a conn_cleanup. Signed-off-by: Morten Priess --- subsys/bluetooth/controller/ll_sw/ull_conn.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/subsys/bluetooth/controller/ll_sw/ull_conn.c b/subsys/bluetooth/controller/ll_sw/ull_conn.c index 537ef58e003..6e27272bbf7 100644 --- a/subsys/bluetooth/controller/ll_sw/ull_conn.c +++ b/subsys/bluetooth/controller/ll_sw/ull_conn.c @@ -999,7 +999,8 @@ void ull_conn_done(struct node_rx_event_done *done) 0 || #endif /* CONFIG_BT_PERIPHERAL */ #if defined(CONFIG_BT_CENTRAL) - conn->master.terminate_ack + conn->master.terminate_ack || + (reason_peer == BT_HCI_ERR_TERM_DUE_TO_MIC_FAIL) #else /* CONFIG_BT_CENTRAL */ 1 #endif /* CONFIG_BT_CENTRAL */