From: "Luka Gejak" <luka.gejak@linux.dev>
To: "Maksym Pikhotskyi" <mpikhotskyi@gmail.com>,
<gregkh@linuxfoundation.org>, <error27@gmail.com>,
<ethantidmore06@gmail.com>, <starpt.official@gmail.com>,
<straube.linux@gmail.com>, <sameekshasankpal@gmail.com>,
<arthur.stupa@gmail.com>, <luka.gejak@linux.dev>
Cc: <linux-staging@lists.linux.dev>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v3 1/2] staging: rtl8723bs: fix stainfo check in rtw_aes_decrypt
Date: Fri, 17 Apr 2026 12:20:37 +0200 [thread overview]
Message-ID: <DHVCRUGQKWML.3PO6W7SN7QPRQ@linux.dev> (raw)
In-Reply-To: <20260417095452.23440-1-mpikhotskyi@gmail.com>
On Fri Apr 17, 2026 at 11:54 AM CEST, Maksym Pikhotskyi wrote:
> The null-pointer-guard was incorrect, returning _FAIL on valid pointer.
> Invert the guard, so it returns _FAIL on invalid pointer.
>
> Fixes: e23ad1570028 ("staging: rtl8723bs: use guard clause for stainfo check")
> Reported-by: Luka Gejak <luka.gejak@linux.dev>
> Closes: https://lore.kernel.org/linux-staging/E4BF62EF-C6F6-431F-8EDC-77C1E613E66B@linux.dev/
> Reviewed-by: Dan Carpenter <error27@gmail.com>
> Signed-off-by: Maksym Pikhotskyi <mpikhotskyi@gmail.com>
> ---
> v2: rebase on staging-next. Split into a series of patches.
> v3: add Reported-by, Closes and Reviewed-by tags.
> ---
> drivers/staging/rtl8723bs/core/rtw_security.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/rtl8723bs/core/rtw_security.c b/drivers/staging/rtl8723bs/core/rtw_security.c
> index a00504ff2910..f467cb5b1dca 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_security.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_security.c
> @@ -1212,7 +1212,7 @@ u32 rtw_aes_decrypt(struct adapter *padapter, u8 *precvframe)
> if (prxattrib->encrypt != _AES_)
> return _SUCCESS;
> stainfo = rtw_get_stainfo(&padapter->stapriv, &prxattrib->ta[0]);
> - if (stainfo)
> + if (!stainfo)
> return _FAIL;
> if (is_multicast_ether_addr(prxattrib->ra)) {
> static unsigned long start;
LGTM.
Reviewed-by: Luka Gejak <luka.gejak@linux.dev>
Best regards,
Luka Gejak
prev parent reply other threads:[~2026-04-17 10:20 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-17 9:54 [PATCH v3 1/2] staging: rtl8723bs: fix stainfo check in rtw_aes_decrypt Maksym Pikhotskyi
2026-04-17 9:54 ` [PATCH v3 2/2] staging: rtl8723bs: reduce nesting in rtw_security.c Maksym Pikhotskyi
2026-04-17 10:22 ` Luka Gejak
2026-04-17 10:20 ` Luka Gejak [this message]
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=DHVCRUGQKWML.3PO6W7SN7QPRQ@linux.dev \
--to=luka.gejak@linux.dev \
--cc=arthur.stupa@gmail.com \
--cc=error27@gmail.com \
--cc=ethantidmore06@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=mpikhotskyi@gmail.com \
--cc=sameekshasankpal@gmail.com \
--cc=starpt.official@gmail.com \
--cc=straube.linux@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