mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] x86/mm: fix "prev_pud" set but not used
@ 2019-02-28 21:32 Qian Cai
  0 siblings, 0 replies; only message in thread
From: Qian Cai @ 2019-02-28 21:32 UTC (permalink / raw)
  To: dave.hansen, luto, peterz
  Cc: aryabinin, tglx, mingo, bp, hpa, x86, linux-kernel, Qian Cai

The commit 04b67022fb6d ("x86/mm/dump_pagetables: Speed up page tables
dump for CONFIG_KASAN=y") removed pud_already_checked() but left a
unused variable.

arch/x86/mm/dump_pagetables.c: In function 'walk_pud_level':
arch/x86/mm/dump_pagetables.c:447:9: warning: variable 'prev_pud' set
but not used [-Wunused-but-set-variable]
  pud_t *prev_pud = NULL;
         ^~~~~~~~

Signed-off-by: Qian Cai <cai@lca.pw>
---
 arch/x86/mm/dump_pagetables.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/arch/x86/mm/dump_pagetables.c b/arch/x86/mm/dump_pagetables.c
index e3cdc85ce5b6..ee8f8ab46941 100644
--- a/arch/x86/mm/dump_pagetables.c
+++ b/arch/x86/mm/dump_pagetables.c
@@ -444,7 +444,6 @@ static void walk_pud_level(struct seq_file *m, struct pg_state *st, p4d_t addr,
 	int i;
 	pud_t *start, *pud_start;
 	pgprotval_t prot, eff;
-	pud_t *prev_pud = NULL;
 
 	pud_start = start = (pud_t *)p4d_page_vaddr(addr);
 
@@ -462,7 +461,6 @@ static void walk_pud_level(struct seq_file *m, struct pg_state *st, p4d_t addr,
 		} else
 			note_page(m, st, __pgprot(0), 0, 3);
 
-		prev_pud = start;
 		start++;
 	}
 }
-- 
2.17.2 (Apple Git-113)


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-02-28 21:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-28 21:32 [PATCH] x86/mm: fix "prev_pud" set but not used Qian Cai

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®