* [PATCH] iwlegacy: remove redundant variable len
@ 2022-11-04 13:50 Colin Ian King
2022-11-04 17:32 ` Kalle Valo
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Colin Ian King @ 2022-11-04 13:50 UTC (permalink / raw)
To: Stanislaw Gruszka, Kalle Valo, David S . Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni, linux-wireless, netdev
Cc: kernel-janitors, linux-kernel
Variable len is being assigned and modified but it is never
used. The variable is redundant and can be removed.
Cleans up clang scan build warning:
warning: variable 'len' set but not used [-Wunused-but-set-variable]
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
drivers/net/wireless/intel/iwlegacy/3945-mac.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/drivers/net/wireless/intel/iwlegacy/3945-mac.c b/drivers/net/wireless/intel/iwlegacy/3945-mac.c
index 7352d5b2095f..429952871976 100644
--- a/drivers/net/wireless/intel/iwlegacy/3945-mac.c
+++ b/drivers/net/wireless/intel/iwlegacy/3945-mac.c
@@ -1202,8 +1202,6 @@ il3945_rx_handle(struct il_priv *il)
D_RX("r = %d, i = %d\n", r, i);
while (i != r) {
- int len;
-
rxb = rxq->queue[i];
/* If an RXB doesn't have a Rx queue slot associated with it,
@@ -1217,10 +1215,6 @@ il3945_rx_handle(struct il_priv *il)
PAGE_SIZE << il->hw_params.rx_page_order,
DMA_FROM_DEVICE);
pkt = rxb_addr(rxb);
-
- len = le32_to_cpu(pkt->len_n_flags) & IL_RX_FRAME_SIZE_MSK;
- len += sizeof(u32); /* account for status word */
-
reclaim = il_need_reclaim(il, pkt);
/* Based on type of command response or notification,
--
2.38.1
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [PATCH] iwlegacy: remove redundant variable len
2022-11-04 13:50 [PATCH] iwlegacy: remove redundant variable len Colin Ian King
@ 2022-11-04 17:32 ` Kalle Valo
2022-11-04 17:34 ` Colin King (gmail)
2022-11-04 18:58 ` Stanislaw Gruszka
2022-11-08 7:40 ` wifi: " Kalle Valo
2 siblings, 1 reply; 5+ messages in thread
From: Kalle Valo @ 2022-11-04 17:32 UTC (permalink / raw)
To: Colin Ian King
Cc: Stanislaw Gruszka, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, linux-wireless, netdev, kernel-janitors,
linux-kernel
Colin Ian King <colin.i.king@gmail.com> writes:
> Variable len is being assigned and modified but it is never
> used. The variable is redundant and can be removed.
>
> Cleans up clang scan build warning:
> warning: variable 'len' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
For future wireless patches please add "wifi: " to the subject. I can
edit the subject during commit so no need to resend.
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] iwlegacy: remove redundant variable len
2022-11-04 17:32 ` Kalle Valo
@ 2022-11-04 17:34 ` Colin King (gmail)
0 siblings, 0 replies; 5+ messages in thread
From: Colin King (gmail) @ 2022-11-04 17:34 UTC (permalink / raw)
To: Kalle Valo
Cc: Stanislaw Gruszka, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, linux-wireless, netdev, kernel-janitors,
linux-kernel
On 04/11/2022 17:32, Kalle Valo wrote:
> Colin Ian King <colin.i.king@gmail.com> writes:
>
>> Variable len is being assigned and modified but it is never
>> used. The variable is redundant and can be removed.
>>
>> Cleans up clang scan build warning:
>> warning: variable 'len' set but not used [-Wunused-but-set-variable]
>>
>> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
>
> For future wireless patches please add "wifi: " to the subject. I can
> edit the subject during commit so no need to resend.
>
OK, will try to remember to do that. Thanks for handling the $SUBJECT
Colin
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] iwlegacy: remove redundant variable len
2022-11-04 13:50 [PATCH] iwlegacy: remove redundant variable len Colin Ian King
2022-11-04 17:32 ` Kalle Valo
@ 2022-11-04 18:58 ` Stanislaw Gruszka
2022-11-08 7:40 ` wifi: " Kalle Valo
2 siblings, 0 replies; 5+ messages in thread
From: Stanislaw Gruszka @ 2022-11-04 18:58 UTC (permalink / raw)
To: Colin Ian King
Cc: Kalle Valo, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, linux-wireless, netdev, kernel-janitors,
linux-kernel
On Fri, Nov 04, 2022 at 01:50:36PM +0000, Colin Ian King wrote:
> Variable len is being assigned and modified but it is never
> used. The variable is redundant and can be removed.
>
> Cleans up clang scan build warning:
> warning: variable 'len' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Acked-by: Stanislaw Gruszka <stf_xl@wp.pl>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: wifi: iwlegacy: remove redundant variable len
2022-11-04 13:50 [PATCH] iwlegacy: remove redundant variable len Colin Ian King
2022-11-04 17:32 ` Kalle Valo
2022-11-04 18:58 ` Stanislaw Gruszka
@ 2022-11-08 7:40 ` Kalle Valo
2 siblings, 0 replies; 5+ messages in thread
From: Kalle Valo @ 2022-11-08 7:40 UTC (permalink / raw)
To: Colin Ian King
Cc: Stanislaw Gruszka, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, linux-wireless, netdev, kernel-janitors,
linux-kernel
Colin Ian King <colin.i.king@gmail.com> wrote:
> Variable len is being assigned and modified but it is never
> used. The variable is redundant and can be removed.
>
> Cleans up clang scan build warning:
> warning: variable 'len' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
> Acked-by: Stanislaw Gruszka <stf_xl@wp.pl>
Patch applied to wireless-next.git, thanks.
9db485ce098f wifi: iwlegacy: remove redundant variable len
--
https://patchwork.kernel.org/project/linux-wireless/patch/20221104135036.225628-1-colin.i.king@gmail.com/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-11-08 7:41 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-04 13:50 [PATCH] iwlegacy: remove redundant variable len Colin Ian King
2022-11-04 17:32 ` Kalle Valo
2022-11-04 17:34 ` Colin King (gmail)
2022-11-04 18:58 ` Stanislaw Gruszka
2022-11-08 7:40 ` 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).