浏览代码

[Bluetooth] Handle command complete event for exit periodic inquiry

The command complete event of the exit periodic inquiry command must
clear the HCI_INQUIRY flag and finish the HCI request.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Marcel Holtmann 18 年之前
父节点
当前提交
defc761bc2
共有 2 个文件被更改,包括 3 次插入0 次删除
  1. 2 0
      include/net/bluetooth/hci.h
  2. 1 0
      net/bluetooth/hci_event.c

+ 2 - 0
include/net/bluetooth/hci.h

@@ -340,6 +340,8 @@ struct hci_cp_inquiry {
 
 #define OCF_INQUIRY_CANCEL	0x0002
 
+#define OCF_EXIT_PERIODIC_INQ	0x0004
+
 #define OCF_LINK_KEY_REPLY	0x000B
 struct hci_cp_link_key_reply {
 	bdaddr_t bdaddr;

+ 1 - 0
net/bluetooth/hci_event.c

@@ -62,6 +62,7 @@ static void hci_cc_link_ctl(struct hci_dev *hdev, __u16 ocf, struct sk_buff *skb
 
 	switch (ocf) {
 	case OCF_INQUIRY_CANCEL:
+	case OCF_EXIT_PERIODIC_INQ:
 		status = *((__u8 *) skb->data);
 
 		if (status) {