* [PATCH 1/3] staging: rtl8188eu: goto replaced by 'else' branch
@ 2015-11-06 15:17 Ivan Safonov
2015-11-07 3:14 ` Greg Kroah-Hartman
0 siblings, 1 reply; 3+ messages in thread
From: Ivan Safonov @ 2015-11-06 15:17 UTC (permalink / raw)
To: devel
Cc: Greg Kroah-Hartman, Ivan Safonov, Larry Finger, Vaishali Thakkar,
Bryan Paul, linux-kernel
goto is not needed here.
Signed-off-by: Ivan Safonov <insafonov@gmail.com>
---
drivers/staging/rtl8188eu/core/rtw_cmd.c | 25 +++++++++++--------------
1 file changed, 11 insertions(+), 14 deletions(-)
diff --git a/drivers/staging/rtl8188eu/core/rtw_cmd.c b/drivers/staging/rtl8188eu/core/rtw_cmd.c
index 1d03727..c0fff77 100644
--- a/drivers/staging/rtl8188eu/core/rtw_cmd.c
+++ b/drivers/staging/rtl8188eu/core/rtw_cmd.c
@@ -201,23 +201,20 @@ _next:
if (rtw_cmd_filter(pcmdpriv, pcmd) == _FAIL) {
pcmd->res = H2C_DROPPED;
- goto post_process;
- }
-
- if (pcmd->cmdcode < ARRAY_SIZE(wlancmds)) {
- cmd_hdl = wlancmds[pcmd->cmdcode].h2cfuns;
-
- if (cmd_hdl) {
- ret = cmd_hdl(pcmd->padapter, pcmd->parmbuf);
- pcmd->res = ret;
- }
} else {
- pcmd->res = H2C_PARAMETERS_ERROR;
- }
+ if (pcmd->cmdcode < ARRAY_SIZE(wlancmds)) {
+ cmd_hdl = wlancmds[pcmd->cmdcode].h2cfuns;
- cmd_hdl = NULL;
+ if (cmd_hdl) {
+ ret = cmd_hdl(pcmd->padapter, pcmd->parmbuf);
+ pcmd->res = ret;
+ }
+ } else {
+ pcmd->res = H2C_PARAMETERS_ERROR;
+ }
-post_process:
+ cmd_hdl = NULL;
+ }
/* call callback function for post-processed */
if (pcmd->cmdcode < ARRAY_SIZE(rtw_cmd_callback)) {
--
2.4.10
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/3] staging: rtl8188eu: goto replaced by 'else' branch
2015-11-06 15:17 [PATCH 1/3] staging: rtl8188eu: goto replaced by 'else' branch Ivan Safonov
@ 2015-11-07 3:14 ` Greg Kroah-Hartman
2015-11-07 4:10 ` Ivan Safonov
0 siblings, 1 reply; 3+ messages in thread
From: Greg Kroah-Hartman @ 2015-11-07 3:14 UTC (permalink / raw)
To: Ivan Safonov
Cc: devel, Vaishali Thakkar, linux-kernel, Larry Finger, Bryan Paul
On Fri, Nov 06, 2015 at 10:17:29PM +0700, Ivan Safonov wrote:
> goto is not needed here.
>
> Signed-off-by: Ivan Safonov <insafonov@gmail.com>
> ---
> drivers/staging/rtl8188eu/core/rtw_cmd.c | 25 +++++++++++--------------
> 1 file changed, 11 insertions(+), 14 deletions(-)
>
I've applied most of these patches, but I got a bit confused about what
order for some of these. Can you please look at what I applied and
resend what I missed, in a single set of patches that are properly
numbered so I have a chance to get it right?
thanks,
greg k-h
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 1/3] staging: rtl8188eu: goto replaced by 'else' branch
2015-11-07 3:14 ` Greg Kroah-Hartman
@ 2015-11-07 4:10 ` Ivan Safonov
0 siblings, 0 replies; 3+ messages in thread
From: Ivan Safonov @ 2015-11-07 4:10 UTC (permalink / raw)
To: Greg Kroah-Hartman
Cc: devel, Vaishali Thakkar, linux-kernel, Larry Finger, Bryan Paul
On 11/07/2015 10:14 AM, Greg Kroah-Hartman wrote:
> On Fri, Nov 06, 2015 at 10:17:29PM +0700, Ivan Safonov wrote:
>> goto is not needed here.
>>
>> Signed-off-by: Ivan Safonov <insafonov@gmail.com>
>> ---
>> drivers/staging/rtl8188eu/core/rtw_cmd.c | 25 +++++++++++--------------
>> 1 file changed, 11 insertions(+), 14 deletions(-)
>>
> I've applied most of these patches, but I got a bit confused about what
> order for some of these. Can you please look at what I applied and
> resend what I missed, in a single set of patches that are properly
> numbered so I have a chance to get it right?
>
> thanks,
>
> greg k-h
Yes, of course.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-11-07 4:08 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-06 15:17 [PATCH 1/3] staging: rtl8188eu: goto replaced by 'else' branch Ivan Safonov
2015-11-07 3:14 ` Greg Kroah-Hartman
2015-11-07 4:10 ` Ivan Safonov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox