This is an automated email from the ASF dual-hosted git repository. kopyscinski pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git
commit dd4e011ed6242d1e7fde78b3f582dfd42056177d Author: Ćukasz Rymanowski <lukasz.rymanow...@codecoup.pl> AuthorDate: Wed Feb 12 21:37:02 2020 +0100 nimble/host: Make gap init before att This is needed as eatt is registering listener in gap nowadays --- nimble/host/src/ble_hs.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/nimble/host/src/ble_hs.c b/nimble/host/src/ble_hs.c index e130c1ca..bab8fe11 100644 --- a/nimble/host/src/ble_hs.c +++ b/nimble/host/src/ble_hs.c @@ -734,6 +734,11 @@ ble_hs_init(void) rc = ble_l2cap_init(); SYSINIT_PANIC_ASSERT(rc == 0); +#endif + rc = ble_gap_init(); + SYSINIT_PANIC_ASSERT(rc == 0); +#if NIMBLE_BLE_CONNECT + rc = ble_att_init(); SYSINIT_PANIC_ASSERT(rc == 0); @@ -746,8 +751,6 @@ ble_hs_init(void) rc = ble_gatts_init(); SYSINIT_PANIC_ASSERT(rc == 0); #endif - rc = ble_gap_init(); - SYSINIT_PANIC_ASSERT(rc == 0); ble_hs_stop_init();