summaryrefslogtreecommitdiff
path: root/sys/include/arch
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2024-06-04 22:13:30 -0400
committerIan Moffett <ian@osmora.org>2024-06-04 22:15:54 -0400
commit955d6a381f53c234ce1f4d52aa57f183ed9a6e65 (patch)
treea2525bfe5898683b983b82c2bbda693e609e5152 /sys/include/arch
parent31e9919ced2c577e601d17ec02a3d7886f793469 (diff)
kernel/amd64: Support IBRS
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'sys/include/arch')
-rw-r--r--sys/include/arch/amd64/msr.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/include/arch/amd64/msr.h b/sys/include/arch/amd64/msr.h
index bc0dbcb..6ad95f1 100644
--- a/sys/include/arch/amd64/msr.h
+++ b/sys/include/arch/amd64/msr.h
@@ -33,6 +33,7 @@
#define IA32_SPEC_CTL 0x00000048
#define IA32_KERNEL_GS_BASE 0xC0000102
+#if !defined(__ASSEMBLER__)
static inline uint64_t
rdmsr(uint32_t msr_addr)
{
@@ -60,4 +61,5 @@ wrmsr(uint32_t msr_addr, uint64_t value)
);
}
+#endif /* !__ASSEMBLER__ */
#endif /* !_MACHINE_MSR_H_ */