aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLarry Finger <Larry.Finger@lwfinger.net>2012-01-27 14:59:25 -0500
committerJohn W. Linville <linville@tuxdriver.com>2012-01-30 15:48:23 -0500
commitd273bb20c00340748e3ca9730f87524ec5abbd64 (patch)
treeab67a4c86f76434b318c3177e4f974c188b497d8
parent608383bfc04aa222c3e9e896c32f56a5e5deaff0 (diff)
rtlwifi: Move pr_fmt macros to a single location
Although the rtlwifi family of devices contains 11 copies of the pr_fmt macro, the macro is not defined for all routines that need it. By moving the macro to wifi.h, a single copy is available for all routines. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/rtlwifi/base.c7
-rw-r--r--drivers/net/wireless/rtlwifi/cam.c2
-rw-r--r--drivers/net/wireless/rtlwifi/core.h2
-rw-r--r--drivers/net/wireless/rtlwifi/debug.c2
-rw-r--r--drivers/net/wireless/rtlwifi/pci.c4
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192c/fw_common.c5
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192c/main.c2
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192ce/sw.c5
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192cu/hw.c2
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192cu/mac.c6
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192cu/sw.c1
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192de/sw.c7
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192se/hw.c2
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192se/phy.c2
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192se/rf.c2
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8192se/sw.c7
-rw-r--r--drivers/net/wireless/rtlwifi/usb.c7
-rw-r--r--drivers/net/wireless/rtlwifi/usb.h1
-rw-r--r--drivers/net/wireless/rtlwifi/wifi.h2
19 files changed, 21 insertions, 47 deletions
diff --git a/drivers/net/wireless/rtlwifi/base.c b/drivers/net/wireless/rtlwifi/base.c
index ff3e393bc104..7a95a544a9b1 100644
--- a/drivers/net/wireless/rtlwifi/base.c
+++ b/drivers/net/wireless/rtlwifi/base.c
@@ -27,10 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include <linux/ip.h>
33#include <linux/module.h>
34#include "wifi.h" 30#include "wifi.h"
35#include "rc.h" 31#include "rc.h"
36#include "base.h" 32#include "base.h"
@@ -39,6 +35,9 @@
39#include "ps.h" 35#include "ps.h"
40#include "regd.h" 36#include "regd.h"
41 37
38#include <linux/ip.h>
39#include <linux/module.h>
40
42/* 41/*
43 *NOTICE!!!: This file will be very big, we hsould 42 *NOTICE!!!: This file will be very big, we hsould
44 *keep it clear under follwing roles: 43 *keep it clear under follwing roles:
diff --git a/drivers/net/wireless/rtlwifi/cam.c b/drivers/net/wireless/rtlwifi/cam.c
index 8fd820d85eea..5c7d57947d23 100644
--- a/drivers/net/wireless/rtlwifi/cam.c
+++ b/drivers/net/wireless/rtlwifi/cam.c
@@ -27,8 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include <linux/export.h> 30#include <linux/export.h>
33#include "wifi.h" 31#include "wifi.h"
34#include "cam.h" 32#include "cam.h"
diff --git a/drivers/net/wireless/rtlwifi/core.h b/drivers/net/wireless/rtlwifi/core.h
index a45c3892e363..57569e0e3d47 100644
--- a/drivers/net/wireless/rtlwifi/core.h
+++ b/drivers/net/wireless/rtlwifi/core.h
@@ -30,8 +30,6 @@
30#ifndef __RTL_CORE_H__ 30#ifndef __RTL_CORE_H__
31#define __RTL_CORE_H__ 31#define __RTL_CORE_H__
32 32
33#include <net/mac80211.h>
34
35#define RTL_SUPPORTED_FILTERS \ 33#define RTL_SUPPORTED_FILTERS \
36 (FIF_PROMISC_IN_BSS | \ 34 (FIF_PROMISC_IN_BSS | \
37 FIF_ALLMULTI | FIF_CONTROL | \ 35 FIF_ALLMULTI | FIF_CONTROL | \
diff --git a/drivers/net/wireless/rtlwifi/debug.c b/drivers/net/wireless/rtlwifi/debug.c
index 67dcbcdfaa7b..bdda9b2fffe1 100644
--- a/drivers/net/wireless/rtlwifi/debug.c
+++ b/drivers/net/wireless/rtlwifi/debug.c
@@ -28,6 +28,8 @@
28 28
29#include "wifi.h" 29#include "wifi.h"
30 30
31#include <linux/moduleparam.h>
32
31void rtl_dbgp_flag_init(struct ieee80211_hw *hw) 33void rtl_dbgp_flag_init(struct ieee80211_hw *hw)
32{ 34{
33 struct rtl_priv *rtlpriv = rtl_priv(hw); 35 struct rtl_priv *rtlpriv = rtl_priv(hw);
diff --git a/drivers/net/wireless/rtlwifi/pci.c b/drivers/net/wireless/rtlwifi/pci.c
index 4326fd1e3190..e4d1dcfe8299 100644
--- a/drivers/net/wireless/rtlwifi/pci.c
+++ b/drivers/net/wireless/rtlwifi/pci.c
@@ -27,13 +27,13 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#include <linux/export.h>
31#include "core.h"
32#include "wifi.h" 30#include "wifi.h"
31#include "core.h"
33#include "pci.h" 32#include "pci.h"
34#include "base.h" 33#include "base.h"
35#include "ps.h" 34#include "ps.h"
36#include "efuse.h" 35#include "efuse.h"
36#include <linux/export.h>
37 37
38static const u16 pcibridge_vendors[PCI_BRIDGE_VENDOR_MAX] = { 38static const u16 pcibridge_vendors[PCI_BRIDGE_VENDOR_MAX] = {
39 PCI_VENDOR_ID_INTEL, 39 PCI_VENDOR_ID_INTEL,
diff --git a/drivers/net/wireless/rtlwifi/rtl8192c/fw_common.c b/drivers/net/wireless/rtlwifi/rtl8192c/fw_common.c
index 75be221fde4c..82bbc8384aca 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192c/fw_common.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192c/fw_common.c
@@ -27,16 +27,13 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include <linux/firmware.h>
33#include <linux/export.h>
34#include "../wifi.h" 30#include "../wifi.h"
35#include "../pci.h" 31#include "../pci.h"
36#include "../base.h" 32#include "../base.h"
37#include "../rtl8192ce/reg.h" 33#include "../rtl8192ce/reg.h"
38#include "../rtl8192ce/def.h" 34#include "../rtl8192ce/def.h"
39#include "fw_common.h" 35#include "fw_common.h"
36#include <linux/export.h>
40 37
41static void _rtl92c_enable_fw_download(struct ieee80211_hw *hw, bool enable) 38static void _rtl92c_enable_fw_download(struct ieee80211_hw *hw, bool enable)
42{ 39{
diff --git a/drivers/net/wireless/rtlwifi/rtl8192c/main.c b/drivers/net/wireless/rtlwifi/rtl8192c/main.c
index 8ae65b576126..918b1d129e77 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192c/main.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192c/main.c
@@ -27,8 +27,8 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#include <linux/module.h>
31#include "../wifi.h" 30#include "../wifi.h"
31#include <linux/module.h>
32 32
33 33
34MODULE_AUTHOR("lizhaoming <chaoming_li@realsil.com.cn>"); 34MODULE_AUTHOR("lizhaoming <chaoming_li@realsil.com.cn>");
diff --git a/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c b/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c
index 7e59b689bfff..460dc925b4e4 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c
@@ -27,9 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#include <linux/vmalloc.h>
31#include <linux/module.h>
32
33#include "../wifi.h" 30#include "../wifi.h"
34#include "../core.h" 31#include "../core.h"
35#include "../pci.h" 32#include "../pci.h"
@@ -43,6 +40,8 @@
43#include "trx.h" 40#include "trx.h"
44#include "led.h" 41#include "led.h"
45 42
43#include <linux/module.h>
44
46static void rtl92c_init_aspm_vars(struct ieee80211_hw *hw) 45static void rtl92c_init_aspm_vars(struct ieee80211_hw *hw)
47{ 46{
48 struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw)); 47 struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
diff --git a/drivers/net/wireless/rtlwifi/rtl8192cu/hw.c b/drivers/net/wireless/rtlwifi/rtl8192cu/hw.c
index edb52987f5ea..7f171682d3d6 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192cu/hw.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192cu/hw.c
@@ -27,8 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include "../wifi.h" 30#include "../wifi.h"
33#include "../efuse.h" 31#include "../efuse.h"
34#include "../base.h" 32#include "../base.h"
diff --git a/drivers/net/wireless/rtlwifi/rtl8192cu/mac.c b/drivers/net/wireless/rtlwifi/rtl8192cu/mac.c
index d028f6f21990..025bdc2eba44 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192cu/mac.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192cu/mac.c
@@ -27,10 +27,6 @@
27 * 27 *
28****************************************************************************/ 28****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include <linux/module.h>
33
34#include "../wifi.h" 30#include "../wifi.h"
35#include "../pci.h" 31#include "../pci.h"
36#include "../usb.h" 32#include "../usb.h"
@@ -44,6 +40,8 @@
44#include "mac.h" 40#include "mac.h"
45#include "trx.h" 41#include "trx.h"
46 42
43#include <linux/module.h>
44
47/* macro to shorten lines */ 45/* macro to shorten lines */
48 46
49#define LINK_Q ui_link_quality 47#define LINK_Q ui_link_quality
diff --git a/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c b/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c
index aec8cae733a1..c04c3be5bd4e 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c
@@ -41,7 +41,6 @@
41#include "trx.h" 41#include "trx.h"
42#include "led.h" 42#include "led.h"
43#include "hw.h" 43#include "hw.h"
44#include <linux/vmalloc.h>
45#include <linux/module.h> 44#include <linux/module.h>
46 45
47MODULE_AUTHOR("Georgia <georgia@realtek.com>"); 46MODULE_AUTHOR("Georgia <georgia@realtek.com>");
diff --git a/drivers/net/wireless/rtlwifi/rtl8192de/sw.c b/drivers/net/wireless/rtlwifi/rtl8192de/sw.c
index b8d7fe39e5a8..bf625f9e632e 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192de/sw.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192de/sw.c
@@ -27,11 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include <linux/vmalloc.h>
33#include <linux/module.h>
34
35#include "../wifi.h" 30#include "../wifi.h"
36#include "../core.h" 31#include "../core.h"
37#include "../pci.h" 32#include "../pci.h"
@@ -44,6 +39,8 @@
44#include "trx.h" 39#include "trx.h"
45#include "led.h" 40#include "led.h"
46 41
42#include <linux/module.h>
43
47static void rtl92d_init_aspm_vars(struct ieee80211_hw *hw) 44static void rtl92d_init_aspm_vars(struct ieee80211_hw *hw)
48{ 45{
49 struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw)); 46 struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
diff --git a/drivers/net/wireless/rtlwifi/rtl8192se/hw.c b/drivers/net/wireless/rtlwifi/rtl8192se/hw.c
index 625c9eb0a118..cbaf1f345c6e 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192se/hw.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192se/hw.c
@@ -27,8 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include "../wifi.h" 30#include "../wifi.h"
33#include "../efuse.h" 31#include "../efuse.h"
34#include "../base.h" 32#include "../base.h"
diff --git a/drivers/net/wireless/rtlwifi/rtl8192se/phy.c b/drivers/net/wireless/rtlwifi/rtl8192se/phy.c
index adfac569b67c..05b4e2790e99 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192se/phy.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192se/phy.c
@@ -27,8 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include "../wifi.h" 30#include "../wifi.h"
33#include "../pci.h" 31#include "../pci.h"
34#include "../ps.h" 32#include "../ps.h"
diff --git a/drivers/net/wireless/rtlwifi/rtl8192se/rf.c b/drivers/net/wireless/rtlwifi/rtl8192se/rf.c
index 46be4cc8ba96..ad51906124db 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192se/rf.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192se/rf.c
@@ -27,8 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include "../wifi.h" 30#include "../wifi.h"
33#include "reg.h" 31#include "reg.h"
34#include "def.h" 32#include "def.h"
diff --git a/drivers/net/wireless/rtlwifi/rtl8192se/sw.c b/drivers/net/wireless/rtlwifi/rtl8192se/sw.c
index 3bc0128deeaa..0c47310b39b9 100644
--- a/drivers/net/wireless/rtlwifi/rtl8192se/sw.c
+++ b/drivers/net/wireless/rtlwifi/rtl8192se/sw.c
@@ -27,11 +27,6 @@
27 * 27 *
28 *****************************************************************************/ 28 *****************************************************************************/
29 29
30#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
31
32#include <linux/vmalloc.h>
33#include <linux/module.h>
34
35#include "../wifi.h" 30#include "../wifi.h"
36#include "../core.h" 31#include "../core.h"
37#include "../pci.h" 32#include "../pci.h"
@@ -45,6 +40,8 @@
45#include "trx.h" 40#include "trx.h"
46#include "led.h" 41#include "led.h"
47 42
43#include <linux/module.h>
44
48static void rtl92s_init_aspm_vars(struct ieee80211_hw *hw) 45static void rtl92s_init_aspm_vars(struct ieee80211_hw *hw)
49{ 46{
50 struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw)); 47 struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
diff --git a/drivers/net/wireless/rtlwifi/usb.c b/drivers/net/wireless/rtlwifi/usb.c
index 78194e30fcd5..e7a7ea96f42b 100644
--- a/drivers/net/wireless/rtlwifi/usb.c
+++ b/drivers/net/wireless/rtlwifi/usb.c
@@ -25,16 +25,13 @@
25 * 25 *
26 *****************************************************************************/ 26 *****************************************************************************/
27 27
28#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
29
30#include <linux/usb.h>
31#include <linux/export.h>
32#include "core.h"
33#include "wifi.h" 28#include "wifi.h"
29#include "core.h"
34#include "usb.h" 30#include "usb.h"
35#include "base.h" 31#include "base.h"
36#include "ps.h" 32#include "ps.h"
37#include "rtl8192c/fw_common.h" 33#include "rtl8192c/fw_common.h"
34#include <linux/export.h>
38 35
39#define REALTEK_USB_VENQT_READ 0xC0 36#define REALTEK_USB_VENQT_READ 0xC0
40#define REALTEK_USB_VENQT_WRITE 0x40 37#define REALTEK_USB_VENQT_WRITE 0x40
diff --git a/drivers/net/wireless/rtlwifi/usb.h b/drivers/net/wireless/rtlwifi/usb.h
index cdad7c2507e4..43846b329153 100644
--- a/drivers/net/wireless/rtlwifi/usb.h
+++ b/drivers/net/wireless/rtlwifi/usb.h
@@ -28,7 +28,6 @@
28#ifndef __RTL_USB_H__ 28#ifndef __RTL_USB_H__
29#define __RTL_USB_H__ 29#define __RTL_USB_H__
30 30
31#include <linux/usb.h>
32#include <linux/skbuff.h> 31#include <linux/skbuff.h>
33 32
34#define RTL_RX_DESC_SIZE 24 33#define RTL_RX_DESC_SIZE 24
diff --git a/drivers/net/wireless/rtlwifi/wifi.h b/drivers/net/wireless/rtlwifi/wifi.h
index b2d98548500b..1e5fffb2db0b 100644
--- a/drivers/net/wireless/rtlwifi/wifi.h
+++ b/drivers/net/wireless/rtlwifi/wifi.h
@@ -30,6 +30,8 @@
30#ifndef __RTL_WIFI_H__ 30#ifndef __RTL_WIFI_H__
31#define __RTL_WIFI_H__ 31#define __RTL_WIFI_H__
32 32
33#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
34
33#include <linux/sched.h> 35#include <linux/sched.h>
34#include <linux/firmware.h> 36#include <linux/firmware.h>
35#include <linux/etherdevice.h> 37#include <linux/etherdevice.h>