git: e19bdeccc89a - stable/13 - Split out pmap_map_delete on arm64
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 25 Sep 2023 11:00:50 UTC
The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=e19bdeccc89a76727ddb56c9c2dbfc66daf9003a commit e19bdeccc89a76727ddb56c9c2dbfc66daf9003a Author: Andrew Turner <andrew@FreeBSD.org> AuthorDate: 2023-04-28 10:54:19 +0000 Commit: Andrew Turner <andrew@FreeBSD.org> CommitDate: 2023-09-25 08:41:16 +0000 Split out pmap_map_delete on arm64 This will be used when supporting some extensions, e.g. Branch Target Identification (BTI). Sponsored by: Arm Ltd (cherry picked from commit 020edaea2ab05c9cea7d83872f28a4e5e65407e2) --- sys/arm64/arm64/pmap.c | 12 ++++++++++++ sys/arm64/include/pmap.h | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c index edd34bcd5e68..037f1d5a805f 100644 --- a/sys/arm64/arm64/pmap.c +++ b/sys/arm64/arm64/pmap.c @@ -3294,6 +3294,18 @@ pmap_remove(pmap_t pmap, vm_offset_t sva, vm_offset_t eva) vm_page_free_pages_toq(&free, true); } +/* + * Remove the given range of addresses as part of a logical unmap + * operation. This has the effect of calling pmap_remove(), but + * also clears any metadata that should persist for the lifetime + * of a logical mapping. + */ +void +pmap_map_delete(pmap_t pmap, vm_offset_t sva, vm_offset_t eva) +{ + pmap_remove(pmap, sva, eva); +} + /* * Routine: pmap_remove_all * Function: diff --git a/sys/arm64/include/pmap.h b/sys/arm64/include/pmap.h index 95e43eada9cc..7305b8d32e87 100644 --- a/sys/arm64/include/pmap.h +++ b/sys/arm64/include/pmap.h @@ -177,7 +177,7 @@ int pmap_pinit_stage(pmap_t, enum pmap_stage, int); bool pmap_ps_enabled(pmap_t pmap); uint64_t pmap_to_ttbr0(pmap_t pmap); void pmap_disable_promotion(vm_offset_t sva, vm_size_t size); -#define pmap_map_delete(pmap, sva, eva) pmap_remove(pmap, sva, eva) +void pmap_map_delete(pmap_t, vm_offset_t, vm_offset_t); void *pmap_mapdev(vm_offset_t, vm_size_t); void *pmap_mapbios(vm_paddr_t, vm_size_t);