Bluetooth: Add missing confirm_name field to mgmt_ev_device_found
Subsystems (2)
PATCH 1/3 Bluetooth: Add missing confirm_name field to mgmt_ev_device_found
From: Johan Hedberg <[email protected]>
This patch adds a missing confirm_name field to mgmt_ev_device_found. Support for setting the correct value for this field is not implemented yet, but having it part of the struct definition ensures that user-space gets correct sized device_found events and is thereby able to do at least rudimentary parsing of them.
--- include/net/bluetooth/mgmt.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
include/net/bluetooth/mgmt.h +1 -0
@@ -357,6 +357,7 @@ struct mgmt_ev_device_found {struct mgmt_addr_info addr;__u8 dev_class[3 ];__s8 rssi; +__u8 confirm_name;__u8 eir[HCI_MAX_EIR_LENGTH ]; } __packed;
Signature · 1 line
1.7.7.3
PATCH 2/3 Bluetooth: Fix mgmt_(block,unblock)_device opcodes
From: Johan Hedberg <[email protected]>
This patch fixes the opcodes of the Block/Unblock device commands to match with what user-space expects and to confirm with the latest mgmt specification. The reason the values were wrong was a missing Confirm Name command definition (which will be added by a subsequent patch).
--- include/net/bluetooth/mgmt.h | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
include/net/bluetooth/mgmt.h +2 -2
@@ -268,12 +268,12 @@ struct mgmt_cp_start_discovery {#define MGMT_OP_STOP_DISCOVERY 0x0022 -#define MGMT_OP_BLOCK_DEVICE 0x0023 +#define MGMT_OP_BLOCK_DEVICE 0x0024struct mgmt_cp_block_device {bdaddr_t bdaddr; } __packed; -#define MGMT_OP_UNBLOCK_DEVICE 0x0024 +#define MGMT_OP_UNBLOCK_DEVICE 0x0025struct mgmt_cp_unblock_device {bdaddr_t bdaddr; } __packed;
Signature · 1 line
1.7.7.3
PATCH 3/3 Bluetooth: Add missing mgmt_confirm_name command definition
In reply to [email protected]From: Johan Hedberg <[email protected]>
This patch adds the necessary structs for the Confirm Name command. This ensures that the protocol definitions are up to date with the latest mgmt specification. The actual implementation of the command will follow in a later patch-set.
--- include/net/bluetooth/mgmt.h | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-)
include/net/bluetooth/mgmt.h +10 -0
@@ -268,6 +268,16 @@ struct mgmt_cp_start_discovery {#define MGMT_OP_STOP_DISCOVERY 0x0022 +#define MGMT_OP_CONFIRM_NAME 0x0023 +struct mgmt_cp_confirm_name { +bdaddr_t bdaddr; +__u8 name_known; +} __packed; +struct mgmt_rp_confirm_name { +bdaddr_t bdaddr; +__u8 status; +} __packed; +#define MGMT_OP_BLOCK_DEVICE 0x0024struct mgmt_cp_block_device {bdaddr_t bdaddr;
Signature · 1 line
1.7.7.3
Re: [PATCH 3/3] Bluetooth: Add missing mgmt_confirm_name command definition
Hi Johan,
Quoted 11 lines · * [email protected] <[email protected]> [2011-12-19 14:29:08 +0200]:
From: Johan Hedberg <[email protected]>
This patch adds the necessary structs for the Confirm Name command. This ensures that the protocol definitions are up to date with the latest mgmt specification. The actual implementation of the command will follow in a later patch-set.
Signed-off-by Johan Hedberg <[email protected]>--- include/net/bluetooth/mgmt.h | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-)
The 3 patches have been applied. Thanks.
Gustavo