* [PATCH] mwifiex: remove unused evt_buf variable
@ 2023-03-29 13:14 Tom Rix
2023-03-29 13:44 ` Simon Horman
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Tom Rix @ 2023-03-29 13:14 UTC (permalink / raw)
To: amitkarwar, ganapathi017, sharvari.harisangam, huxinming820,
kvalo, davem, edumazet, kuba, pabeni, nathan, ndesaulniers
Cc: linux-wireless, netdev, linux-kernel, llvm, Tom Rix
clang with W=1 reports
drivers/net/wireless/marvell/mwifiex/11h.c:198:6: error: variable
'evt_buf' set but not used [-Werror,-Wunused-but-set-variable]
u8 *evt_buf;
^
This variable is not used so remove it.
Signed-off-by: Tom Rix <trix@redhat.com>
---
drivers/net/wireless/marvell/mwifiex/11h.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/drivers/net/wireless/marvell/mwifiex/11h.c b/drivers/net/wireless/marvell/mwifiex/11h.c
index b0c40a776a2e..2ea03725f188 100644
--- a/drivers/net/wireless/marvell/mwifiex/11h.c
+++ b/drivers/net/wireless/marvell/mwifiex/11h.c
@@ -195,7 +195,6 @@ int mwifiex_11h_handle_chanrpt_ready(struct mwifiex_private *priv,
{
struct host_cmd_ds_chan_rpt_event *rpt_event;
struct mwifiex_ie_types_chan_rpt_data *rpt;
- u8 *evt_buf;
u16 event_len, tlv_len;
rpt_event = (void *)(skb->data + sizeof(u32));
@@ -208,8 +207,6 @@ int mwifiex_11h_handle_chanrpt_ready(struct mwifiex_private *priv,
return -1;
}
- evt_buf = (void *)&rpt_event->tlvbuf;
-
while (event_len >= sizeof(struct mwifiex_ie_types_header)) {
rpt = (void *)&rpt_event->tlvbuf;
tlv_len = le16_to_cpu(rpt->header.len);
@@ -231,7 +228,6 @@ int mwifiex_11h_handle_chanrpt_ready(struct mwifiex_private *priv,
break;
}
- evt_buf += (tlv_len + sizeof(rpt->header));
event_len -= (tlv_len + sizeof(rpt->header));
}
--
2.27.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] mwifiex: remove unused evt_buf variable
2023-03-29 13:14 [PATCH] mwifiex: remove unused evt_buf variable Tom Rix
@ 2023-03-29 13:44 ` Simon Horman
2023-03-29 16:16 ` Kalle Valo
2023-03-31 14:54 ` wifi: " Kalle Valo
2 siblings, 0 replies; 4+ messages in thread
From: Simon Horman @ 2023-03-29 13:44 UTC (permalink / raw)
To: Tom Rix
Cc: amitkarwar, ganapathi017, sharvari.harisangam, huxinming820,
kvalo, davem, edumazet, kuba, pabeni, nathan, ndesaulniers,
linux-wireless, netdev, linux-kernel, llvm
On Wed, Mar 29, 2023 at 09:14:44AM -0400, Tom Rix wrote:
> clang with W=1 reports
> drivers/net/wireless/marvell/mwifiex/11h.c:198:6: error: variable
> 'evt_buf' set but not used [-Werror,-Wunused-but-set-variable]
> u8 *evt_buf;
> ^
> This variable is not used so remove it.
>
> Signed-off-by: Tom Rix <trix@redhat.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mwifiex: remove unused evt_buf variable
2023-03-29 13:14 [PATCH] mwifiex: remove unused evt_buf variable Tom Rix
2023-03-29 13:44 ` Simon Horman
@ 2023-03-29 16:16 ` Kalle Valo
2023-03-31 14:54 ` wifi: " Kalle Valo
2 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2023-03-29 16:16 UTC (permalink / raw)
To: Tom Rix
Cc: amitkarwar, ganapathi017, sharvari.harisangam, huxinming820,
davem, edumazet, kuba, pabeni, nathan, ndesaulniers,
linux-wireless, netdev, linux-kernel, llvm
Tom Rix <trix@redhat.com> writes:
> clang with W=1 reports
> drivers/net/wireless/marvell/mwifiex/11h.c:198:6: error: variable
> 'evt_buf' set but not used [-Werror,-Wunused-but-set-variable]
> u8 *evt_buf;
> ^
> This variable is not used so remove it.
>
> Signed-off-by: Tom Rix <trix@redhat.com>
There should be "wifi:" in title, but I can add that during commit.
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: wifi: mwifiex: remove unused evt_buf variable
2023-03-29 13:14 [PATCH] mwifiex: remove unused evt_buf variable Tom Rix
2023-03-29 13:44 ` Simon Horman
2023-03-29 16:16 ` Kalle Valo
@ 2023-03-31 14:54 ` Kalle Valo
2 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2023-03-31 14:54 UTC (permalink / raw)
To: Tom Rix
Cc: amitkarwar, ganapathi017, sharvari.harisangam, huxinming820,
davem, edumazet, kuba, pabeni, nathan, ndesaulniers,
linux-wireless, netdev, linux-kernel, llvm, Tom Rix
Tom Rix <trix@redhat.com> wrote:
> clang with W=1 reports
> drivers/net/wireless/marvell/mwifiex/11h.c:198:6: error: variable
> 'evt_buf' set but not used [-Werror,-Wunused-but-set-variable]
> u8 *evt_buf;
> ^
> This variable is not used so remove it.
>
> Signed-off-by: Tom Rix <trix@redhat.com>
> Reviewed-by: Simon Horman <simon.horman@corigine.com>
Patch applied to wireless-next.git, thanks.
074d0a1ae1fe wifi: mwifiex: remove unused evt_buf variable
--
https://patchwork.kernel.org/project/linux-wireless/patch/20230329131444.1809018-1-trix@redhat.com/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-03-31 14:55 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-29 13:14 [PATCH] mwifiex: remove unused evt_buf variable Tom Rix
2023-03-29 13:44 ` Simon Horman
2023-03-29 16:16 ` Kalle Valo
2023-03-31 14:54 ` wifi: " Kalle Valo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).