Re: [PATCH v3 2/2] staging: rtl8723bs: refactor rtw_joinbss_event_prehandle to reduce indentation

From: Dan Carpenter

Date: Sat Mar 21 2026 - 03:49:34 EST


On Sat, Mar 21, 2026 at 10:46:48AM +0300, Dan Carpenter wrote:
> 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.

(This was not intended for you Jose, I'm trying to create a TODO list
for kernel janitors to work on so I put KTODO in the email so people
looking for things to do can find it on lore).

regards,
dan carpenter