Commit c92f473d authored by Ana Rey's avatar Ana Rey Committed by Peter P Waskiewicz Jr

staging: rtl8192u: make in r819xU_phy.c some local functions static

Make some local functions static and fix coding style in these function
declarations when It is necessary

These are the local functions that were made static:
rtl8192_CalculateBitShift, rtl8192_phy_RFSerialRead,
rtl8192_phy_RFSerialWrite, rtl8192_InitBBRFRegDef,
rtl8192_BB_Config_ParaFile,rtl8192_SetTxPowerLevel,
rtl8192_phy_SetSwChnlCmdArray, rtl8192_phy_SwChnlStepByStep,
rtl8192_phy_FinishSwChnlNow

Fixed the following sparse warnings in r819xU_phy.c

drivers/staging/rtl8192u/r819xU_phy.c:47:5: warning: symbol 'rtl8192_CalculateBitShift' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:147:5: warning: symbol 'rtl8192_phy_RFSerialRead' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:232:6: warning: symbol 'rtl8192_phy_RFSerialWrite' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:574:6: warning: symbol 'rtl8192_InitBBRFRegDef' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:783:6: warning: symbol 'rtl8192_BB_Config_ParaFile' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:1073:6: warning: symbol 'rtl8192_SetTxPowerLevel' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:1242:4: warning: symbol 'rtl8192_phy_SetSwChnlCmdArray' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:1279:4: warning: symbol 'rtl8192_phy_SwChnlStepByStep' was not declared. Should it be static?
drivers/staging/rtl8192u/r819xU_phy.c:1436:6: warning: symbol 'rtl8192_phy_FinishSwChnlNow' was not declared. Should it be static?
Signed-off-by: default avatarAna Rey <anarey@gmail.com>
Signed-off-by: default avatarPeter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
parent 097b4d8c
...@@ -44,7 +44,7 @@ static u32 RF_CHANNEL_TABLE_ZEBRA[] = { ...@@ -44,7 +44,7 @@ static u32 RF_CHANNEL_TABLE_ZEBRA[] = {
* output: none * output: none
* return: u32 return the shift bit position of the mask * return: u32 return the shift bit position of the mask
******************************************************************************/ ******************************************************************************/
u32 rtl8192_CalculateBitShift(u32 bitmask) static u32 rtl8192_CalculateBitShift(u32 bitmask)
{ {
u32 i; u32 i;
...@@ -144,8 +144,8 @@ static void phy_FwRFSerialWrite(struct net_device *dev, ...@@ -144,8 +144,8 @@ static void phy_FwRFSerialWrite(struct net_device *dev,
* Driver here need to implement (1) and (2) * Driver here need to implement (1) and (2)
* ---need more spec for this information. * ---need more spec for this information.
******************************************************************************/ ******************************************************************************/
u32 rtl8192_phy_RFSerialRead(struct net_device *dev, RF90_RADIO_PATH_E eRFPath, static u32 rtl8192_phy_RFSerialRead(struct net_device *dev,
u32 offset) RF90_RADIO_PATH_E eRFPath, u32 offset)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
u32 ret = 0; u32 ret = 0;
...@@ -229,8 +229,9 @@ u32 rtl8192_phy_RFSerialRead(struct net_device *dev, RF90_RADIO_PATH_E eRFPath, ...@@ -229,8 +229,9 @@ u32 rtl8192_phy_RFSerialRead(struct net_device *dev, RF90_RADIO_PATH_E eRFPath,
* Reg_Mode2 1 1 Reg 31 ~ 45(0x1 ~ 0xf) * Reg_Mode2 1 1 Reg 31 ~ 45(0x1 ~ 0xf)
* --------------------------------------------------------------------------- * ---------------------------------------------------------------------------
*****************************************************************************/ *****************************************************************************/
void rtl8192_phy_RFSerialWrite(struct net_device *dev, static void rtl8192_phy_RFSerialWrite(struct net_device *dev,
RF90_RADIO_PATH_E eRFPath, u32 offset, u32 data) RF90_RADIO_PATH_E eRFPath, u32 offset,
u32 data)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
u32 DataAndAddr = 0, new_offset = 0; u32 DataAndAddr = 0, new_offset = 0;
...@@ -571,7 +572,7 @@ void rtl8192_phyConfigBB(struct net_device *dev, u8 ConfigType) ...@@ -571,7 +572,7 @@ void rtl8192_phyConfigBB(struct net_device *dev, u8 ConfigType)
* notice: Initialization value here is constant and it should never * notice: Initialization value here is constant and it should never
* be changed * be changed
*****************************************************************************/ *****************************************************************************/
void rtl8192_InitBBRFRegDef(struct net_device *dev) static void rtl8192_InitBBRFRegDef(struct net_device *dev)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
...@@ -780,7 +781,7 @@ u8 rtl8192_phy_checkBBAndRF(struct net_device *dev, HW90_BLOCK_E CheckBlock, ...@@ -780,7 +781,7 @@ u8 rtl8192_phy_checkBBAndRF(struct net_device *dev, HW90_BLOCK_E CheckBlock,
* notice: Initialization value may change all the time, so please make * notice: Initialization value may change all the time, so please make
* sure it has been synced with the newest. * sure it has been synced with the newest.
******************************************************************************/ ******************************************************************************/
void rtl8192_BB_Config_ParaFile(struct net_device *dev) static void rtl8192_BB_Config_ParaFile(struct net_device *dev)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
u8 reg_u8 = 0, eCheckItem = 0, status = 0; u8 reg_u8 = 0, eCheckItem = 0, status = 0;
...@@ -1070,7 +1071,7 @@ u8 rtl8192_phy_ConfigRFWithHeaderFile(struct net_device *dev, ...@@ -1070,7 +1071,7 @@ u8 rtl8192_phy_ConfigRFWithHeaderFile(struct net_device *dev,
* return: none * return: none
* notice: * notice:
******************************************************************************/ ******************************************************************************/
void rtl8192_SetTxPowerLevel(struct net_device *dev, u8 channel) static void rtl8192_SetTxPowerLevel(struct net_device *dev, u8 channel)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
u8 powerlevel = priv->TxPowerLevelCCK[channel-1]; u8 powerlevel = priv->TxPowerLevelCCK[channel-1];
...@@ -1239,9 +1240,9 @@ bool rtl8192_SetRFPowerState(struct net_device *dev, ...@@ -1239,9 +1240,9 @@ bool rtl8192_SetRFPowerState(struct net_device *dev,
* return: true if finished, false otherwise * return: true if finished, false otherwise
* notice: * notice:
******************************************************************************/ ******************************************************************************/
u8 rtl8192_phy_SetSwChnlCmdArray(SwChnlCmd *CmdTable, u32 CmdTableIdx, static u8 rtl8192_phy_SetSwChnlCmdArray(SwChnlCmd *CmdTable, u32 CmdTableIdx,
u32 CmdTableSz, SwChnlCmdID CmdID, u32 Para1, u32 CmdTableSz, SwChnlCmdID CmdID,
u32 Para2, u32 msDelay) u32 Para1, u32 Para2, u32 msDelay)
{ {
SwChnlCmd *pCmd; SwChnlCmd *pCmd;
...@@ -1276,8 +1277,8 @@ u8 rtl8192_phy_SetSwChnlCmdArray(SwChnlCmd *CmdTable, u32 CmdTableIdx, ...@@ -1276,8 +1277,8 @@ u8 rtl8192_phy_SetSwChnlCmdArray(SwChnlCmd *CmdTable, u32 CmdTableIdx,
* return: true if finished, false otherwise * return: true if finished, false otherwise
* notice: Wait for simpler function to replace it * notice: Wait for simpler function to replace it
*****************************************************************************/ *****************************************************************************/
u8 rtl8192_phy_SwChnlStepByStep(struct net_device *dev, u8 channel, u8 *stage, static u8 rtl8192_phy_SwChnlStepByStep(struct net_device *dev, u8 channel,
u8 *step, u32 *delay) u8 *stage, u8 *step, u32 *delay)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
SwChnlCmd PreCommonCmd[MAX_PRECMD_CNT]; SwChnlCmd PreCommonCmd[MAX_PRECMD_CNT];
...@@ -1433,7 +1434,7 @@ u8 rtl8192_phy_SwChnlStepByStep(struct net_device *dev, u8 channel, u8 *stage, ...@@ -1433,7 +1434,7 @@ u8 rtl8192_phy_SwChnlStepByStep(struct net_device *dev, u8 channel, u8 *stage,
* return: none * return: none
* notice: We should not call this function directly * notice: We should not call this function directly
*****************************************************************************/ *****************************************************************************/
void rtl8192_phy_FinishSwChnlNow(struct net_device *dev, u8 channel) static void rtl8192_phy_FinishSwChnlNow(struct net_device *dev, u8 channel)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
u32 delay = 0; u32 delay = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment