Re: [RFC v2 3/6] cpus: extract out kvm-specific code to accel/kvm

2020-07-08 Thread Paolo Bonzini
On 08/07/20 09:40, Claudio Fontana wrote: > Ciao Paolo, > > On 7/7/20 7:01 PM, Paolo Bonzini wrote: >> On 07/07/20 15:58, Claudio Fontana wrote: >>> +static void kvm_kick_vcpu_thread(CPUState *cpu) >>> +{ >>> +cpus_kick_thread(cpu); >>> +} >>> + >> >> I would just use cpus_kick_thread instead

Re: [RFC v2 3/6] cpus: extract out kvm-specific code to accel/kvm

2020-07-08 Thread Claudio Fontana
Ciao Paolo, On 7/7/20 7:01 PM, Paolo Bonzini wrote: > On 07/07/20 15:58, Claudio Fontana wrote: >> +static void kvm_kick_vcpu_thread(CPUState *cpu) >> +{ >> +cpus_kick_thread(cpu); >> +} >> + > > I would just use cpus_kick_thread instead of wrapping it (and likewise Here I left the common co

Re: [RFC v2 3/6] cpus: extract out kvm-specific code to accel/kvm

2020-07-07 Thread Paolo Bonzini
On 07/07/20 15:58, Claudio Fontana wrote: > +static void kvm_kick_vcpu_thread(CPUState *cpu) > +{ > +cpus_kick_thread(cpu); > +} > + I would just use cpus_kick_thread instead of wrapping it (and likewise would provide a global function for noop synchronization). start_vcpu_thread is also a ca

[RFC v2 3/6] cpus: extract out kvm-specific code to accel/kvm

2020-07-07 Thread Claudio Fontana
register a "CpusAccel" interface for KVM as well. Signed-off-by: Claudio Fontana --- accel/kvm/Makefile.objs | 2 ++ accel/kvm/kvm-all.c | 14 +++- accel/kvm/kvm-cpus.c| 94 + accel/kvm/kvm-cpus.h| 17 + accel/stubs/kvm-stu