Stub function loongarch_get_addr_from_tlb() is added if option CONFIG_TCG is not enabled, so this function can be called in KVM only mode.
Signed-off-by: Bibo Mao <maob...@loongson.cn> --- target/loongarch/cpu_helper.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/target/loongarch/cpu_helper.c b/target/loongarch/cpu_helper.c index 8e0c1b3764..111a57314f 100644 --- a/target/loongarch/cpu_helper.c +++ b/target/loongarch/cpu_helper.c @@ -156,7 +156,16 @@ static int loongarch_get_addr_from_tlb(CPULoongArchState *env, hwaddr *physical, return TLBRET_NOMATCH; } +#else +static int loongarch_get_addr_from_tlb(CPULoongArchState *env, hwaddr *physical, + int *prot, target_ulong address, + MMUAccessType access_type, int mmu_idx) +{ + return TLBRET_NOMATCH; +} +#endif +#ifdef CONFIG_TCG void get_dir_base_width(CPULoongArchState *env, uint64_t *dir_base, uint64_t *dir_width, target_ulong level) { -- 2.39.3