[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 13/14] bsd-user: Make compile for non-linux user-mode stuff
From: |
Warner Losh |
Subject: |
[PATCH 13/14] bsd-user: Make compile for non-linux user-mode stuff |
Date: |
Mon, 22 Jul 2024 15:43:12 -0600 |
We include the files that define PR_MTE_TCF_SHIFT only on Linux, but use
them unconditionally. Restrict its use to Linux-only.
Signed-off-by: Warner Losh <imp@bsdimp.com>
---
target/arm/gdbstub64.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/target/arm/gdbstub64.c b/target/arm/gdbstub64.c
index 2e2bc2700b8..6dc81aecb2a 100644
--- a/target/arm/gdbstub64.c
+++ b/target/arm/gdbstub64.c
@@ -404,6 +404,7 @@ int aarch64_gdb_get_tag_ctl_reg(CPUState *cs, GByteArray
*buf, int reg)
int aarch64_gdb_set_tag_ctl_reg(CPUState *cs, uint8_t *buf, int reg)
{
+#if defined(CONFIG_LINUX)
ARMCPU *cpu = ARM_CPU(cs);
CPUARMState *env = &cpu->env;
@@ -425,6 +426,9 @@ int aarch64_gdb_set_tag_ctl_reg(CPUState *cs, uint8_t *buf,
int reg)
arm_set_mte_tcf0(env, tcf);
return 1;
+#else
+ return 0;
+#endif
}
static void handle_q_memtag(GArray *params, void *user_ctx)
--
2.45.1