Skip to contentSkip to conversation

Bluetooth: Fix RSSI value in device found event from disabling scan

PATCH In review [email protected] 2 participants 2 messages Mar 26, 2014

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Bluetooth: Fix RSSI value in device found event from disabling scan

From: Johan Hedberg <[email protected]>

When sending a pending device found event triggered by disabling LE scanning we should use the stored RSSI instead of sending a zero value.

---
 net/bluetooth/hci_event.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
net/bluetooth/hci_event.c +3 -2
index 2ecb34f2e2ad..ddb518c62ed1 100644
@@ -1091,8 +1091,9 @@ static void hci_cc_le_set_scan_enable(struct hci_dev *hdev,
 			struct discovery_state *d = &hdev->discovery;
 
 			mgmt_device_found(hdev, &d->last_adv_addr, LE_LINK,
-					  d->last_adv_addr_type, NULL, 0, 0,
-					  1, d->last_adv_data,
+					  d->last_adv_addr_type, NULL,
+					  d->last_adv_rssi, 0, 1,
+					  d->last_adv_data,
 					  d->last_adv_data_len, NULL, 0);
 		}
 
Signature · 1 line
1.9.0
maintainer
#1 lore raw

Hi Johan,

Quoted 7 lines

When sending a pending device found event triggered by disabling LE scanning we should use the stored RSSI instead of sending a zero value.

---
net/bluetooth/hci_event.c | 5 +++--

1 file changed, 3 insertions(+), 2 deletions(-)

patch has been applied to bluetooth-next tree.

Regards

Marcel