samples: conn_cb replace to const zsector
It is more efficient and saves part of RAM by replacing it with static one dynamically. Signed-off-by: Lingao Meng <menglingao@xiaomi.com>
This commit is contained in:
parent
23a9594944
commit
8e1682d1ea
31 changed files with 35 additions and 94 deletions
|
@ -418,7 +418,7 @@ void le_phy_updated(struct bt_conn *conn,
|
|||
}
|
||||
#endif
|
||||
|
||||
static struct bt_conn_cb conn_callbacks = {
|
||||
BT_CONN_CB_DEFINE(conn_callbacks) = {
|
||||
.connected = connected,
|
||||
.disconnected = disconnected,
|
||||
.le_param_req = le_param_req,
|
||||
|
@ -576,8 +576,6 @@ static void bt_ready(int err)
|
|||
|
||||
#if defined(CONFIG_BT_CONN)
|
||||
default_conn = NULL;
|
||||
|
||||
bt_conn_cb_register(&conn_callbacks);
|
||||
#endif /* CONFIG_BT_CONN */
|
||||
|
||||
#if defined(CONFIG_BT_PER_ADV_SYNC)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue