* [PATCH] x86/amd_nb: remove redundant initialization of variable i
@ 2022-07-04 19:11 Colin Ian King
0 siblings, 0 replies; only message in thread
From: Colin Ian King @ 2022-07-04 19:11 UTC (permalink / raw)
To: David Airlie; +Cc: kernel-janitors, linux-kernel
Variable i is initialized with a value and then re-assigned with
the same value in the following for-loop. The first initialization
is redundant and can be removed.
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
---
drivers/char/agp/amd64-agp.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/char/agp/amd64-agp.c b/drivers/char/agp/amd64-agp.c
index 84a4aa9312cf..c7bf2c4bc0b0 100644
--- a/drivers/char/agp/amd64-agp.c
+++ b/drivers/char/agp/amd64-agp.c
@@ -333,7 +333,6 @@ static int cache_nbs(struct pci_dev *pdev, u32 cap_ptr)
if (!amd_nb_has_feature(AMD_NB_GART))
return -ENODEV;
- i = 0;
for (i = 0; i < amd_nb_num(); i++) {
struct pci_dev *dev = node_to_amd_nb(i)->misc;
if (fix_northbridge(dev, pdev, cap_ptr) < 0) {
--
2.35.3
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-07-04 19:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-04 19:11 [PATCH] x86/amd_nb: remove redundant initialization of variable i Colin Ian King
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®