summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2010-12-16 10:00:37 +0200
committerGustavo F. Padovan <padovan@profusion.mobi>2011-02-08 01:40:04 -0200
commit5add6af8fcbce269cac2457584c0ebfda055474a (patch)
treef27f5eb78f8193f636c576c979391c63bfc50c29 /include
parentab81cbf99c881ca2b9a83682a8722fc84b2483d2 (diff)
downloadlinux-3.10-5add6af8fcbce269cac2457584c0ebfda055474a.tar.gz
linux-3.10-5add6af8fcbce269cac2457584c0ebfda055474a.tar.bz2
linux-3.10-5add6af8fcbce269cac2457584c0ebfda055474a.zip
Bluetooth: Add support for management powered event
This patch adds support for the powered event that's used to indicate to userspace when the powered state of a local adapter changes. Signed-off-by: Johan Hedberg <johan.hedberg@nokia.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Diffstat (limited to 'include')
-rw-r--r--include/net/bluetooth/hci_core.h1
-rw-r--r--include/net/bluetooth/mgmt.h6
2 files changed, 7 insertions, 0 deletions
diff --git a/include/net/bluetooth/hci_core.h b/include/net/bluetooth/hci_core.h
index 75c4f201c1c..32e11b37ef2 100644
--- a/include/net/bluetooth/hci_core.h
+++ b/include/net/bluetooth/hci_core.h
@@ -673,6 +673,7 @@ void hci_send_to_sock(struct hci_dev *hdev, struct sk_buff *skb);
int mgmt_control(struct sock *sk, struct msghdr *msg, size_t len);
int mgmt_index_added(u16 index);
int mgmt_index_removed(u16 index);
+int mgmt_powered(u16 index, u8 powered);
/* HCI info for socket */
#define hci_pi(sk) ((struct hci_pinfo *) sk)
diff --git a/include/net/bluetooth/mgmt.h b/include/net/bluetooth/mgmt.h
index ca29c1367ff..0ac1520573e 100644
--- a/include/net/bluetooth/mgmt.h
+++ b/include/net/bluetooth/mgmt.h
@@ -85,3 +85,9 @@ struct mgmt_ev_index_added {
struct mgmt_ev_index_removed {
__le16 index;
} __packed;
+
+#define MGMT_EV_POWERED 0x0006
+struct mgmt_ev_powered {
+ __le16 index;
+ __u8 powered;
+} __packed;