Commit c0b99bed authored by Larry Finger's avatar Larry Finger Committed by Greg Kroah-Hartman

staging: r8723au: Set undeclared routines to static

The following sparse warnings are fixed:

drivers/staging/rtl8723au/core/rtw_cmd.c:1211:6: warning: symbol 'dynamic_chk_wk_hdl' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_cmd.c:1238:6: warning: symbol 'lps_ctrl_wk_hdl' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_cmd.c:1812:6: warning: symbol 'rtw_getrttbl_cmd_cmdrsp_callback' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_mlme.c:364:6: warning: symbol 'rtw_free_network' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_mlme.c:373:6: warning: symbol 'rtw_free_network_nolock' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_mlme.c:631:6: warning: symbol 'rtw_add_network' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_mlme.c:644:5: warning: symbol 'rtw_is_desired_network' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_mlme_ext.c:2246:5: warning: symbol 'DoReserved23a' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_mlme_ext.c:5549:6: warning: symbol 'linked23a_rx_sig_stren_disp' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_pwrctrl.c:272:4: warning: symbol 'PS_RDY_CHECK' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_recv.c:1937:5: warning: symbol 'enqueue_reorder_recvframe23a' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_sta_mgt.c:24:6: warning: symbol '_rtw_init_stainfo' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_sta_mgt.c:112:6: warning: symbol 'rtw_mfree_all_stainfo' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_sta_mgt.c:127:6: warning: symbol 'rtw_mfree_sta_priv_lock' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_wlan_util.c:143:15: warning: symbol 'ratetbl_val_2wifirate' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_wlan_util.c:188:5: warning: symbol 'is_basicrate' was not declared. Should it be static?
drivers/staging/rtl8723au/core/rtw_wlan_util.c:206:14: warning: symbol 'ratetbl2rateset' was not declared. Should it be static?

