aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/bluetooth/bluetooth.h
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2015-11-05 07:09:59 +0100
committerMarcel Holtmann <marcel@holtmann.org>2015-11-19 17:50:26 +0100
commitf5c4a42a7549cbc29dbac2b5ede05a3bc2bb4522 (patch)
treefbd1e8e6b18e304a73fb8cf2154556fed507525a /include/net/bluetooth/bluetooth.h
parentBluetooth: Make LE only events conditional on supported commands (diff)
downloadlinux-dev-f5c4a42a7549cbc29dbac2b5ede05a3bc2bb4522.tar.xz
linux-dev-f5c4a42a7549cbc29dbac2b5ede05a3bc2bb4522.zip
Bluetooth: Add hci_skb_* helper wrappers for bt_cb(skb) access
For all the HCI driver related variables accesssed via bt_cb(skb), provide helper wrappers. Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Diffstat (limited to 'include/net/bluetooth/bluetooth.h')
-rw-r--r--include/net/bluetooth/bluetooth.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/net/bluetooth/bluetooth.h b/include/net/bluetooth/bluetooth.h
index 42844d7b154a..663e0ef1eaa0 100644
--- a/include/net/bluetooth/bluetooth.h
+++ b/include/net/bluetooth/bluetooth.h
@@ -316,6 +316,10 @@ struct bt_skb_cb {
};
#define bt_cb(skb) ((struct bt_skb_cb *)((skb)->cb))
+#define hci_skb_pkt_type(skb) bt_cb((skb))->pkt_type
+#define hci_skb_expect(skb) bt_cb((skb))->expect
+#define hci_skb_opcode(skb) bt_cb((skb))->hci.opcode
+
static inline struct sk_buff *bt_skb_alloc(unsigned int len, gfp_t how)
{
struct sk_buff *skb;