Re: [PATCH] staging: rtl8723bs: fix line length checkpatch warning
From: Dan Carpenter
Date: Mon Jun 15 2026 - 08:53:15 EST
On Mon, Jun 15, 2026 at 05:48:38PM +0530, Devansh Soni wrote:
> Wrap a long pointer arithmetic line to resolve a checkpatch.pl line length warning.
>
> Signed-off-by: Devansh Soni <devanshsoni874@xxxxxxxxx>
> ---
> drivers/staging/rtl8723bs/core/rtw_cmd.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl8723bs/core/rtw_cmd.c
> index c1185c25e..d727a00f2 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_cmd.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c
> @@ -184,7 +184,8 @@ int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv)
> return -ENOMEM;
> }
>
> - pcmdpriv->rsp_buf = pcmdpriv->rsp_allocated_buf + 4 - ((SIZE_PTR)(pcmdpriv->rsp_allocated_buf) & 3);
> + pcmdpriv->rsp_buf = pcmdpriv->rsp_allocated_buf + 4 -
> + ((SIZE_PTR)(pcmdpriv->rsp_allocated_buf) & 3);
This code is ALIGN() the pointer to the 4 byte boundary. We have a macro
for that. But also I bet that the pointer is already aligned to start
with. Also check that we allocated enough space to align it. (I have
not looked at this code outside of what I can see in this email).
regards,
dan carpenter