aboutsummaryrefslogtreecommitdiffstats
path: root/net/bluetooth/hci_request.h
diff options
context:
space:
mode:
authorMichał Narajowski <michal.narajowski@codecoup.pl>2016-10-19 10:20:27 +0200
committerMarcel Holtmann <marcel@holtmann.org>2016-10-19 18:42:37 +0200
commitf61851f64b171a684f5a1fa78325756dbbaadadc (patch)
treea6296b4aecf3903a33de96608eef7c27bcbd1663 /net/bluetooth/hci_request.h
parentBluetooth: hci_bcm: Fix autosuspend PM for Lenovo ThinkPad 8 (diff)
downloadlinux-dev-f61851f64b171a684f5a1fa78325756dbbaadadc.tar.xz
linux-dev-f61851f64b171a684f5a1fa78325756dbbaadadc.zip
Bluetooth: Fix append max 11 bytes of name to scan rsp data
Append maximum of 10 + 1 bytes of name to scan response data. Complete name is appended only if exists and is <= 10 characters. Else append short name if exists or shorten complete name if not. This makes sure name is consistent across multiple advertising instances. Signed-off-by: Michał Narajowski <michal.narajowski@codecoup.pl> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/bluetooth/hci_request.h')
-rw-r--r--net/bluetooth/hci_request.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/net/bluetooth/hci_request.h b/net/bluetooth/hci_request.h
index 6b06629245a8..dde77bd59f91 100644
--- a/net/bluetooth/hci_request.h
+++ b/net/bluetooth/hci_request.h
@@ -106,6 +106,8 @@ static inline void hci_update_background_scan(struct hci_dev *hdev)
void hci_request_setup(struct hci_dev *hdev);
void hci_request_cancel_all(struct hci_dev *hdev);
+u8 append_local_name(struct hci_dev *hdev, u8 *ptr, u8 ad_len);
+
static inline u16 eir_append_data(u8 *eir, u16 eir_len, u8 type,
u8 *data, u8 data_len)
{