diff options
author | Madhumitha Prabakaran <madhumithabiw@gmail.com> | 2019-03-20 18:02:02 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-03-21 08:25:01 +0100 |
commit | e4432160d9b3ff5d23dc6af6fac3ed5cbd1a14f2 (patch) | |
tree | 73ae66a9a1604ea2074fd9548c4a9169eabd96a1 /drivers/staging/rtl8723bs/core | |
parent | 19c74ea57715c09c63eb7ddeadab84503f9fed9f (diff) |
Staging: rtl8723bs: Change return type and type of local variable
rtw_startbss_cmd can return the result of calling rtw_enqueue_cmd, which
can return the result of calling _rtw_enqueue_cmd, but they all have
different return types (u8, u32, and sint, respectively).
As all of these functions return error codes, change all the return types
to int, in preparation for converting these functions to use standard
kernel error codes.
Also, remove extern from the function declaration to maintain Linux kernel
coding style.
Issue suggested by Coccinelle.
Signed-off-by: Madhumitha Prabakaran <madhumithabiw@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8723bs/core')
-rw-r--r-- | drivers/staging/rtl8723bs/core/rtw_cmd.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl8723bs/core/rtw_cmd.c index bd3a5a23a418..04c6927dab8b 100644 --- a/drivers/staging/rtl8723bs/core/rtw_cmd.c +++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c @@ -256,7 +256,7 @@ ISR/Call-Back functions can't call this sub-function. */ -sint _rtw_enqueue_cmd(struct __queue *queue, struct cmd_obj *obj) +int _rtw_enqueue_cmd(struct __queue *queue, struct cmd_obj *obj) { _irqL irqL; @@ -331,7 +331,7 @@ int rtw_cmd_filter(struct cmd_priv *pcmdpriv, struct cmd_obj *cmd_obj) -u32 rtw_enqueue_cmd(struct cmd_priv *pcmdpriv, struct cmd_obj *cmd_obj) +int rtw_enqueue_cmd(struct cmd_priv *pcmdpriv, struct cmd_obj *cmd_obj) { int res = _FAIL; struct adapter *padapter = pcmdpriv->padapter; @@ -719,12 +719,12 @@ exit: return res; } -u8 rtw_startbss_cmd(struct adapter *padapter, int flags) +int rtw_startbss_cmd(struct adapter *padapter, int flags) { struct cmd_obj *pcmd; struct cmd_priv *pcmdpriv = &padapter->cmdpriv; struct submit_ctx sctx; - u8 res = _SUCCESS; + int res = _SUCCESS; if (flags & RTW_CMDF_DIRECTLY) { /* no need to enqueue, do the cmd hdl directly and free cmd parameter */ |