NFC: Use LIST_HEAD() at appropriate places
authorAxel Lin <axel.lin@ingics.com>
Sat, 22 Feb 2014 14:14:18 +0000 (22:14 +0800)
committerSamuel Ortiz <sameo@linux.intel.com>
Sun, 23 Feb 2014 22:34:09 +0000 (23:34 +0100)
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
net/nfc/hci/llc.c
net/nfc/llcp_core.c

index a07d2b8..1b90c05 100644 (file)
 
 #include "llc.h"
 
-static struct list_head llc_engines;
+static LIST_HEAD(llc_engines);
 
 int nfc_llc_init(void)
 {
        int r;
 
-       INIT_LIST_HEAD(&llc_engines);
-
        r = nfc_llc_nop_register();
        if (r)
                goto exit;
index 6184bd1..9d37ded 100644 (file)
@@ -27,7 +27,7 @@
 
 static u8 llcp_magic[3] = {0x46, 0x66, 0x6d};
 
-static struct list_head llcp_devices;
+static LIST_HEAD(llcp_devices);
 
 static void nfc_llcp_rx_skb(struct nfc_llcp_local *local, struct sk_buff *skb);
 
@@ -1622,8 +1622,6 @@ void nfc_llcp_unregister_device(struct nfc_dev *dev)
 
 int __init nfc_llcp_init(void)
 {
-       INIT_LIST_HEAD(&llcp_devices);
-
        return nfc_llcp_sock_init();
 }