diff options
| author | Hungyu Lin <dennylin0707@gmail.com> | 2026-05-14 00:37:16 +0300 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2026-05-21 13:39:28 +0300 |
| commit | 95f290497329b7433bc6dfef062bd34b8f66e976 (patch) | |
| tree | f219a4ee8aff95a83a68c457c393fc7d4e05f11b | |
| parent | 07ff92ba0aa1573da1a961cb379b12ff5ae890eb (diff) | |
| download | linux-95f290497329b7433bc6dfef062bd34b8f66e976.tar.xz | |
staging: rtl8723bs: simplify _rtw_enqueue_cmd control flow
Replace the goto exit pattern with a direct return to simplify
the control flow and improve readability.
No functional change intended.
Signed-off-by: Hungyu Lin <dennylin0707@gmail.com>
Link: https://patch.msgid.link/20260513213719.12246-2-dennylin0707@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| -rw-r--r-- | drivers/staging/rtl8723bs/core/rtw_cmd.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl8723bs/core/rtw_cmd.c index f01b0a221b6a..9c21980a80e0 100644 --- a/drivers/staging/rtl8723bs/core/rtw_cmd.c +++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c @@ -253,7 +253,7 @@ int _rtw_enqueue_cmd(struct __queue *queue, struct cmd_obj *obj) unsigned long irqL; if (!obj) - goto exit; + return _SUCCESS; /* spin_lock_bh(&queue->lock); */ spin_lock_irqsave(&queue->lock, irqL); @@ -263,7 +263,6 @@ int _rtw_enqueue_cmd(struct __queue *queue, struct cmd_obj *obj) /* spin_unlock_bh(&queue->lock); */ spin_unlock_irqrestore(&queue->lock, irqL); -exit: return _SUCCESS; } |
