[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240704043132.28501-5-osalvador@suse.de>
Date: Thu, 4 Jul 2024 06:30:51 +0200
From: Oscar Salvador <osalvador@...e.de>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: linux-kernel@...r.kernel.org,
linux-mm@...ck.org,
Peter Xu <peterx@...hat.com>,
Muchun Song <muchun.song@...ux.dev>,
David Hildenbrand <david@...hat.com>,
SeongJae Park <sj@...nel.org>,
Miaohe Lin <linmiaohe@...wei.com>,
Michal Hocko <mhocko@...e.com>,
Matthew Wilcox <willy@...radead.org>,
Christophe Leroy <christophe.leroy@...roup.eu>,
Oscar Salvador <osalvador@...e.de>
Subject: [PATCH 04/45] mm/pagewalk: Only call pud_entry when we have a pud leaf
Check first whether the pud is leaf one before trying to call pud_entry.
Signed-off-by: Oscar Salvador <osalvador@...e.de>
---
mm/pagewalk.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/pagewalk.c b/mm/pagewalk.c
index eba705def9a0..d93e77411482 100644
--- a/mm/pagewalk.c
+++ b/mm/pagewalk.c
@@ -155,7 +155,7 @@ static int walk_pud_range(p4d_t *p4d, unsigned long addr, unsigned long end,
walk->action = ACTION_SUBTREE;
- if (ops->pud_entry)
+ if (ops->pud_entry && pud_leaf(*pud))
err = ops->pud_entry(pud, addr, next, walk);
if (err)
break;
--
2.26.2
Powered by blists - more mailing lists