zephyr/subsys/bluetooth/host/shell
Lyle Zhu 8d819954e8 Bluetooth: Classic: Refactor query and deletion of bonding information
In current implementation, the bonding information of classic is
queried by calling the function `bt_foreach_bond()`. And the bonding
information of classic is deleted by calling `bt_unpair()`.

There are two issues if the LE and classic are bonded at same time for
dual mode peer device.
Issue 1, for the function `bt_foreach_bond()`, there are two bonding
information will be found. But there is no way to find which bonding
information belongs to LE or classic.
Issue 2, For the function `bt_unpair()`, all bonding information will
be deleted if the passed address is the public address. But there is
no way to delete the bonding information of LE or classic.

Remove the calling of function `bt_foreach_bond_br()` from the
function `bt_foreach_bond()`. And rename it to `bt_br_foreach_bond()`,
and public it as an API to query the bonding information of classic.

Remove the calling of function `bt_keys_link_key_clear_addr()` from
the function `bt_unpair()`. Add an API `bt_br_unpair()` to delete the
bonding information of classic.

Add a `br_bond_deleted` to structure `bt_conn_auth_info_cb` for
classic. The callback will be triggered if the bonding information has
been deleted by the function `bt_br_unpair()`.

Add a `clear` shell command for classic to delete the bonding
information.

Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
2025-04-01 22:18:40 +02:00
..
bt.c Bluetooth: Classic: Refactor query and deletion of bonding information 2025-04-01 22:18:40 +02:00
bt.h bluetooth: shell: completely eliminate the dependency on ctx_shell 2025-01-14 10:56:16 +01:00
CMakeLists.txt bluetooth: shell: move bt_shell_private.c to common folder 2025-01-14 10:56:16 +01:00
cs.c bluetooth: Host: Rename CS tone antenna configurations 2025-03-11 08:59:19 +01:00
gatt.c bluetooth: shell: move bt_shell_private.c to common folder 2025-01-14 10:56:16 +01:00
iso.c Bluetooth: ISO: Make setting ISO data explicit 2025-03-19 10:56:57 +01:00
l2cap.c bluetooth: shell: move bt_shell_private.c to common folder 2025-01-14 10:56:16 +01:00