linux-stable/net/bluetooth
Luiz Augusto von Dentz b547b3ad8a Bluetooth: hci_core: Fix not handling hdev->le_num_of_adv_sets=1
[ Upstream commit e77f43d531 ]

If hdev->le_num_of_adv_sets is set to 1 it means that only handle 0x00
can be used, but since the MGMT interface instances start from 1
(instance 0 means all instances in case of MGMT_OP_REMOVE_ADVERTISING)
the code needs to map the instance to handle otherwise users will not be
able to advertise as instance 1 would attempt to use handle 0x01.

Fixes: 1d0fac2c38 ("Bluetooth: Use controller sets when available")
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-05-30 09:49:31 +02:00
..
bnep Bluetooth: Consolidate code around sk_alloc into a helper function 2023-08-11 11:36:50 -07:00
cmtp
hidp Bluetooth: Init sk_peer_* on bt_sock_alloc 2023-08-11 11:37:22 -07:00
rfcomm Bluetooth: RFCOMM: Fix not validating setsockopt user input 2024-04-17 11:23:32 +02:00
6lowpan.c Bluetooth: hci_conn: Always use sk_timeo as conn_timeout 2024-05-02 16:35:18 +02:00
Kconfig Bluetooth: Remove BT_HS 2024-03-26 18:16:53 -04:00
Makefile Bluetooth: Remove BT_HS 2024-03-26 18:16:53 -04:00
af_bluetooth.c Bluetooth: af_bluetooth: Fix deadlock 2024-03-26 18:16:54 -04:00
aosp.c
aosp.h
coredump.c Bluetooth: Remove unnecessary NULL check before vfree() 2023-08-11 11:56:54 -07:00
ecdh_helper.c Bluetooth: Use crypto_wait_req 2023-02-13 18:34:48 +08:00
ecdh_helper.h
eir.c Bluetooth: Fix eir name length 2024-03-26 18:16:56 -04:00
eir.h
hci_codec.c
hci_codec.h
hci_conn.c Bluetooth: HCI: Remove HCI_AMP support 2024-05-30 09:49:30 +02:00
hci_core.c Bluetooth: hci_core: Fix not handling hdev->le_num_of_adv_sets=1 2024-05-30 09:49:31 +02:00
hci_debugfs.c Bluetooth: Fix TOCTOU in HCI debugfs implementation 2024-04-10 16:38:02 +02:00
hci_debugfs.h
hci_event.c Bluetooth: hci_conn, hci_sync: Use __counted_by() to avoid -Wfamnae warnings 2024-05-30 09:49:31 +02:00
hci_request.c Bluetooth: Fix memory leak in hci_req_sync_complete() 2024-04-17 11:23:25 +02:00
hci_request.h Bluetooth: Delete unused hci_req_prepare_suspend() declaration 2023-09-20 10:55:29 -07:00
hci_sock.c Bluetooth: HCI: Remove HCI_AMP support 2024-05-30 09:49:30 +02:00
hci_sync.c Bluetooth: hci_core: Fix not handling hdev->le_num_of_adv_sets=1 2024-05-30 09:49:31 +02:00
hci_sysfs.c Bluetooth: Fix double free in hci_conn_cleanup 2023-10-23 11:05:11 -07:00
iso.c Bluetooth: ISO: Make iso_get_sock_listen generic 2024-05-30 09:49:30 +02:00
l2cap_core.c Bluetooth: HCI: Remove HCI_AMP support 2024-05-30 09:49:30 +02:00
l2cap_sock.c Bluetooth: compute LE flow credits based on recvbuf space 2024-05-30 09:49:29 +02:00
leds.c
leds.h
lib.c Bluetooth: Add documentation to exported functions in lib 2023-12-22 12:54:55 -05:00
mgmt.c Bluetooth: HCI: Remove HCI_AMP support 2024-05-30 09:49:30 +02:00
mgmt_config.c
mgmt_config.h
mgmt_util.c
mgmt_util.h
msft.c Bluetooth: msft: fix slab-use-after-free in msft_do_close() 2024-05-17 12:14:51 +02:00
msft.h Bluetooth: msft: fix slab-use-after-free in msft_do_close() 2024-05-17 12:14:51 +02:00
sco.c Bluetooth: L2CAP: Fix div-by-zero in l2cap_le_flowctl_init() 2024-05-25 16:28:38 +02:00
selftest.c
selftest.h
smp.c Bluetooth: MGMT/SMP: Fix address type when using SMP over BREDR/LE 2023-12-15 11:53:09 -05:00
smp.h