Bluetooth: Add set_connectable management command
This patch adds a set_connectable command as well as a corresponding event to the management interface. It's mainly useful for setting an adapter as connectable from a non-initialized state as well as setting an already initialized adapter as non-connectable (mostly useful for qualification purposes). Signed-off-by: Johan Hedberg <johan.hedberg@nokia.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
This commit is contained in:
committed by
Gustavo F. Padovan
parent
73f22f6238
commit
9fbcbb455d
@@ -47,6 +47,7 @@ struct mgmt_rp_read_info {
|
||||
__le16 index;
|
||||
__u8 type;
|
||||
__u8 powered;
|
||||
__u8 connectable;
|
||||
__u8 discoverable;
|
||||
__u8 pairable;
|
||||
__u8 sec_mode;
|
||||
@@ -78,6 +79,16 @@ struct mgmt_rp_set_discoverable {
|
||||
__u8 discoverable;
|
||||
} __packed;
|
||||
|
||||
#define MGMT_OP_SET_CONNECTABLE 0x0007
|
||||
struct mgmt_cp_set_connectable {
|
||||
__le16 index;
|
||||
__u8 connectable;
|
||||
} __packed;
|
||||
struct mgmt_rp_set_connectable {
|
||||
__le16 index;
|
||||
__u8 connectable;
|
||||
} __packed;
|
||||
|
||||
#define MGMT_EV_CMD_COMPLETE 0x0001
|
||||
struct mgmt_ev_cmd_complete {
|
||||
__le16 opcode;
|
||||
@@ -117,3 +128,9 @@ struct mgmt_ev_discoverable {
|
||||
__le16 index;
|
||||
__u8 discoverable;
|
||||
} __packed;
|
||||
|
||||
#define MGMT_EV_CONNECTABLE 0x0008
|
||||
struct mgmt_ev_connectable {
|
||||
__le16 index;
|
||||
__u8 connectable;
|
||||
} __packed;
|
||||
|
Reference in New Issue
Block a user