* Re: [PATCH -next] net: mvneta: Remove unused variables 'i'
2022-10-10 3:25 [PATCH -next] net: mvneta: Remove unused variables 'i' Chen Zhongjin
@ 2022-09-30 15:51 ` Jakub Kicinski
2022-10-08 1:59 ` Chen Zhongjin
0 siblings, 1 reply; 3+ messages in thread
From: Jakub Kicinski @ 2022-09-30 15:51 UTC (permalink / raw)
To: Chen Zhongjin
Cc: linux-kernel, netdev, thomas.petazzoni, davem, edumazet, pabeni
On Mon, 10 Oct 2022 11:25:06 +0800 Chen Zhongjin wrote:
> Reported by Clang [-Wunused-but-set-variable]
>
> 'commit cad5d847a093 ("net: mvneta: Fix the CPU choice in mvneta_percpu_elect")'
> This commit had changed the logic to elect CPU in mvneta_percpu_elect().
> Now the variable 'i' is not used in this function, so remove it.
Please fix the date on your system. Your patches are sent with the date
over a week in the future.
Please note that we have a 24h wait period so you need to wait at least
a day before you resend anything.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH -next] net: mvneta: Remove unused variables 'i'
2022-09-30 15:51 ` Jakub Kicinski
@ 2022-10-08 1:59 ` Chen Zhongjin
0 siblings, 0 replies; 3+ messages in thread
From: Chen Zhongjin @ 2022-10-08 1:59 UTC (permalink / raw)
To: Jakub Kicinski
Cc: linux-kernel, netdev, thomas.petazzoni, davem, edumazet, pabeni
On 2022/9/30 23:51, Jakub Kicinski wrote:
> On Mon, 10 Oct 2022 11:25:06 +0800 Chen Zhongjin wrote:
>> Reported by Clang [-Wunused-but-set-variable]
>>
>> 'commit cad5d847a093 ("net: mvneta: Fix the CPU choice in mvneta_percpu_elect")'
>> This commit had changed the logic to elect CPU in mvneta_percpu_elect().
>> Now the variable 'i' is not used in this function, so remove it.
> Please fix the date on your system. Your patches are sent with the date
> over a week in the future.
>
> Please note that we have a 24h wait period so you need to wait at least
> a day before you resend anything.
Sorry for late reply cuz I'm just back for work today.
Thanks for the tips. I'll fix the date problem and post it after 6.1-rc1.
Best,
Chen
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH -next] net: mvneta: Remove unused variables 'i'
@ 2022-10-10 3:25 Chen Zhongjin
2022-09-30 15:51 ` Jakub Kicinski
0 siblings, 1 reply; 3+ messages in thread
From: Chen Zhongjin @ 2022-10-10 3:25 UTC (permalink / raw)
To: linux-kernel, netdev
Cc: thomas.petazzoni, davem, edumazet, kuba, pabeni, chenzhongjin
Reported by Clang [-Wunused-but-set-variable]
'commit cad5d847a093 ("net: mvneta: Fix the CPU choice in mvneta_percpu_elect")'
This commit had changed the logic to elect CPU in mvneta_percpu_elect().
Now the variable 'i' is not used in this function, so remove it.
Signed-off-by: Chen Zhongjin <chenzhongjin@huawei.com>
---
drivers/net/ethernet/marvell/mvneta.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/net/ethernet/marvell/mvneta.c b/drivers/net/ethernet/marvell/mvneta.c
index 0caa2df87c04..11bec920177b 100644
--- a/drivers/net/ethernet/marvell/mvneta.c
+++ b/drivers/net/ethernet/marvell/mvneta.c
@@ -4266,7 +4266,7 @@ static void mvneta_mdio_remove(struct mvneta_port *pp)
*/
static void mvneta_percpu_elect(struct mvneta_port *pp)
{
- int elected_cpu = 0, max_cpu, cpu, i = 0;
+ int elected_cpu = 0, max_cpu, cpu;
/* Use the cpu associated to the rxq when it is online, in all
* the other cases, use the cpu 0 which can't be offline.
@@ -4306,8 +4306,6 @@ static void mvneta_percpu_elect(struct mvneta_port *pp)
*/
smp_call_function_single(cpu, mvneta_percpu_unmask_interrupt,
pp, true);
- i++;
-
}
};
--
2.33.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-10-08 1:59 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-10 3:25 [PATCH -next] net: mvneta: Remove unused variables 'i' Chen Zhongjin
2022-09-30 15:51 ` Jakub Kicinski
2022-10-08 1:59 ` Chen Zhongjin
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).