aboutsummaryrefslogtreecommitdiff
path: root/target/loongarch
diff options
context:
space:
mode:
Diffstat (limited to 'target/loongarch')
-rw-r--r--target/loongarch/cpu.c2
-rw-r--r--target/loongarch/cpu.h10
2 files changed, 1 insertions, 11 deletions
diff --git a/target/loongarch/cpu.c b/target/loongarch/cpu.c
index 49ced98..7dc50bf 100644
--- a/target/loongarch/cpu.c
+++ b/target/loongarch/cpu.c
@@ -375,7 +375,7 @@ static bool loongarch_cpu_has_work(CPUState *cs)
#endif
}
-int loongarch_cpu_mmu_index(CPUState *cs, bool ifetch)
+static int loongarch_cpu_mmu_index(CPUState *cs, bool ifetch)
{
CPULoongArchState *env = cpu_env(cs);
diff --git a/target/loongarch/cpu.h b/target/loongarch/cpu.h
index 47fd110..ec37579 100644
--- a/target/loongarch/cpu.h
+++ b/target/loongarch/cpu.h
@@ -408,16 +408,6 @@ struct LoongArchCPUClass {
#define MMU_USER_IDX MMU_PLV_USER
#define MMU_DA_IDX 4
-int loongarch_cpu_mmu_index(CPUState *cs, bool ifetch);
-static inline int cpu_mmu_index(CPULoongArchState *env, bool ifetch)
-{
-#ifdef CONFIG_USER_ONLY
- return MMU_USER_IDX;
-#else
- return loongarch_cpu_mmu_index(env_cpu(env), ifetch);
-#endif
-}
-
static inline bool is_la64(CPULoongArchState *env)
{
return FIELD_EX32(env->cpucfg[1], CPUCFG1, ARCH) == CPUCFG1_ARCH_LA64;