Bluetooth: bt_gatt_service_register() assumes sc delayed work handler is initialized #9785
Labels
area: Bluetooth
bug
The issue is a bug, or the PR is fixing a bug
priority: high
High impact/importance bug
My understanding is that it should be possible, or at least desirable, to register a GATT service prior to
bt_enable()
. This would it make it possible, for example, to register services automatically withSYS_INIT
.When I try to do that, I am hitting a bus fault but symptoms may vary I gues (I am running a peripheral example on a Nordic DK). I believe the issue is in
sc_indicate()
inbt_gatt_service_register()
which attempts to submit some work to a delayed work queue without it being initialized. Specificallyk_delayed_work_submit(&sc->work, SC_TIMEOUT);
is not initialized untilbt_gatt_init()
has been called.The text was updated successfully, but these errors were encountered: