Commit cd7ca0ec authored by Marcel Holtmann's avatar Marcel Holtmann Committed by Johan Hedberg

Bluetooth: Fix enabling Authenticated Payload Timeout Expired event

The Authenticated Payload Timeout Expired event is valid for
controllers with BR/EDR Secure Connections support, but also for
LE only controllers supporting LE Ping feature. When either of them
is available enable this event. Previous it was not enabled when
the controller was only supporting LE operation.
Signed-off-by: default avatarMarcel Holtmann <marcel@holtmann.org>
Signed-off-by: default avatarJohan Hedberg <johan.hedberg@intel.com>
parent fa2f1394
...@@ -357,6 +357,7 @@ enum { ...@@ -357,6 +357,7 @@ enum {
/* LE features */ /* LE features */
#define HCI_LE_CONN_PARAM_REQ_PROC 0x02 #define HCI_LE_CONN_PARAM_REQ_PROC 0x02
#define HCI_LE_PING 0x10
/* Connection modes */ /* Connection modes */
#define HCI_CM_ACTIVE 0x0000 #define HCI_CM_ACTIVE 0x0000
......
...@@ -1569,7 +1569,7 @@ static void hci_set_event_mask_page_2(struct hci_request *req) ...@@ -1569,7 +1569,7 @@ static void hci_set_event_mask_page_2(struct hci_request *req)
} }
/* Enable Authenticated Payload Timeout Expired event if supported */ /* Enable Authenticated Payload Timeout Expired event if supported */
if (lmp_ping_capable(hdev)) if (lmp_ping_capable(hdev) || hdev->le_features[0] & HCI_LE_PING)
events[2] |= 0x80; events[2] |= 0x80;
hci_req_add(req, HCI_OP_SET_EVENT_MASK_PAGE_2, sizeof(events), events); hci_req_add(req, HCI_OP_SET_EVENT_MASK_PAGE_2, sizeof(events), events);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment