You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by an...@apache.org on 2022/04/16 09:48:25 UTC

[mynewt-nimble] branch master updated: nimble/ll: Fix chanmap initialization

This is an automated email from the ASF dual-hosted git repository.

andk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git


The following commit(s) were added to refs/heads/master by this push:
     new 5d9571fa nimble/ll: Fix chanmap initialization
5d9571fa is described below

commit 5d9571fa0d374b31fc9facdde5b7bd36d9e99fd4
Author: Andrzej Kaczmarek <an...@codecoup.pl>
AuthorDate: Fri Apr 15 13:19:07 2022 +0200

    nimble/ll: Fix chanmap initialization
---
 nimble/controller/src/ble_ll.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/nimble/controller/src/ble_ll.c b/nimble/controller/src/ble_ll.c
index 185fb583..23b105fa 100644
--- a/nimble/controller/src/ble_ll.c
+++ b/nimble/controller/src/ble_ll.c
@@ -1642,7 +1642,8 @@ ble_ll_reset(void)
 
     /* Enable all channels in channel map */
     g_ble_ll_data.chan_map_num_used = BLE_PHY_NUM_DATA_CHANS;
-    memset(g_ble_ll_data.chan_map, 0xff, BLE_LL_CHAN_MAP_LEN);
+    memset(g_ble_ll_data.chan_map, 0xff, BLE_LL_CHAN_MAP_LEN - 1);
+    g_ble_ll_data.chan_map[4] = 0x1f;
 
 #if MYNEWT_VAL(BLE_LL_ROLE_PERIPHERAL) || MYNEWT_VAL(BLE_LL_ROLE_CENTRAL)
     /* Reset connection module */