]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
arm64: mm: fix p?d_leaf()
authorMuchun Song <songmuchun@bytedance.com>
Fri, 22 Apr 2022 06:00:33 +0000 (14:00 +0800)
committerStefan Bader <stefan.bader@canonical.com>
Wed, 22 Jun 2022 12:22:12 +0000 (14:22 +0200)
commitc14d94d2b85f1c8b96099764700c14b9ea9d28e3
tree2b16146df25b8299eab2af5c7298cbfce84c46c2
parent3b21fc811a6d610705ac2826852cf162ec37f3ce
arm64: mm: fix p?d_leaf()

BugLink: https://bugs.launchpad.net/bugs/1972905
[ Upstream commit 23bc8f69f0eceecbb87c3801d2e48827d2dca92b ]

The pmd_leaf() is used to test a leaf mapped PMD, however, it misses
the PROT_NONE mapped PMD on arm64.  Fix it.  A real world issue [1]
caused by this was reported by Qian Cai. Also fix pud_leaf().

Link: https://patchwork.kernel.org/comment/24798260/
Fixes: 8aa82df3c123 ("arm64: mm: add p?d_leaf() definitions")
Reported-by: Qian Cai <quic_qiancai@quicinc.com>
Signed-off-by: Muchun Song <songmuchun@bytedance.com>
Link: https://lore.kernel.org/r/20220422060033.48711-1-songmuchun@bytedance.com
Signed-off-by: Will Deacon <will@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
arch/arm64/include/asm/pgtable.h