From: Dan Carpenter <dan.carpenter@linaro.org>
To: "Jose A. Perez de Azpillaga" <azpijr@gmail.com>
Cc: linux-staging@lists.linux.dev,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Michael Straube <straube.linux@gmail.com>,
Hans de Goede <hansg@kernel.org>,
Khushal Chitturi <khushalchitturi@gmail.com>,
Ethan Tidmore <ethantidmore06@gmail.com>,
Luka Gejak <luka.gejak@linux.dev>,
Vivek BalachandharTN <vivek.balachandhar@gmail.com>,
Artur Stupa <arthur.stupa@gmail.com>,
Zhuoheng Li <lizhuoheng@kylinos.cn>,
Nino Zhang <ninozhang001@gmail.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 2/2] staging: rtl8723bs: refactor rtw_joinbss_event_prehandle to reduce indentation
Date: Sat, 21 Mar 2026 10:46:48 +0300 [thread overview]
Message-ID: <ab5M6Hvs1_8noick@stanley.mountain> (raw)
In-Reply-To: <20260320154724.603847-3-azpijr@gmail.com>
On Fri, Mar 20, 2026 at 04:47:17PM +0100, Jose A. Perez de Azpillaga wrote:
> -ignore_joinbss_callback:
> + spin_unlock_bh(&pmlmepriv->scanned_queue.lock);
>
> spin_unlock_bh(&pmlmepriv->lock);
> + /* s5. Cancel assoc_timer */
> + timer_delete_sync(&pmlmepriv->assoc_timer);
> + return;
> }
So close... But you can't end a void function with a return statement.
It causes a checkpatch warning.
KTODO: Fix checkpatch to catch extra void statements
Checkpatch will catch an unnecessary return statement like this when
people use the -f option, but why can't it catch it for normal patches?
Surely, if there is a line which is just "}" then we could just print
a warning if the previous line is "return;"?
Test this on commits in the git log to find if there is a non-obvious
reason why it only works for -f.
regards,
dan carpenter
next prev parent reply other threads:[~2026-03-21 7:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-20 15:47 [PATCH v3 0/2] staging: rtl8723bs: clean up rtw_joinbss_event_prehandle Jose A. Perez de Azpillaga
2026-03-20 15:47 ` [PATCH v3 1/2] staging: rtl8723bs: remove dead REJOIN code Jose A. Perez de Azpillaga
2026-03-20 15:47 ` [PATCH v3 2/2] staging: rtl8723bs: refactor rtw_joinbss_event_prehandle to reduce indentation Jose A. Perez de Azpillaga
2026-03-21 7:46 ` Dan Carpenter [this message]
2026-03-21 7:48 ` Dan Carpenter
2026-03-20 17:47 ` [PATCH v3 0/2] staging: rtl8723bs: clean up rtw_joinbss_event_prehandle Luka Gejak
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ab5M6Hvs1_8noick@stanley.mountain \
--to=dan.carpenter@linaro.org \
--cc=arthur.stupa@gmail.com \
--cc=azpijr@gmail.com \
--cc=ethantidmore06@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=hansg@kernel.org \
--cc=khushalchitturi@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=lizhuoheng@kylinos.cn \
--cc=luka.gejak@linux.dev \
--cc=ninozhang001@gmail.com \
--cc=straube.linux@gmail.com \
--cc=vivek.balachandhar@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox