On Wed, Apr 09, 2025 at 04:42:53PM +0200, Cornelia Huck wrote: > From: Eric Auger <eric.au...@redhat.com> > > Also add kvm add accessors for storing host features into idregs. > > Reviewed-by: Richard Henderson <richard.hender...@linaro.org> > Reviewed-by: Sebastian Ott <seb...@redhat.com> > Signed-off-by: Eric Auger <eric.au...@redhat.com> > Signed-off-by: Cornelia Huck <coh...@redhat.com> > --- > target/arm/cpu-features.h | 57 ++++++++++++++++++++------------------- > target/arm/cpu-sysregs.h | 4 +++ > target/arm/cpu.c | 10 +++---- > target/arm/cpu.h | 2 -- > target/arm/cpu64.c | 8 +++--- > target/arm/helper.c | 6 +++-- > target/arm/hvf/hvf.c | 3 ++- > target/arm/kvm.c | 30 ++++++++++++++++++--- > target/arm/tcg/cpu64.c | 44 ++++++++++++++++++------------ > 9 files changed, 101 insertions(+), 63 deletions(-)
> diff --git a/target/arm/cpu-sysregs.h b/target/arm/cpu-sysregs.h > index 7877a3b06a8e..e89a1105904c 100644 > --- a/target/arm/cpu-sysregs.h > +++ b/target/arm/cpu-sysregs.h > @@ -39,4 +39,8 @@ extern const uint32_t id_register_sysreg[NUM_ID_IDX]; > > int get_sysreg_idx(ARMSysRegs sysreg); > > +#ifdef CONFIG_KVM > +uint64_t idregs_sysreg_to_kvm_reg(ARMSysRegs sysreg); > +#endif This breaks the build when KVM is disabled, and/or not available on the build target architecture In file included from ../target/arm/cpu.h:35, from /var/home/berrange/src/virt/qemu/include/hw/arm/digic.h:21, from ../hw/arm/digic_boards.c:31: /var/home/berrange/src/virt/qemu/target/arm/cpu-sysregs.h:42:8: error: attempt to use poisoned ‘CONFIG_KVM’ 42 | #ifdef CONFIG_KVM | ^ In file included from /var/home/berrange/src/virt/qemu/include/exec/poison.h:7, from /var/home/berrange/src/virt/qemu/include/qemu/osdep.h:38, from ../hw/arm/digic_boards.c:26: ./config-poison.h:185:20: note: poisoned here 185 | #pragma GCC poison CONFIG_KVM | ^~~~~~~~~~ ninja: build stopped: subcommand failed. With regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|