Bluetooth: Mesh: Network loopback
Changes the local network interface to exclusively handle packets for the local interface, duplicating the buffers in the process. The loopback mechanism now operates its own packet pool for the local interface queue. The loopback is moved ahead of encryption, allowing the local interface packets to go back up the stack without network crypto, saving a full round of encrypt/decrypt for self-send. Packets for group addresses the local node subscribes to are now duplicated, with one unencrypted variant going into the network queue, and the network bound packets following the regular path to the advertiser. Introduces one new configuration for setting the number of loopback buffers. Signed-off-by: Trond Einar Snekvik <Trond.Einar.Snekvik@nordicsemi.no>
This commit is contained in:
parent
e3eb9bedec
commit
3c8e5b0e1c
5 changed files with 197 additions and 92 deletions
|
@ -3535,6 +3535,8 @@ void bt_mesh_subnet_del(struct bt_mesh_subnet *sub, bool store)
|
|||
bt_mesh_friend_clear_net_idx(sub->net_idx);
|
||||
}
|
||||
|
||||
bt_mesh_net_loopback_clear(sub->net_idx);
|
||||
|
||||
if (IS_ENABLED(CONFIG_BT_SETTINGS) && store) {
|
||||
bt_mesh_clear_subnet(sub);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue