Skip to content

Commit e2835e2

Browse files
trond-snekviknashif
authored andcommitted
[backport v1.14] Bluetooth: Mesh: Move RPL clear to bt_mesh_reset
Moves the clearing of RPL out of the bt_mesh_rx_reset() to avoid it being called outside of the node reset procedure. Fixes #29858 for v1.14. Signed-off-by: Trond Einar Snekvik <[email protected]>
1 parent 3d61897 commit e2835e2

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

subsys/bluetooth/host/mesh/main.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,12 @@ void bt_mesh_reset(void)
106106
bt_mesh_rx_reset();
107107
bt_mesh_tx_reset();
108108

109+
if (IS_ENABLED(CONFIG_BT_SETTINGS)) {
110+
bt_mesh_clear_rpl();
111+
} else {
112+
(void)memset(bt_mesh.rpl, 0, sizeof(bt_mesh.rpl));
113+
}
114+
109115
if (IS_ENABLED(CONFIG_BT_MESH_LOW_POWER)) {
110116
bt_mesh_lpn_disable(true);
111117
}

subsys/bluetooth/host/mesh/transport.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1509,12 +1509,6 @@ void bt_mesh_rx_reset(void)
15091509
for (i = 0; i < ARRAY_SIZE(seg_rx); i++) {
15101510
seg_rx_reset(&seg_rx[i], true);
15111511
}
1512-
1513-
if (IS_ENABLED(CONFIG_BT_SETTINGS)) {
1514-
bt_mesh_clear_rpl();
1515-
} else {
1516-
(void)memset(bt_mesh.rpl, 0, sizeof(bt_mesh.rpl));
1517-
}
15181512
}
15191513

15201514
void bt_mesh_tx_reset(void)

0 commit comments

Comments
 (0)