kvm tools, setup: Create private directory
[linux-2.6/next.git] / include / net / bluetooth / smp.h
blob8f2edbf979dceb9f5461074fd18e45382dc6d273
1 #ifndef __SMP_H
2 #define __SMP_H
4 struct smp_command_hdr {
5 __u8 code;
6 } __packed;
8 #define SMP_CMD_PAIRING_REQ 0x01
9 #define SMP_CMD_PAIRING_RSP 0x02
10 struct smp_cmd_pairing {
11 __u8 io_capability;
12 __u8 oob_flag;
13 __u8 auth_req;
14 __u8 max_key_size;
15 __u8 init_key_dist;
16 __u8 resp_key_dist;
17 } __packed;
19 #define SMP_CMD_PAIRING_CONFIRM 0x03
20 struct smp_cmd_pairing_confirm {
21 __u8 confirm_val[16];
22 } __packed;
24 #define SMP_CMD_PAIRING_RANDOM 0x04
25 struct smp_cmd_pairing_random {
26 __u8 rand_val[16];
27 } __packed;
29 #define SMP_CMD_PAIRING_FAIL 0x05
30 struct smp_cmd_pairing_fail {
31 __u8 reason;
32 } __packed;
34 #define SMP_CMD_ENCRYPT_INFO 0x06
35 struct smp_cmd_encrypt_info {
36 __u8 ltk[16];
37 } __packed;
39 #define SMP_CMD_MASTER_IDENT 0x07
40 struct smp_cmd_master_ident {
41 __u16 ediv;
42 __u8 rand[8];
43 } __packed;
45 #define SMP_CMD_IDENT_INFO 0x08
46 struct smp_cmd_ident_info {
47 __u8 irk[16];
48 } __packed;
50 #define SMP_CMD_IDENT_ADDR_INFO 0x09
51 struct smp_cmd_ident_addr_info {
52 __u8 addr_type;
53 bdaddr_t bdaddr;
54 } __packed;
56 #define SMP_CMD_SIGN_INFO 0x0a
57 struct smp_cmd_sign_info {
58 __u8 csrk[16];
59 } __packed;
61 #define SMP_CMD_SECURITY_REQ 0x0b
62 struct smp_cmd_security_req {
63 __u8 auth_req;
64 } __packed;
66 #define SMP_PASSKEY_ENTRY_FAILED 0x01
67 #define SMP_OOB_NOT_AVAIL 0x02
68 #define SMP_AUTH_REQUIREMENTS 0x03
69 #define SMP_CONFIRM_FAILED 0x04
70 #define SMP_PAIRING_NOTSUPP 0x05
71 #define SMP_ENC_KEY_SIZE 0x06
72 #define SMP_CMD_NOTSUPP 0x07
73 #define SMP_UNSPECIFIED 0x08
74 #define SMP_REPEATED_ATTEMPTS 0x09
76 #endif /* __SMP_H */