Linux kernel staging patches
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: 2023060904@ycu.edu.cn
Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org,
	guagua210311@qq.com
Subject: Re: [PATCH 2/3] rtl8723bs: sdio: Use local error_count instead of global variable
Date: Sat, 10 Jan 2026 14:24:15 +0100	[thread overview]
Message-ID: <2026011047-monoxide-tidings-190c@gregkh> (raw)
In-Reply-To: <A23D22DD90AB07AE+20260110101801.5820-3-2023060904@ycu.edu.cn>

On Sat, Jan 10, 2026 at 06:17:59PM +0800, 2023060904@ycu.edu.cn wrote:
> From: changjunzheng <guagua210311@qq.com>
> 
> Replace the global continual_io_error variable with a local error_count in
> sd_read32 and sd_write32 functions. This eliminates cross-function dependency
> on the global variable and keeps the error counting logic isolated to each
> IO operation.
> 
> Changelog v3 -> v4:
> 1. Split the single v3 patch into 4 logical patches (per Greg KH's request)
> 2. Fix all coding style errors (trailing spaces, missing assignment spaces, indentation)
> 3. Add clear, purpose-driven commit messages for each patch
> 4. Add version changelog as required by kernel documentation
> 
> Signed-off-by: changjunzheng <guagua210311@qq.com>
> ---
>  .../staging/rtl8723bs/os_dep/sdio_ops_linux.c    | 16 +++++++++-------
>  1 file changed, 9 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/staging/rtl8723bs/os_dep/sdio_ops_linux.c b/drivers/staging/rtl8723bs/os_dep/sdio_ops_linux.c
> index 5dc00e9117ae..571a2c6fc37a 100644
> --- a/drivers/staging/rtl8723bs/os_dep/sdio_ops_linux.c
> +++ b/drivers/staging/rtl8723bs/os_dep/sdio_ops_linux.c
> @@ -207,7 +207,7 @@ u32 sd_read32(struct intf_hdl *pintfhdl, u32 addr, s32 *err)
>  
>  	if (err && *err) {
>  		int i;
> -
> +		int error_count = 0;
>  		*err = 0;
>  		for (i = 0; i < SD_IO_TRY_CNT; i++) {
>  			if (claim_needed)
> @@ -217,13 +217,13 @@ u32 sd_read32(struct intf_hdl *pintfhdl, u32 addr, s32 *err)
>  				sdio_release_host(func);
>  
>  			if (*err == 0) {
> -				rtw_reset_continual_io_error(psdiodev);
> +				error_count=0;

Always run checkpatch.pl on your submissions so that you don't get
grumpy maintainers asking you why you didn't run checkpatch.pl on your
submission :)

  reply	other threads:[~2026-01-10 20:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20260110101801.5820-1-2023060904@ycu.edu.cn>
2026-01-10 10:17 ` [PATCH 1/3] rtl8723bs: io: Add independent rtw_check_continual_io_error function 2023060904
2026-01-10 13:22   ` Greg KH
2026-01-10 10:17 ` [PATCH 2/3] rtl8723bs: sdio: Use local error_count instead of global variable 2023060904
2026-01-10 13:24   ` Greg KH [this message]
2026-01-10 10:18 ` [PATCH 3/3] rtl8723bs: io: Remove redundant global continual_io_error variable 2023060904

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=2026011047-monoxide-tidings-190c@gregkh \
    --to=gregkh@linuxfoundation.org \
    --cc=2023060904@ycu.edu.cn \
    --cc=guagua210311@qq.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-staging@lists.linux.dev \
    /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