git: e8997a4e44c7 - main - arm64: Use sysinsn.h to generate tlbi instructions
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 09 Oct 2026 12:07:55 UTC
The branch main has been updated by andrew:
URL: https://cgit.FreeBSD.org/src/commit/?id=e8997a4e44c7729e6013745cb6590d2ec3691175
commit e8997a4e44c7729e6013745cb6590d2ec3691175
Author: Andrew Turner <andrew@FreeBSD.org>
AuthorDate: 2026-10-09 11:55:06 +0000
Commit: Andrew Turner <andrew@FreeBSD.org>
CommitDate: 2026-10-09 11:55:06 +0000
arm64: Use sysinsn.h to generate tlbi instructions
Some toolchains may not understand the .arch_extension.
Reviewed by: jhb
Sponsored by: Arm Ltd
Differential Revision: https://reviews.freebsd.org/D59148
---
sys/arm64/arm64/pmap.c | 17 +++++------------
1 file changed, 5 insertions(+), 12 deletions(-)
diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c
index 97cbb92d6d43..d20c08412c71 100644
--- a/sys/arm64/arm64/pmap.c
+++ b/sys/arm64/arm64/pmap.c
@@ -154,6 +154,7 @@
#include <machine/md_var.h>
#include <machine/pcb.h>
#include <machine/rsi.h>
+#include <machine/sysinsn.h>
#ifdef NUMA
#define PMAP_MEMDOM MAXMEMDOM
@@ -2103,26 +2104,18 @@ static __inline void
pmap_s1_invalidate_range_kernel(uint64_t r, bool final_only)
{
if (final_only)
- __asm __volatile(".arch_extension tlb-rmi \n"
- "tlbi rvaale1is, %0 \n"
- ".arch_extension notlb-rmi" : : "r" (r));
+ tlbi_rvaale1is(r);
else
- __asm __volatile(".arch_extension tlb-rmi \n"
- "tlbi rvaae1is, %0 \n"
- ".arch_extension notlb-rmi" : : "r" (r));
+ tlbi_rvaae1is(r);
}
static __inline void
pmap_s1_invalidate_range_user(uint64_t r, bool final_only)
{
if (final_only)
- __asm __volatile(".arch_extension tlb-rmi \n"
- "tlbi rvale1is, %0 \n"
- ".arch_extension notlb-rmi" : : "r" (r));
+ tlbi_rvale1is(r);
else
- __asm __volatile(".arch_extension tlb-rmi \n"
- "tlbi rvae1is, %0 \n"
- ".arch_extension notlb-rmi" : : "r" (r));
+ tlbi_rvae1is(r);
}
/*