Commit f66e05d8 authored by Jes Sorensen's avatar Jes Sorensen Committed by Greg Kroah-Hartman

staging: rtl8723au: rtw_mlme_ext.c: Use int to return error codes

Signed-off-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 7e761c5a
...@@ -2065,7 +2065,7 @@ static int OnAction23a_back23a(struct rtw_adapter *padapter, ...@@ -2065,7 +2065,7 @@ static int OnAction23a_back23a(struct rtw_adapter *padapter,
return _SUCCESS; return _SUCCESS;
} }
static s32 rtw_action_public_decache(struct recv_frame *recv_frame, s32 token) static int rtw_action_public_decache(struct recv_frame *recv_frame, s32 token)
{ {
struct rtw_adapter *adapter = recv_frame->adapter; struct rtw_adapter *adapter = recv_frame->adapter;
struct mlme_ext_priv *mlmeext = &adapter->mlmeextpriv; struct mlme_ext_priv *mlmeext = &adapter->mlmeextpriv;
...@@ -2105,7 +2105,7 @@ static s32 rtw_action_public_decache(struct recv_frame *recv_frame, s32 token) ...@@ -2105,7 +2105,7 @@ static s32 rtw_action_public_decache(struct recv_frame *recv_frame, s32 token)
return _SUCCESS; return _SUCCESS;
} }
static unsigned int on_action_public23a_p2p(struct recv_frame *precv_frame) static int on_action_public23a_p2p(struct recv_frame *precv_frame)
{ {
struct sk_buff *skb = precv_frame->pkt; struct sk_buff *skb = precv_frame->pkt;
u8 *pframe = skb->data; u8 *pframe = skb->data;
...@@ -2123,7 +2123,7 @@ static unsigned int on_action_public23a_p2p(struct recv_frame *precv_frame) ...@@ -2123,7 +2123,7 @@ static unsigned int on_action_public23a_p2p(struct recv_frame *precv_frame)
return _SUCCESS; return _SUCCESS;
} }
static unsigned int on_action_public23a_vendor(struct recv_frame *precv_frame) static int on_action_public23a_vendor(struct recv_frame *precv_frame)
{ {
unsigned int ret = _FAIL; unsigned int ret = _FAIL;
struct sk_buff *skb = precv_frame->pkt; struct sk_buff *skb = precv_frame->pkt;
...@@ -2168,7 +2168,7 @@ on_action_public23a_default(struct recv_frame *precv_frame, u8 action) ...@@ -2168,7 +2168,7 @@ on_action_public23a_default(struct recv_frame *precv_frame, u8 action)
static int on_action_public23a(struct rtw_adapter *padapter, static int on_action_public23a(struct rtw_adapter *padapter,
struct recv_frame *precv_frame) struct recv_frame *precv_frame)
{ {
unsigned int ret = _FAIL; int ret = _FAIL;
struct sk_buff *skb = precv_frame->pkt; struct sk_buff *skb = precv_frame->pkt;
struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data;
u8 *pframe = skb->data; u8 *pframe = skb->data;
...@@ -2332,10 +2332,10 @@ void dump_mgntframe23a(struct rtw_adapter *padapter, ...@@ -2332,10 +2332,10 @@ void dump_mgntframe23a(struct rtw_adapter *padapter,
rtl8723au_mgnt_xmit(padapter, pmgntframe); rtl8723au_mgnt_xmit(padapter, pmgntframe);
} }
s32 dump_mgntframe23a_and_wait(struct rtw_adapter *padapter, int dump_mgntframe23a_and_wait(struct rtw_adapter *padapter,
struct xmit_frame *pmgntframe, int timeout_ms) struct xmit_frame *pmgntframe, int timeout_ms)
{ {
s32 ret = _FAIL; int ret = _FAIL;
unsigned long irqL; unsigned long irqL;
struct xmit_priv *pxmitpriv = &padapter->xmitpriv; struct xmit_priv *pxmitpriv = &padapter->xmitpriv;
struct xmit_buf *pxmitbuf = pmgntframe->pxmitbuf; struct xmit_buf *pxmitbuf = pmgntframe->pxmitbuf;
...@@ -2360,16 +2360,16 @@ s32 dump_mgntframe23a_and_wait(struct rtw_adapter *padapter, ...@@ -2360,16 +2360,16 @@ s32 dump_mgntframe23a_and_wait(struct rtw_adapter *padapter,
return ret; return ret;
} }
s32 dump_mgntframe23a_and_wait_ack23a(struct rtw_adapter *padapter, int dump_mgntframe23a_and_wait_ack23a(struct rtw_adapter *padapter,
struct xmit_frame *pmgntframe) struct xmit_frame *pmgntframe)
{ {
s32 ret = _FAIL; int ret = _FAIL;
u32 timeout_ms = 500;/* 500ms */ u32 timeout_ms = 500;/* 500ms */
struct xmit_priv *pxmitpriv = &padapter->xmitpriv; struct xmit_priv *pxmitpriv = &padapter->xmitpriv;
if (padapter->bSurpriseRemoved == true || if (padapter->bSurpriseRemoved == true ||
padapter->bDriverStopped == true) padapter->bDriverStopped == true)
return -1; return _FAIL;
mutex_lock(&pxmitpriv->ack_tx_mutex); mutex_lock(&pxmitpriv->ack_tx_mutex);
pxmitpriv->ack_tx = true; pxmitpriv->ack_tx = true;
...@@ -4278,7 +4278,7 @@ static void issue_action_BSSCoexistPacket(struct rtw_adapter *padapter) ...@@ -4278,7 +4278,7 @@ static void issue_action_BSSCoexistPacket(struct rtw_adapter *padapter)
dump_mgntframe23a(padapter, pmgntframe); dump_mgntframe23a(padapter, pmgntframe);
} }
unsigned int send_delba23a(struct rtw_adapter *padapter, u8 initiator, u8 *addr) int send_delba23a(struct rtw_adapter *padapter, u8 initiator, u8 *addr)
{ {
struct sta_priv *pstapriv = &padapter->stapriv; struct sta_priv *pstapriv = &padapter->stapriv;
struct sta_info *psta = NULL; struct sta_info *psta = NULL;
...@@ -4318,7 +4318,7 @@ unsigned int send_delba23a(struct rtw_adapter *padapter, u8 initiator, u8 *addr) ...@@ -4318,7 +4318,7 @@ unsigned int send_delba23a(struct rtw_adapter *padapter, u8 initiator, u8 *addr)
return _SUCCESS; return _SUCCESS;
} }
unsigned int send_beacon23a(struct rtw_adapter *padapter) int send_beacon23a(struct rtw_adapter *padapter)
{ {
bool bxmitok; bool bxmitok;
int issue = 0; int issue = 0;
...@@ -4464,9 +4464,9 @@ void site_survey23a(struct rtw_adapter *padapter) ...@@ -4464,9 +4464,9 @@ void site_survey23a(struct rtw_adapter *padapter)
} }
/* collect bss info from Beacon and Probe request/response frames. */ /* collect bss info from Beacon and Probe request/response frames. */
u8 collect_bss_info23a(struct rtw_adapter *padapter, int collect_bss_info23a(struct rtw_adapter *padapter,
struct recv_frame *precv_frame, struct recv_frame *precv_frame,
struct wlan_bssid_ex *bssid) struct wlan_bssid_ex *bssid)
{ {
int i; int i;
const u8 *p; const u8 *p;
...@@ -4808,7 +4808,8 @@ void start_clnt_assoc23a(struct rtw_adapter* padapter) ...@@ -4808,7 +4808,8 @@ void start_clnt_assoc23a(struct rtw_adapter* padapter)
set_link_timer(pmlmeext, REASSOC_TO); set_link_timer(pmlmeext, REASSOC_TO);
} }
unsigned int receive_disconnect23a(struct rtw_adapter *padapter, unsigned char *MacAddr, unsigned short reason) int receive_disconnect23a(struct rtw_adapter *padapter,
unsigned char *MacAddr, unsigned short reason)
{ {
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;
......
...@@ -498,9 +498,9 @@ void flush_all_cam_entry23a(struct rtw_adapter *padapter); ...@@ -498,9 +498,9 @@ void flush_all_cam_entry23a(struct rtw_adapter *padapter);
bool IsLegal5GChannel(struct rtw_adapter *Adapter, u8 channel); bool IsLegal5GChannel(struct rtw_adapter *Adapter, u8 channel);
void site_survey23a(struct rtw_adapter *padapter); void site_survey23a(struct rtw_adapter *padapter);
u8 collect_bss_info23a(struct rtw_adapter *padapter, int collect_bss_info23a(struct rtw_adapter *padapter,
struct recv_frame *precv_frame, struct recv_frame *precv_frame,
struct wlan_bssid_ex *bssid); struct wlan_bssid_ex *bssid);
void update_network23a(struct wlan_bssid_ex *dst, struct wlan_bssid_ex *src, void update_network23a(struct wlan_bssid_ex *dst, struct wlan_bssid_ex *src,
struct rtw_adapter *padapter, bool update_ie); struct rtw_adapter *padapter, bool update_ie);
...@@ -548,8 +548,8 @@ unsigned int update_MSC_rate23a(struct HT_caps_element *pHT_caps); ...@@ -548,8 +548,8 @@ unsigned int update_MSC_rate23a(struct HT_caps_element *pHT_caps);
void Update_RA_Entry23a(struct rtw_adapter *padapter, struct sta_info *psta); void Update_RA_Entry23a(struct rtw_adapter *padapter, struct sta_info *psta);
void set_sta_rate23a(struct rtw_adapter *padapter, struct sta_info *psta); void set_sta_rate23a(struct rtw_adapter *padapter, struct sta_info *psta);
unsigned int receive_disconnect23a(struct rtw_adapter *padapter, int receive_disconnect23a(struct rtw_adapter *padapter,
unsigned char *MacAddr, unsigned short reason); unsigned char *MacAddr, unsigned short reason);
unsigned char get_highest_rate_idx23a(u32 mask); unsigned char get_highest_rate_idx23a(u32 mask);
int support_short_GI23a(struct rtw_adapter *padapter, int support_short_GI23a(struct rtw_adapter *padapter,
...@@ -605,8 +605,8 @@ void issue_action_spct_ch_switch23a(struct rtw_adapter *padapter, u8 *ra, ...@@ -605,8 +605,8 @@ void issue_action_spct_ch_switch23a(struct rtw_adapter *padapter, u8 *ra,
void issue_action_BA23a(struct rtw_adapter *padapter, void issue_action_BA23a(struct rtw_adapter *padapter,
const unsigned char *raddr, const unsigned char *raddr,
unsigned char action, unsigned short status); unsigned char action, unsigned short status);
unsigned int send_delba23a(struct rtw_adapter *padapter, u8 initiator, u8 *addr); int send_delba23a(struct rtw_adapter *padapter, u8 initiator, u8 *addr);
unsigned int send_beacon23a(struct rtw_adapter *padapter); int send_beacon23a(struct rtw_adapter *padapter);
void start_clnt_assoc23a(struct rtw_adapter *padapter); void start_clnt_assoc23a(struct rtw_adapter *padapter);
void start_clnt_auth23a(struct rtw_adapter *padapter); void start_clnt_auth23a(struct rtw_adapter *padapter);
......
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