Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F102737920
D45160.id138517.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D45160.id138517.diff
View Options
diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c
--- a/sys/arm64/arm64/pmap.c
+++ b/sys/arm64/arm64/pmap.c
@@ -5662,6 +5662,19 @@
}
}
l3p = (pt_entry_t *)PHYS_TO_DMAP(VM_PAGE_TO_PHYS(*ml3p));
+
+have_l3p:
+ /*
+ * If bti is not the same for the whole L3C range, return
+ * failure and let vm_fault() cope. Check after L3 allocation,
+ * since it could sleep.
+ */
+ if (!pmap_bti_same(pmap, va, va + L3C_SIZE)) {
+ (*ml3p)->ref_count -= L3C_ENTRIES - 1;
+ pmap_abort_ptp(pmap, va, *ml3p);
+ *ml3p = NULL;
+ return (KERN_PROTECTION_FAILURE);
+ }
} else {
*ml3p = NULL;
@@ -5684,22 +5697,8 @@
pmap_load(pde)));
}
}
-have_l3p:
l3p = &l3p[pmap_l3_index(va)];
- /*
- * If bti is not the same for the whole L3C range, return failure
- * and let vm_fault() cope. Check after L3 allocation, since
- * it could sleep.
- */
- if (!pmap_bti_same(pmap, va, va + L3C_SIZE)) {
- KASSERT(*ml3p != NULL, ("pmap_enter_l3c: missing L3 PTP"));
- (*ml3p)->ref_count -= L3C_ENTRIES - 1;
- pmap_abort_ptp(pmap, va, *ml3p);
- *ml3p = NULL;
- return (KERN_PROTECTION_FAILURE);
- }
-
/*
* If there are existing mappings, either abort or remove them.
*/
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Nov 17, 1:24 PM (4 h, 51 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14678906
Default Alt Text
D45160.id138517.diff (1 KB)
Attached To
Mode
D45160: arm64_pmap: narrow scope of bti_same test
Attached
Detach File
Event Timeline
Log In to Comment