diff options
author | Johan Hedberg <johan.hedberg@intel.com> | 2012-09-06 11:39:26 -0400 |
---|---|---|
committer | Gustavo Padovan <gustavo.padovan@collabora.co.uk> | 2012-09-18 21:27:29 -0400 |
commit | 92a25256f142d55e25f9959441cea6ddeabae57e (patch) | |
tree | eb276a7076d59e7d29f14139b3993d441c3ea0fd /include/net/bluetooth/hci.h | |
parent | 5ad777958621524b48d1bdf4aaf3b26a363d4553 (diff) |
Bluetooth: mgmt: Implement support for passkey notification
This patch adds support for Secure Simple Pairing with devices that have
KeyboardOnly as their IO capability. Such devices will cause a passkey
notification on our side and optionally also keypress notifications.
Without this patch some keyboards cannot be paired using the mgmt
interface.
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Cc: stable@vger.kernel.org
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Diffstat (limited to 'include/net/bluetooth/hci.h')
-rw-r--r-- | include/net/bluetooth/hci.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/include/net/bluetooth/hci.h b/include/net/bluetooth/hci.h index 0f28f7052f82..76b2b6bdcf36 100644 --- a/include/net/bluetooth/hci.h +++ b/include/net/bluetooth/hci.h | |||
@@ -1249,6 +1249,24 @@ struct hci_ev_simple_pair_complete { | |||
1249 | bdaddr_t bdaddr; | 1249 | bdaddr_t bdaddr; |
1250 | } __packed; | 1250 | } __packed; |
1251 | 1251 | ||
1252 | #define HCI_EV_USER_PASSKEY_NOTIFY 0x3b | ||
1253 | struct hci_ev_user_passkey_notify { | ||
1254 | bdaddr_t bdaddr; | ||
1255 | __le32 passkey; | ||
1256 | } __packed; | ||
1257 | |||
1258 | #define HCI_KEYPRESS_STARTED 0 | ||
1259 | #define HCI_KEYPRESS_ENTERED 1 | ||
1260 | #define HCI_KEYPRESS_ERASED 2 | ||
1261 | #define HCI_KEYPRESS_CLEARED 3 | ||
1262 | #define HCI_KEYPRESS_COMPLETED 4 | ||
1263 | |||
1264 | #define HCI_EV_KEYPRESS_NOTIFY 0x3c | ||
1265 | struct hci_ev_keypress_notify { | ||
1266 | bdaddr_t bdaddr; | ||
1267 | __u8 type; | ||
1268 | } __packed; | ||
1269 | |||
1252 | #define HCI_EV_REMOTE_HOST_FEATURES 0x3d | 1270 | #define HCI_EV_REMOTE_HOST_FEATURES 0x3d |
1253 | struct hci_ev_remote_host_features { | 1271 | struct hci_ev_remote_host_features { |
1254 | bdaddr_t bdaddr; | 1272 | bdaddr_t bdaddr; |