summaryrefslogtreecommitdiffstats
path: root/include/net/bluetooth
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2011-01-21 12:56:35 +0100
committerGustavo F. Padovan <padovan@profusion.mobi>2011-02-08 04:40:07 +0100
commit2784eb41b1fbb3ff80f4921fe9dbb4c4acb6dc24 (patch)
treee13ea997be45f3d1abf5f3b4733a9da075a0410f /include/net/bluetooth
parentBluetooth: Add support for connect failed management event (diff)
downloadlinux-2784eb41b1fbb3ff80f4921fe9dbb4c4acb6dc24.tar.xz
linux-2784eb41b1fbb3ff80f4921fe9dbb4c4acb6dc24.zip
Bluetooth: Add get_connections managment interface command
This patch adds a get_connections command to the management interface. With this command userspace can get the current list of connected devices. Typically this command would only be used once when enumerating existing adapters. After that the connected and disconnected events are used to track connections. Signed-off-by: Johan Hedberg <johan.hedberg@nokia.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Diffstat (limited to 'include/net/bluetooth')
-rw-r--r--include/net/bluetooth/mgmt.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/net/bluetooth/mgmt.h b/include/net/bluetooth/mgmt.h
index 1d822f2c0f1a..3d8d589fa559 100644
--- a/include/net/bluetooth/mgmt.h
+++ b/include/net/bluetooth/mgmt.h
@@ -130,6 +130,16 @@ struct mgmt_rp_disconnect {
bdaddr_t bdaddr;
} __packed;
+#define MGMT_OP_GET_CONNECTIONS 0x0010
+struct mgmt_cp_get_connections {
+ __le16 index;
+} __packed;
+struct mgmt_rp_get_connections {
+ __le16 index;
+ __le16 conn_count;
+ bdaddr_t conn[0];
+} __packed;
+
#define MGMT_EV_CMD_COMPLETE 0x0001
struct mgmt_ev_cmd_complete {
__le16 opcode;