Three of the above routines were not used and were deleted.
Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 69d9ff1a
...@@ -1083,7 +1083,7 @@ static void traffic_status_watchdog(struct rtw_adapter *padapter) ...@@ -1083,7 +1083,7 @@ static void traffic_status_watchdog(struct rtw_adapter *padapter)
pmlmepriv->LinkDetectInfo.bHigherBusyTxTraffic = bHigherBusyTxTraffic; pmlmepriv->LinkDetectInfo.bHigherBusyTxTraffic = bHigherBusyTxTraffic;
} }
void dynamic_chk_wk_hdl(struct rtw_adapter *padapter, u8 *pbuf, int sz) static void dynamic_chk_wk_hdl(struct rtw_adapter *padapter, u8 *pbuf, int sz)
{ {
struct mlme_priv *pmlmepriv; struct mlme_priv *pmlmepriv;
...@@ -1110,7 +1110,7 @@ void dynamic_chk_wk_hdl(struct rtw_adapter *padapter, u8 *pbuf, int sz) ...@@ -1110,7 +1110,7 @@ void dynamic_chk_wk_hdl(struct rtw_adapter *padapter, u8 *pbuf, int sz)
#endif #endif
} }
void lps_ctrl_wk_hdl(struct rtw_adapter *padapter, u8 lps_ctrl_type) static void lps_ctrl_wk_hdl(struct rtw_adapter *padapter, u8 lps_ctrl_type)
{ {
struct pwrctrl_priv *pwrpriv = &padapter->pwrctrlpriv; struct pwrctrl_priv *pwrpriv = &padapter->pwrctrlpriv;
struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
...@@ -1689,9 +1689,3 @@ void rtw_setassocsta_cmdrsp_callback23a(struct rtw_adapter *padapter, ...@@ -1689,9 +1689,3 @@ void rtw_setassocsta_cmdrsp_callback23a(struct rtw_adapter *padapter,
exit: exit:
rtw_free_cmd_obj23a(pcmd); rtw_free_cmd_obj23a(pcmd);
} }
void rtw_getrttbl_cmd_cmdrsp_callback(struct rtw_adapter *padapter,
struct cmd_obj *pcmd)
{
rtw_free_cmd_obj23a(pcmd);
}
...@@ -361,16 +361,7 @@ int rtw_init_mlme_priv23a (struct rtw_adapter *padapter) ...@@ -361,16 +361,7 @@ int rtw_init_mlme_priv23a (struct rtw_adapter *padapter)
return res; return res;
} }
void rtw_free_network(struct mlme_priv *pmlmepriv, static void rtw_free_network_nolock(struct mlme_priv *pmlmepriv,
struct wlan_network *pnetwork, u8 is_freeall)
{
RT_TRACE(_module_rtl871x_mlme_c_, _drv_err_,
("rtw_free_network ==> ssid = %s\n\n" ,
pnetwork->network.Ssid.ssid));
_rtw_free_network23a(pmlmepriv, pnetwork, is_freeall);
}
void rtw_free_network_nolock(struct mlme_priv *pmlmepriv,
struct wlan_network *pnetwork) struct wlan_network *pnetwork)
{ {
_rtw_free_network23a_nolock23a(pmlmepriv, pnetwork); _rtw_free_network23a_nolock23a(pmlmepriv, pnetwork);
...@@ -628,7 +619,7 @@ void rtw_update_scanned_network23a(struct rtw_adapter *adapter, ...@@ -628,7 +619,7 @@ void rtw_update_scanned_network23a(struct rtw_adapter *adapter,
spin_unlock_bh(&queue->lock); spin_unlock_bh(&queue->lock);
} }
void rtw_add_network(struct rtw_adapter *adapter, static void rtw_add_network(struct rtw_adapter *adapter,
struct wlan_bssid_ex *pnetwork) struct wlan_bssid_ex *pnetwork)
{ {
update_current_network(adapter, pnetwork); update_current_network(adapter, pnetwork);
...@@ -641,7 +632,7 @@ void rtw_add_network(struct rtw_adapter *adapter, ...@@ -641,7 +632,7 @@ void rtw_add_network(struct rtw_adapter *adapter,
/* (3) WMM */ /* (3) WMM */
/* (4) HT */ /* (4) HT */
/* (5) others */ /* (5) others */
int rtw_is_desired_network(struct rtw_adapter *adapter, static int rtw_is_desired_network(struct rtw_adapter *adapter,
struct wlan_network *pnetwork) struct wlan_network *pnetwork)
{ {
struct security_priv *psecuritypriv = &adapter->securitypriv; struct security_priv *psecuritypriv = &adapter->securitypriv;
......
...@@ -2243,7 +2243,8 @@ OnAction23a(struct rtw_adapter *padapter, struct recv_frame *precv_frame) ...@@ -2243,7 +2243,8 @@ OnAction23a(struct rtw_adapter *padapter, struct recv_frame *precv_frame)
return _SUCCESS; return _SUCCESS;
} }
int DoReserved23a(struct rtw_adapter *padapter, struct recv_frame *precv_frame) static int DoReserved23a(struct rtw_adapter *padapter,
struct recv_frame *precv_frame)
{ {
return _SUCCESS; return _SUCCESS;
} }
...@@ -5537,7 +5538,7 @@ void mlmeext_sta_del_event_callback23a(struct rtw_adapter *padapter) ...@@ -5537,7 +5538,7 @@ void mlmeext_sta_del_event_callback23a(struct rtw_adapter *padapter)
Following are the functions for the timer handlers Following are the functions for the timer handlers
*****************************************************************************/ *****************************************************************************/
void linked23a_rx_sig_stren_disp(struct rtw_adapter *padapter) static void linked23a_rx_sig_stren_disp(struct rtw_adapter *padapter)
{ {
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv; struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
struct mlme_ext_info *pmlmeinfo = &pmlmeext->mlmext_info; struct mlme_ext_info *pmlmeinfo = &pmlmeext->mlmext_info;
......
...@@ -269,7 +269,7 @@ void rtw_set_rpwm23a(struct rtw_adapter *padapter, u8 pslv) ...@@ -269,7 +269,7 @@ void rtw_set_rpwm23a(struct rtw_adapter *padapter, u8 pslv)
} }
u8 PS_RDY_CHECK(struct rtw_adapter * padapter) static u8 PS_RDY_CHECK(struct rtw_adapter * padapter)
{ {
unsigned long delta_time; unsigned long delta_time;
struct pwrctrl_priv *pwrpriv = &padapter->pwrctrlpriv; struct pwrctrl_priv *pwrpriv = &padapter->pwrctrlpriv;
......
...@@ -1934,7 +1934,7 @@ int check_indicate_seq(struct recv_reorder_ctrl *preorder_ctrl, u16 seq_num) ...@@ -1934,7 +1934,7 @@ int check_indicate_seq(struct recv_reorder_ctrl *preorder_ctrl, u16 seq_num)
return true; return true;
} }
int enqueue_reorder_recvframe23a(struct recv_reorder_ctrl *preorder_ctrl, static int enqueue_reorder_recvframe23a(struct recv_reorder_ctrl *preorder_ctrl,
struct recv_frame *prframe) struct recv_frame *prframe)
{ {
struct rx_pkt_attrib *pattrib = &prframe->attrib; struct rx_pkt_attrib *pattrib = &prframe->attrib;
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
#include <mlme_osdep.h> #include <mlme_osdep.h>
#include <sta_info.h> #include <sta_info.h>
void _rtw_init_stainfo(struct sta_info *psta) static void _rtw_init_stainfo(struct sta_info *psta)
{ {
memset((u8 *)psta, 0, sizeof (struct sta_info)); memset((u8 *)psta, 0, sizeof (struct sta_info));
spin_lock_init(&psta->lock); spin_lock_init(&psta->lock);
...@@ -109,7 +109,7 @@ inline struct sta_info *rtw_get_stainfo23a_by_offset23a(struct sta_priv *stapriv ...@@ -109,7 +109,7 @@ inline struct sta_info *rtw_get_stainfo23a_by_offset23a(struct sta_priv *stapriv
} }
/* this function is used to free the memory of lock || sema for all stainfos */ /* this function is used to free the memory of lock || sema for all stainfos */
void rtw_mfree_all_stainfo(struct sta_priv *pstapriv) static void rtw_mfree_all_stainfo(struct sta_priv *pstapriv)
{ {
struct list_head *plist, *phead; struct list_head *plist, *phead;
struct sta_info *psta; struct sta_info *psta;
...@@ -124,7 +124,7 @@ void rtw_mfree_all_stainfo(struct sta_priv *pstapriv) ...@@ -124,7 +124,7 @@ void rtw_mfree_all_stainfo(struct sta_priv *pstapriv)
spin_unlock_bh(&pstapriv->sta_hash_lock); spin_unlock_bh(&pstapriv->sta_hash_lock);
} }
void rtw_mfree_sta_priv_lock(struct sta_priv *pstapriv) static void rtw_mfree_sta_priv_lock(struct sta_priv *pstapriv)
{ {
rtw_mfree_all_stainfo(pstapriv); /* be done before free sta_hash_lock */ rtw_mfree_all_stainfo(pstapriv); /* be done before free sta_hash_lock */
} }
......
...@@ -140,7 +140,7 @@ u8 judge_network_type23a(struct rtw_adapter *padapter, unsigned char *rate, int ...@@ -140,7 +140,7 @@ u8 judge_network_type23a(struct rtw_adapter *padapter, unsigned char *rate, int
return network_type; return network_type;
} }
unsigned char ratetbl_val_2wifirate(unsigned char rate) static unsigned char ratetbl_val_2wifirate(unsigned char rate)
{ {
unsigned char val = 0; unsigned char val = 0;
...@@ -185,7 +185,7 @@ unsigned char ratetbl_val_2wifirate(unsigned char rate) ...@@ -185,7 +185,7 @@ unsigned char ratetbl_val_2wifirate(unsigned char rate)
return val; return val;
} }
int is_basicrate(struct rtw_adapter *padapter, unsigned char rate) static int is_basicrate(struct rtw_adapter *padapter, unsigned char rate)
{ {
int i; int i;
unsigned char val; unsigned char val;
...@@ -203,7 +203,8 @@ int is_basicrate(struct rtw_adapter *padapter, unsigned char rate) ...@@ -203,7 +203,8 @@ int is_basicrate(struct rtw_adapter *padapter, unsigned char rate)
return false; return false;
} }
unsigned int ratetbl2rateset(struct rtw_adapter *padapter, unsigned char *rateset) static unsigned int ratetbl2rateset(struct rtw_adapter *padapter,
unsigned char *rateset)
{ {
int i; int i;
unsigned char rate; unsigned char rate;
...@@ -1232,7 +1233,7 @@ unsigned int is_ap_in_wep23a(struct rtw_adapter *padapter) ...@@ -1232,7 +1233,7 @@ unsigned int is_ap_in_wep23a(struct rtw_adapter *padapter)
} }
} }
int wifirate2_ratetbl_inx23a(unsigned char rate) static int wifirate2_ratetbl_inx23a(unsigned char rate)
{ {
int inx = 0; int inx = 0;
rate = rate & 0x7f; rate = rate & 0x7f;
...@@ -1346,25 +1347,13 @@ unsigned char get_highest_rate_idx23a(u32 mask) ...@@ -1346,25 +1347,13 @@ unsigned char get_highest_rate_idx23a(u32 mask)
return rate_idx; return rate_idx;
} }
unsigned char get_highest_mcs_rate(struct HT_caps_element *pHT_caps)
{
int i, mcs_rate;
mcs_rate = (pHT_caps->u.HT_cap_element.MCS_rate[0] | (pHT_caps->u.HT_cap_element.MCS_rate[1] << 8));
for (i = 15; i >= 0; i--) {
if (mcs_rate & (0x1 << i))
break;
}
return i;
}
void Update_RA_Entry23a(struct rtw_adapter *padapter, struct sta_info *psta) void Update_RA_Entry23a(struct rtw_adapter *padapter, struct sta_info *psta)
{ {
rtw_hal_update_ra_mask23a(psta, 0); rtw_hal_update_ra_mask23a(psta, 0);
} }
void enable_rate_adaptive(struct rtw_adapter *padapter, struct sta_info *psta) static void enable_rate_adaptive(struct rtw_adapter *padapter,
struct sta_info *psta)
{ {
Update_RA_Entry23a(padapter, psta); Update_RA_Entry23a(padapter, psta);
} }
......
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