summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorAndre Guedes2011-11-04 18:16:52 +0100
committerGustavo F. Padovan2011-11-08 15:54:08 +0100
commit023d50498d04c77b73eed11d849e436ef5639ed2 (patch)
tree8e8e6846b835041937c9f242403c868003478981 /include
parentBluetooth: Create hci_do_inquiry() (diff)
downloadkernel-qcow2-linux-023d50498d04c77b73eed11d849e436ef5639ed2.tar.gz
kernel-qcow2-linux-023d50498d04c77b73eed11d849e436ef5639ed2.tar.xz
kernel-qcow2-linux-023d50498d04c77b73eed11d849e436ef5639ed2.zip
Bluetooth: Create hci_cancel_inquiry()
This patch adds a function to hci_core to cancel an ongoing inquiry. According to the Bluetooth spec, the inquiry cancel command should only be issued after the inquiry command has been issued, a command status event has been received for the inquiry command, and before the inquiry complete event occurs. As HCI_INQUIRY flag is only set just after an inquiry command status event occurs and it is cleared just after an inquiry complete event occurs, the inquiry cancel command should be issued only if HCI_INQUIRY flag is set. Additionally, cancel inquiry related code from stop_discovery() were replaced by a hci_cancel_inquiry() call. Signed-off-by: Andre Guedes <andre.guedes@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Diffstat (limited to 'include')
-rw-r--r--include/net/bluetooth/hci_core.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/net/bluetooth/hci_core.h b/include/net/bluetooth/hci_core.h
index 32f30533fd5d..20db034390b7 100644
--- a/include/net/bluetooth/hci_core.h
+++ b/include/net/bluetooth/hci_core.h
@@ -971,5 +971,6 @@ void hci_le_ltk_reply(struct hci_conn *conn, u8 ltk[16]);
void hci_le_ltk_neg_reply(struct hci_conn *conn);
int hci_do_inquiry(struct hci_dev *hdev, u8 length);
+int hci_cancel_inquiry(struct hci_dev *hdev);
#endif /* __HCI_CORE_H */