* [PATCH] staging: rtl8723bs: fix line length checkpatch warning
@ 2026-06-15 12:18 Devansh Soni
2026-06-15 12:23 ` Greg KH
2026-06-15 12:52 ` Dan Carpenter
0 siblings, 2 replies; 3+ messages in thread
From: Devansh Soni @ 2026-06-15 12:18 UTC (permalink / raw)
To: gregkh; +Cc: linux-staging, linux-kernel, Devansh Soni
Wrap a long pointer arithmetic line to resolve a checkpatch.pl line length warning.
Signed-off-by: Devansh Soni <devanshsoni874@gmail.com>
---
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);
pcmdpriv->cmd_issued_cnt = 0;
pcmdpriv->cmd_done_cnt = 0;
--
2.54.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] staging: rtl8723bs: fix line length checkpatch warning
2026-06-15 12:18 [PATCH] staging: rtl8723bs: fix line length checkpatch warning Devansh Soni
@ 2026-06-15 12:23 ` Greg KH
2026-06-15 12:52 ` Dan Carpenter
1 sibling, 0 replies; 3+ messages in thread
From: Greg KH @ 2026-06-15 12:23 UTC (permalink / raw)
To: Devansh Soni; +Cc: linux-staging, linux-kernel
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.
Ironically, this text is too wide :(
Didn't checkpatch complain about that?
thanks,
greg k-h
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] staging: rtl8723bs: fix line length checkpatch warning
2026-06-15 12:18 [PATCH] staging: rtl8723bs: fix line length checkpatch warning Devansh Soni
2026-06-15 12:23 ` Greg KH
@ 2026-06-15 12:52 ` Dan Carpenter
1 sibling, 0 replies; 3+ messages in thread
From: Dan Carpenter @ 2026-06-15 12:52 UTC (permalink / raw)
To: Devansh Soni; +Cc: gregkh, linux-staging, linux-kernel
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@gmail.com>
> ---
> 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
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-06-15 12:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-15 12:18 [PATCH] staging: rtl8723bs: fix line length checkpatch warning Devansh Soni
2026-06-15 12:23 ` Greg KH
2026-06-15 12:52 ` Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox