]> err.no Git - linux-2.6/blobdiff - net/bluetooth/rfcomm/core.c
[BLUETOOTH]: rfcomm endianness annotations
[linux-2.6] / net / bluetooth / rfcomm / core.c
index 468df3b953f6d3c615169a0939e50ec924eb1af8..f3e5b7e2e04cdad143160ac8947c67ca98ecf0be 100644 (file)
@@ -1018,7 +1018,7 @@ static void rfcomm_make_uih(struct sk_buff *skb, u8 addr)
 
        if (len > 127) {
                hdr = (void *) skb_push(skb, 4);
-               put_unaligned(htobs(__len16(len)), (u16 *) &hdr->len);
+               put_unaligned(htobs(__len16(len)), (__le16 *) &hdr->len);
        } else {
                hdr = (void *) skb_push(skb, 3);
                hdr->len = __len8(len);
@@ -2058,7 +2058,8 @@ static int __init rfcomm_init(void)
 
        kernel_thread(rfcomm_run, NULL, CLONE_KERNEL);
 
-       class_create_file(bt_class, &class_attr_rfcomm_dlc);
+       if (class_create_file(bt_class, &class_attr_rfcomm_dlc) < 0)
+               BT_ERR("Failed to create RFCOMM info file");
 
        rfcomm_init_sockets();