Re: [PATCH v3 4/9] target/loongarch: Implement kvm get/set registers

2024-01-02 Thread gaosong
在 2023/12/28 下午4:40, Tianrui Zhao 写道: +static int kvm_loongarch_get_regs_fp(CPUState *cs) +{ +int ret, i; +struct kvm_fpu fpu; + +LoongArchCPU *cpu = LOONGARCH_CPU(cs); +CPULoongArchState *env = &cpu->env; + +ret = kvm_vcpu_ioctl(cs, KVM_GET_FPU, &fpu); +if (ret < 0) { +

Re: [PATCH v3 4/9] target/loongarch: Implement kvm get/set registers

2024-01-02 Thread gaosong
在 2023/12/28 下午4:40, Tianrui Zhao 写道: Implement kvm_arch_get/set_registers interfaces, many regs can be get/set in the function, such as core regs, csr regs, fpu regs, mp state, etc. Signed-off-by: Tianrui Zhao Signed-off-by: xianglai li --- meson.build | 1 + target/loo

[PATCH v3 4/9] target/loongarch: Implement kvm get/set registers

2023-12-28 Thread Tianrui Zhao
Implement kvm_arch_get/set_registers interfaces, many regs can be get/set in the function, such as core regs, csr regs, fpu regs, mp state, etc. Signed-off-by: Tianrui Zhao Signed-off-by: xianglai li --- meson.build | 1 + target/loongarch/cpu.c| 3 + target/loonga