From: luka.gejak@linux.dev
To: Marcos Andrade <marcosandrade95963@gmail.com>
Cc: linux-staging@lists.linux.dev, luka.gejak@linux.dev
Subject: Re: [PATCH 0/2] staging: rtl8723bs: fix boolean logic and clean up coding style
Date: Mon, 30 Mar 2026 10:40:19 +0200 [thread overview]
Message-ID: <20260330084019.4356-1-luka.gejak@linux.dev> (raw)
In-Reply-To: <20260326014221.525368-1-marcosandrade95963@gmail.com>
Thanks for working on this cleanup. The series is well-structured and
almost perfect, however below is my comment on what could be improved.
PATCH 1/2
Looks good, the defensive fix is correct and the commit message explains
the rationale well, but:
The subject lines use 'core:rtw_wlan_util.c' which is non-standard.
The kernel convention for staging patches is:
[PATCH <n/m>] staging: <driver-name>: <short description>
Patch 1/2:
[PATCH 1/2] staging: rtl8723bs: fix boolean comparison Switch_DM_Func
PATCH 2/2
Two issues to address:
1) In adaptive_early_32k(), you left this unchanged:
if (pmlmeext->bcn_cnt > 100 && (pmlmeext->adaptive_tsf_done == true))
This should be converted to match the boolean fix in patch 1:
if (pmlmeext->bcn_cnt > 100 && pmlmeext->adaptive_tsf_done)
2) Patch 2 does not apply to staging-next tree, please rebase on top of
a staging-next and resend
Also one more thing, please make proper indentation, if you are line
breaking you should allign ( and ( from line above. Same for letters
you should allign the first letter in bracket with the first letter
from upper line. Your code:
- rtw_hal_set_hwreg(Adapter, HW_VAR_ACK_PREAMBLE, (u8 *)&ShortPreamble);
+ rtw_hal_set_hwreg(Adapter, HW_VAR_ACK_PREAMBLE,
+ (u8 *)&ShortPreamble);
- pmlmeext->bcn_delay_ratio[i] = (pmlmeext->bcn_delay_cnt[i] * 100) / pmlmeext->bcn_cnt;
+ pmlmeext->bcn_delay_ratio[i] = (pmlmeext->bcn_delay_cnt[i] * 100) /
+ pmlmeext->bcn_cnt;
Correct:
- rtw_hal_set_hwreg(Adapter, HW_VAR_ACK_PREAMBLE, (u8 *)&ShortPreamble);
+ rtw_hal_set_hwreg(Adapter, HW_VAR_ACK_PREAMBLE,
+ (u8 *)&ShortPreamble);
- pmlmeext->bcn_delay_ratio[i] = (pmlmeext->bcn_delay_cnt[i] * 100) / pmlmeext->bcn_cnt;
+ pmlmeext->bcn_delay_ratio[i] = (pmlmeext->bcn_delay_cnt[i] * 100) /
+ pmlmeext->bcn_cnt;
Best regards,
Luka Gejak
prev parent reply other threads:[~2026-03-30 8:40 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-26 1:42 [PATCH 0/2] staging: rtl8723bs: fix boolean logic and clean up coding style Marcos Andrade
2026-03-26 1:42 ` [PATCH 1/2] staging: rtl8723bs: fix coding style issues in core:rtw_wlan_util.c Marcos Andrade
2026-03-26 1:42 ` [PATCH 2/2] staging: rtl8723bs: fix coding style and remove dead code Marcos Andrade
2026-03-30 8:40 ` 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=20260330084019.4356-1-luka.gejak@linux.dev \
--to=luka.gejak@linux.dev \
--cc=linux-staging@lists.linux.dev \
--cc=marcosandrade95963@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