From: Rolf Eike Beer Date: Wed, 24 Aug 2022 11:00:11 +0000 (+0200) Subject: mm: pagewalk: add back missing variable initializations X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=139f34742fb7c95bb95f0ff5867cb5549a5870a1;p=users%2Fjedix%2Flinux-maple.git mm: pagewalk: add back missing variable initializations These initializations accidentially got lost during refactoring. The first one can't actually be used without initialization, because walk_p4d_range() is only called when one of the 4 callbacks is set, but relying on this seems fragile. Link: https://lkml.kernel.org/r/2123960.ggj6I0NvhH@mobilepool36.emlix.com Reported-by: Linux Kernel Functional Testing Reported-by: kernel test robot Reported-by: Dan Carpenter Signed-off-by: Rolf Eike Beer Signed-off-by: Andrew Morton --- diff --git a/mm/pagewalk.c b/mm/pagewalk.c index 818e00384d39..ed12a6c434a9 100644 --- a/mm/pagewalk.c +++ b/mm/pagewalk.c @@ -264,7 +264,7 @@ static int walk_pgd_range(unsigned long addr, unsigned long end, else pgd = pgd_offset(walk->mm, addr); do { - int err; + int err = 0; next = pgd_addr_end(addr, end); if (pgd_none_or_clear_bad(pgd)) {