staging: wilc1000: move multiple definition of same macro to common header
authorAjay Singh <ajay.kathat@microchip.com>
Mon, 26 Feb 2018 16:31:58 +0000 (22:01 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 1 Mar 2018 16:22:28 +0000 (17:22 +0100)
Move the same #define from multiple '.c' files to common header file.
Instead of having same macro in different '.c' files, now kept in
common '.h' file.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wilc1000/linux_mon.c
drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
drivers/staging/wilc1000/wilc_wlan.c
drivers/staging/wilc1000/wilc_wlan.h

index 91d49c4738dc61a796115391ed055d3b311e78ef..bbdfc7aab6779b9f5f15f4b1ed9e62a197a333bc 100644 (file)
@@ -40,9 +40,6 @@ static u8 broadcast[] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff};
 
 #define IEEE80211_RADIOTAP_F_TX_RTS    0x0004  /* used rts/cts handshake */
 #define IEEE80211_RADIOTAP_F_TX_FAIL   0x0001  /* failed due to excessive*/
-#define IS_MANAGMEMENT                         0x100
-#define IS_MANAGMEMENT_CALLBACK                        0x080
-#define IS_MGMT_STATUS_SUCCES                  0x040
 #define GET_PKT_OFFSET(a) (((a) >> 22) & 0x1ff)
 
 void WILC_WFI_monitor_rx(u8 *buff, u32 size)
index 557ab99e62269e0db0eea0831a979a193028b653..205304cc0b968c13ae43642c4bf05ed4b75f5e07 100644 (file)
@@ -85,9 +85,6 @@ static const struct wiphy_wowlan_support wowlan_support = {
 #define TCP_ACK_FILTER_LINK_SPEED_THRESH       54
 #define DEFAULT_LINK_SPEED                     72
 
-#define IS_MANAGMEMENT                         0x100
-#define IS_MANAGMEMENT_CALLBACK                        0x080
-#define IS_MGMT_STATUS_SUCCES                  0x040
 #define GET_PKT_OFFSET(a) (((a) >> 22) & 0x1ff)
 
 static struct network_info last_scanned_shadow[MAX_NUM_SCANNED_NETWORKS_SHADOW];
index ee7102d20f722d2ad85934261c32f17f3fbf3362..f7627856b8894d4d71a9f87f364c62d3b69ca523 100644 (file)
@@ -810,10 +810,6 @@ static void wilc_wlan_handle_rxq(struct wilc *wilc)
                        if (pkt_len == 0 || tp_len == 0)
                                break;
 
-                       #define IS_MANAGMEMENT                          0x100
-                       #define IS_MANAGMEMENT_CALLBACK                 0x080
-                       #define IS_MGMT_STATUS_SUCCES                   0x040
-
                        if (pkt_offset & IS_MANAGMEMENT) {
                                pkt_offset &= ~(IS_MANAGMEMENT |
                                                IS_MANAGMEMENT_CALLBACK |
index da717310549725b46d4dcd8d0da07496a6656d09..fa157a67b045d6702c2426185ce26850bdb7cd84 100644 (file)
 #define ENABLE_TX_VMM          (SEL_VMM_TBL0 | EN_VMM)
 /*time for expiring the completion of cfg packets*/
 #define CFG_PKTS_TIMEOUT       2000
+
+#define IS_MANAGMEMENT         0x100
+#define IS_MANAGMEMENT_CALLBACK        0x080
+#define IS_MGMT_STATUS_SUCCES  0x040
+
 /********************************************
  *
  *      Debug Type