diff options
| author | 2014-02-26 15:29:03 +0100 | |
|---|---|---|
| committer | 2014-02-27 14:49:06 -0800 | |
| commit | 02981dac48765708322146d756fbd230164789b2 (patch) | |
| tree | cd6aef89bb6b0925b014a87d1587e5f7c1c29eeb | |
| parent | staging: rtl8187se: Added parenthesis in a macro in r8180.h (diff) | |
staging: rtl8187se: Convert ChnlAccessSetting typedef into a struct.
The Documentation/CodingStyle doesn't recommend the use of typedef, convert
this to structure.
While at it, I have also renamed the variable names that were used in
this typedef not to use Hungarian notation.
Signed-off-by: Ana Rey <anarey@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| -rw-r--r-- | drivers/staging/rtl8187se/r8180.h | 18 | ||||
| -rw-r--r-- | drivers/staging/rtl8187se/r8185b_init.c | 20 |
2 files changed, 19 insertions, 19 deletions
diff --git a/drivers/staging/rtl8187se/r8180.h b/drivers/staging/rtl8187se/r8180.h index d36470e8f272..2d9accf4ca66 100644 --- a/drivers/staging/rtl8187se/r8180.h +++ b/drivers/staging/rtl8187se/r8180.h @@ -76,14 +76,14 @@ typedef enum _WIRELESS_MODE { WIRELESS_MODE_AUTO = 0x08, } WIRELESS_MODE; -typedef struct ChnlAccessSetting { - u16 SIFS_Timer; - u16 DIFS_Timer; - u16 SlotTimeTimer; - u16 EIFS_Timer; - u16 CWminIndex; - u16 CWmaxIndex; -} *PCHANNEL_ACCESS_SETTING, CHANNEL_ACCESS_SETTING; +struct chnl_access_setting { + u16 sifs_timer; + u16 difs_timer; + u16 slot_time_timer; + u16 eifs_timer; + u16 cwmin_index; + u16 cwmax_index; +}; typedef enum { NIC_8185 = 1, @@ -643,7 +643,7 @@ typedef struct r8180_priv { u32 ReceiveConfig; u32 IntrMask; - struct ChnlAccessSetting ChannelAccessSetting; + struct chnl_access_setting ChannelAccessSetting; } r8180_priv; #define MANAGE_PRIORITY 0 diff --git a/drivers/staging/rtl8187se/r8185b_init.c b/drivers/staging/rtl8187se/r8185b_init.c index c8b9baff1dbc..48eda5564ba5 100644 --- a/drivers/staging/rtl8187se/r8185b_init.c +++ b/drivers/staging/rtl8187se/r8185b_init.c @@ -873,7 +873,7 @@ static u8 GetSupportedWirelessMode8185(struct net_device *dev) static void ActUpdateChannelAccessSetting(struct net_device *dev, WIRELESS_MODE WirelessMode, - PCHANNEL_ACCESS_SETTING ChnlAccessSetting) + struct chnl_access_setting *chnl_access_setting) { AC_CODING eACI; @@ -890,25 +890,25 @@ ActUpdateChannelAccessSetting(struct net_device *dev, */ /* Suggested by Jong, 2005.12.08. */ - ChnlAccessSetting->SIFS_Timer = 0x22; - ChnlAccessSetting->DIFS_Timer = 0x1C; /* 2006.06.02, by rcnjko. */ - ChnlAccessSetting->SlotTimeTimer = 9; /* 2006.06.02, by rcnjko. */ + chnl_access_setting->sifs_timer = 0x22; + chnl_access_setting->difs_timer = 0x1C; /* 2006.06.02, by rcnjko. */ + chnl_access_setting->slot_time_timer = 9; /* 2006.06.02, by rcnjko. */ /* * Suggested by wcchu, it is the default value of EIFS register, * 2005.12.08. */ - ChnlAccessSetting->EIFS_Timer = 0x5B; - ChnlAccessSetting->CWminIndex = 3; /* 2006.06.02, by rcnjko. */ - ChnlAccessSetting->CWmaxIndex = 7; /* 2006.06.02, by rcnjko. */ + chnl_access_setting->eifs_timer = 0x5B; + chnl_access_setting->cwmin_index = 3; /* 2006.06.02, by rcnjko. */ + chnl_access_setting->cwmax_index = 7; /* 2006.06.02, by rcnjko. */ - write_nic_byte(dev, SIFS, ChnlAccessSetting->SIFS_Timer); + write_nic_byte(dev, SIFS, chnl_access_setting->sifs_timer); /* * Rewrited from directly use PlatformEFIOWrite1Byte(), * by Annie, 2006-03-29. */ - write_nic_byte(dev, SLOT, ChnlAccessSetting->SlotTimeTimer); + write_nic_byte(dev, SLOT, chnl_access_setting->slot_time_timer); - write_nic_byte(dev, EIFS, ChnlAccessSetting->EIFS_Timer); + write_nic_byte(dev, EIFS, chnl_access_setting->eifs_timer); /* * <RJ_EXPR_QOS> Suggested by wcchu, it is the default value of EIFS |
