public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <error27@gmail.com>
To: deep@crimson.net.eu.org
Cc: gregkh@linuxfoundation.org, linux-staging@lists.linux.dev,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: rtl8723bs: convert int16_t to s16
Date: Mon, 13 Apr 2026 17:44:24 +0300	[thread overview]
Message-ID: <ad0BSPP6jbeCHOJ-@stanley.mountain> (raw)
In-Reply-To: <20260413143320.1246385-1-deep@crimson.net.eu.org>

On Mon, Apr 13, 2026 at 04:33:20PM +0200, deep@crimson.net.eu.org wrote:
> From: Kenet Jovan Sokoli <deep@crimson.net.eu.org>
> 
> The TODO list for the rtl8723bs driver mentions the conversion of
> unusual variable types to the preferred kernel style. Convert the
> "power_limit" variable in include/wifi.h from int16_t to s16.
> 
> Signed-off-by: Kenet Jovan Sokoli <deep@crimson.net.eu.org>
> ---
>  drivers/staging/rtl8723bs/include/wifi.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/rtl8723bs/include/wifi.h b/drivers/staging/rtl8723bs/include/wifi.h
> index 230b2c4ffd3b..8ab0cb6ba344 100644
> --- a/drivers/staging/rtl8723bs/include/wifi.h
> +++ b/drivers/staging/rtl8723bs/include/wifi.h
> @@ -457,7 +457,7 @@ struct rtw_regulatory {
>  	u32 tp_scale;
>  	u16 current_rd;
>  	u16 current_rd_ext;
> -	int16_t power_limit;
> +	s16 power_limit;

Generally, variables like s16 and s32 should only be used when they
are defined by a hardware or protocol spec.  You should just use
short and int for normal code.

In this case, the rtw_regulatory is never really used.  There are
a few functions which take it as a parameter they aren't used and
we always pass NULL pointers to them.

Cleanup the functions and then delete the whole struct rtw_regulatory
and struct.

regards,
dan carpenter

>  	struct regd_pair_mapping *regpair;
>  };


      reply	other threads:[~2026-04-13 14:44 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-13 14:33 [PATCH] staging: rtl8723bs: convert int16_t to s16 deep
2026-04-13 14:44 ` Dan Carpenter [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=ad0BSPP6jbeCHOJ-@stanley.mountain \
    --to=error27@gmail.com \
    --cc=deep@crimson.net.eu.org \
    --cc=gregkh@linuxfoundation.org \
    --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