]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/net/bluetooth/hci.h
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris...
[linux-2.6-omap-h63xx.git] / include / net / bluetooth / hci.h
index 10a3eec191fd2bf6110fbd0b4dadaa6fbdf2af8a..93ce272a5d27edbe37fef616217e3e37f3fcfb14 100644 (file)
@@ -709,6 +709,24 @@ struct hci_sco_hdr {
        __u8    dlen;
 } __attribute__ ((packed));
 
+#ifdef __KERNEL__
+#include <linux/skbuff.h>
+static inline struct hci_event_hdr *hci_event_hdr(const struct sk_buff *skb)
+{
+       return (struct hci_event_hdr *)skb->data;
+}
+
+static inline struct hci_acl_hdr *hci_acl_hdr(const struct sk_buff *skb)
+{
+       return (struct hci_acl_hdr *)skb->data;
+}
+
+static inline struct hci_sco_hdr *hci_sco_hdr(const struct sk_buff *skb)
+{
+       return (struct hci_sco_hdr *)skb->data;
+}
+#endif
+
 /* Command opcode pack/unpack */
 #define hci_opcode_pack(ogf, ocf)      (__u16) ((ocf & 0x03ff)|(ogf << 10))
 #define hci_opcode_ogf(op)             (op >> 10)
@@ -739,13 +757,13 @@ struct sockaddr_hci {
 struct hci_filter {
        unsigned long type_mask;
        unsigned long event_mask[2];
-       __u16   opcode;
+       __le16   opcode;
 };
 
 struct hci_ufilter {
        __u32   type_mask;
        __u32   event_mask[2];
-       __u16   opcode;
+       __le16   opcode;
 };
 
 #define HCI_FLT_TYPE_BITS      31