diff options
author | Olivier Houchard <cognet@FreeBSD.org> | 2018-05-17 22:40:22 +0000 |
---|---|---|
committer | Olivier Houchard <cognet@FreeBSD.org> | 2018-05-17 22:40:22 +0000 |
commit | 8b2ec5a3a1dfab745cfd95bea014da57e4a65f3c (patch) | |
tree | 9746765a482718ef945ae701f433234d90e02d29 /sys/arm64 | |
parent | 654a792922d2d715dbf179162c0f8e589da11a4b (diff) | |
download | src-8b2ec5a3a1dfab745cfd95bea014da57e4a65f3c.tar.gz src-8b2ec5a3a1dfab745cfd95bea014da57e4a65f3c.zip |
In pmap_get_tables(), check that the L2 is indeed a table before attempting
to get the l3.
Notes
Notes:
svn path=/head/; revision=333772
Diffstat (limited to 'sys/arm64')
-rw-r--r-- | sys/arm64/arm64/pmap.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c index 34037efdeace..e25e2642353d 100644 --- a/sys/arm64/arm64/pmap.c +++ b/sys/arm64/arm64/pmap.c @@ -487,6 +487,9 @@ pmap_get_tables(pmap_t pmap, vm_offset_t va, pd_entry_t **l0, pd_entry_t **l1, return (true); } + if ((pmap_load(l2p) & ATTR_DESCR_MASK) != L2_TABLE) + return (false); + *l3 = pmap_l2_to_l3(l2p, va); return (true); |