Bluetooth: MGMT: Fix marking SCAN_RSP as not connectable
authorLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Wed, 7 Jun 2023 19:33:47 +0000 (12:33 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 19 Jul 2023 14:22:02 +0000 (16:22 +0200)
commitc07efe4dbc12d7046fe2480c1d798c7df4f2c1be
tree3f60262166ffcc48c0319b8bf4fc47dc82376417
parent40ca66eef3d77484788ca17c59a4bffbf8d112e9
Bluetooth: MGMT: Fix marking SCAN_RSP as not connectable

[ Upstream commit 73f55453ea5236a586a7f1b3d5e2ee051d655351 ]

When receiving a scan response there is no way to know if the remote
device is connectable or not, so when it cannot be merged don't
make any assumption and instead just mark it with a new flag defined as
MGMT_DEV_FOUND_SCAN_RSP so userspace can tell it is a standalone
SCAN_RSP.

Link: https://lore.kernel.org/linux-bluetooth/CABBYNZ+CYMsDSPTxBn09Js3BcdC-x7vZFfyLJ3ppZGGwJKmUTw@mail.gmail.com/
Fixes: c70a7e4cc8d2 ("Bluetooth: Add support for Not Connectable flag for Device Found events")
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
include/net/bluetooth/mgmt.h
net/bluetooth/hci_event.c