aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/bluetooth
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/bluetooth')
-rw-r--r--include/net/bluetooth/hci.h17
-rw-r--r--include/net/bluetooth/hci_core.h16
-rw-r--r--include/net/bluetooth/mgmt.h12
3 files changed, 45 insertions, 0 deletions
diff --git a/include/net/bluetooth/hci.h b/include/net/bluetooth/hci.h
index ac4de1afe046..b989a8c3e01a 100644
--- a/include/net/bluetooth/hci.h
+++ b/include/net/bluetooth/hci.h
@@ -426,6 +426,18 @@ struct hci_rp_user_confirm_reply {
426 426
427#define HCI_OP_USER_CONFIRM_NEG_REPLY 0x042d 427#define HCI_OP_USER_CONFIRM_NEG_REPLY 0x042d
428 428
429#define HCI_OP_REMOTE_OOB_DATA_REPLY 0x0430
430struct hci_cp_remote_oob_data_reply {
431 bdaddr_t bdaddr;
432 __u8 hash[16];
433 __u8 randomizer[16];
434} __packed;
435
436#define HCI_OP_REMOTE_OOB_DATA_NEG_REPLY 0x0433
437struct hci_cp_remote_oob_data_neg_reply {
438 bdaddr_t bdaddr;
439} __packed;
440
429#define HCI_OP_IO_CAPABILITY_NEG_REPLY 0x0434 441#define HCI_OP_IO_CAPABILITY_NEG_REPLY 0x0434
430struct hci_cp_io_capability_neg_reply { 442struct hci_cp_io_capability_neg_reply {
431 bdaddr_t bdaddr; 443 bdaddr_t bdaddr;
@@ -962,6 +974,11 @@ struct hci_ev_user_confirm_req {
962 __le32 passkey; 974 __le32 passkey;
963} __packed; 975} __packed;
964 976
977#define HCI_EV_REMOTE_OOB_DATA_REQUEST 0x35
978struct hci_ev_remote_oob_data_request {
979 bdaddr_t bdaddr;
980} __packed;
981
965#define HCI_EV_SIMPLE_PAIR_COMPLETE 0x36 982#define HCI_EV_SIMPLE_PAIR_COMPLETE 0x36
966struct hci_ev_simple_pair_complete { 983struct hci_ev_simple_pair_complete {
967 __u8 status; 984 __u8 status;
diff --git a/include/net/bluetooth/hci_core.h b/include/net/bluetooth/hci_core.h
index fd9b8a31e5b0..87bff518b54b 100644
--- a/include/net/bluetooth/hci_core.h
+++ b/include/net/bluetooth/hci_core.h
@@ -82,6 +82,13 @@ struct link_key {
82 u8 pin_len; 82 u8 pin_len;
83}; 83};
84 84
85struct oob_data {
86 struct list_head list;
87 bdaddr_t bdaddr;
88 u8 hash[16];
89 u8 randomizer[16];
90};
91
85#define NUM_REASSEMBLY 4 92#define NUM_REASSEMBLY 4
86struct hci_dev { 93struct hci_dev {
87 struct list_head list; 94 struct list_head list;
@@ -169,6 +176,8 @@ struct hci_dev {
169 176
170 struct list_head link_keys; 177 struct list_head link_keys;
171 178
179 struct list_head remote_oob_data;
180
172 struct hci_dev_stats stat; 181 struct hci_dev_stats stat;
173 182
174 struct sk_buff_head driver_init; 183 struct sk_buff_head driver_init;
@@ -505,6 +514,13 @@ int hci_add_link_key(struct hci_dev *hdev, int new_key, bdaddr_t *bdaddr,
505 u8 *key, u8 type, u8 pin_len); 514 u8 *key, u8 type, u8 pin_len);
506int hci_remove_link_key(struct hci_dev *hdev, bdaddr_t *bdaddr); 515int hci_remove_link_key(struct hci_dev *hdev, bdaddr_t *bdaddr);
507 516
517int hci_remote_oob_data_clear(struct hci_dev *hdev);
518struct oob_data *hci_find_remote_oob_data(struct hci_dev *hdev,
519 bdaddr_t *bdaddr);
520int hci_add_remote_oob_data(struct hci_dev *hdev, bdaddr_t *bdaddr, u8 *hash,
521 u8 *randomizer);
522int hci_remove_remote_oob_data(struct hci_dev *hdev, bdaddr_t *bdaddr);
523
508void hci_del_off_timer(struct hci_dev *hdev); 524void hci_del_off_timer(struct hci_dev *hdev);
509 525
510void hci_event_packet(struct hci_dev *hdev, struct sk_buff *skb); 526void hci_event_packet(struct hci_dev *hdev, struct sk_buff *skb);
diff --git a/include/net/bluetooth/mgmt.h b/include/net/bluetooth/mgmt.h
index 6ebb1265c36e..1a6283f9fee8 100644
--- a/include/net/bluetooth/mgmt.h
+++ b/include/net/bluetooth/mgmt.h
@@ -183,6 +183,18 @@ struct mgmt_rp_read_local_oob_data {
183 __u8 randomizer[16]; 183 __u8 randomizer[16];
184} __packed; 184} __packed;
185 185
186#define MGMT_OP_ADD_REMOTE_OOB_DATA 0x0019
187struct mgmt_cp_add_remote_oob_data {
188 bdaddr_t bdaddr;
189 __u8 hash[16];
190 __u8 randomizer[16];
191} __packed;
192
193#define MGMT_OP_REMOVE_REMOTE_OOB_DATA 0x001A
194struct mgmt_cp_remove_remote_oob_data {
195 bdaddr_t bdaddr;
196} __packed;
197
186#define MGMT_EV_CMD_COMPLETE 0x0001 198#define MGMT_EV_CMD_COMPLETE 0x0001
187struct mgmt_ev_cmd_complete { 199struct mgmt_ev_cmd_complete {
188 __le16 opcode; 200 __le16 opcode;