mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-10 07:00:48 +00:00
staging: r8188eu: use standard error codes in rtl8188eu_inirp_init
Replace the driver-specific _SUCCESS and _FAIL error codes in rtl8188eu_inirp_init. Return 0 for success or a negative error code as we do elsewhere in the kernel. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20230206201800.139195-4-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
972b28a485
commit
a0b3a1c269
@ -848,29 +848,25 @@ u32 rtl8188eu_hal_deinit(struct adapter *Adapter)
|
||||
return _SUCCESS;
|
||||
}
|
||||
|
||||
unsigned int rtl8188eu_inirp_init(struct adapter *Adapter)
|
||||
int rtl8188eu_inirp_init(struct adapter *Adapter)
|
||||
{
|
||||
u8 i;
|
||||
struct recv_buf *precvbuf;
|
||||
uint status;
|
||||
struct recv_priv *precvpriv = &Adapter->recvpriv;
|
||||
|
||||
status = _SUCCESS;
|
||||
int ret;
|
||||
|
||||
/* issue Rx irp to receive data */
|
||||
precvbuf = (struct recv_buf *)precvpriv->precv_buf;
|
||||
for (i = 0; i < NR_RECVBUFF; i++) {
|
||||
if (!rtw_read_port(Adapter, precvbuf)) {
|
||||
status = _FAIL;
|
||||
goto exit;
|
||||
}
|
||||
ret = rtw_read_port(Adapter, precvbuf);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
precvbuf++;
|
||||
precvpriv->free_recv_buf_queue_cnt--;
|
||||
}
|
||||
|
||||
exit:
|
||||
return status;
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* */
|
||||
|
@ -26,7 +26,7 @@ void UpdateHalRAMask8188EUsb(struct adapter *adapt, u32 mac_id, u8 rssi_level);
|
||||
int rtl8188e_IOL_exec_cmds_sync(struct adapter *adapter,
|
||||
struct xmit_frame *xmit_frame, u32 max_wating_ms, u32 bndy_cnt);
|
||||
|
||||
unsigned int rtl8188eu_inirp_init(struct adapter *Adapter);
|
||||
int rtl8188eu_inirp_init(struct adapter *Adapter);
|
||||
|
||||
uint rtw_hal_init(struct adapter *padapter);
|
||||
uint rtw_hal_deinit(struct adapter *padapter);
|
||||
|
Loading…
x
Reference in New Issue
Block a user