Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-26 Thread Claudio Fontana
On 11/25/20 10:30 AM, Paolo Bonzini wrote: > On 25/11/20 10:21, Claudio Fontana wrote: >> Hi Paolo, >> >> in RFC v5 , module init for ACCEL_CPU is not conditional anymore, right? >> But the fact that its behavior depends on current_accel() still disqualifies >> it? >> It is called right after the

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-26 Thread Claudio Fontana
On 11/26/20 12:25 PM, Philippe Mathieu-Daudé wrote: > On 11/24/20 5:22 PM, Claudio Fontana wrote: >> apply this to the registration of the cpus accel interfaces, >> >> but this will be also in preparation for later use of this >> new module init step to also register per-accel x86 cpu type >> inter

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-26 Thread Philippe Mathieu-Daudé
On 11/24/20 5:22 PM, Claudio Fontana wrote: > apply this to the registration of the cpus accel interfaces, > > but this will be also in preparation for later use of this > new module init step to also register per-accel x86 cpu type > interfaces. > > Signed-off-by: Claudio Fontana > --- > accel

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-25 Thread Claudio Fontana
On 11/25/20 10:30 AM, Paolo Bonzini wrote: > On 25/11/20 10:21, Claudio Fontana wrote: >> Hi Paolo, >> >> in RFC v5 , module init for ACCEL_CPU is not conditional anymore, right? >> But the fact that its behavior depends on current_accel() still disqualifies >> it? >> It is called right after the

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-25 Thread Paolo Bonzini
On 25/11/20 10:21, Claudio Fontana wrote: Hi Paolo, in RFC v5 , module init for ACCEL_CPU is not conditional anymore, right? But the fact that its behavior depends on current_accel() still disqualifies it? It is called right after the accelerator is chosen and initialized in RFC v5, this still i

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-25 Thread Claudio Fontana
On 11/24/20 9:01 PM, Paolo Bonzini wrote: > On 24/11/20 20:08, Eduardo Habkost wrote: >>> Not a big advantage I agree, >>> I think however there is one, in using the existing framework that exists, >>> for the purposes that it was built for. >>> >>> As I understand it, the global module init frame

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-24 Thread Paolo Bonzini
On 24/11/20 20:08, Eduardo Habkost wrote: Not a big advantage I agree, I think however there is one, in using the existing framework that exists, for the purposes that it was built for. As I understand it, the global module init framework is supposed to mark the major initialization steps, and

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-24 Thread Eduardo Habkost
On Tue, Nov 24, 2020 at 07:29:50PM +0100, Claudio Fontana wrote: > On 11/24/20 6:08 PM, Eduardo Habkost wrote: > > On Tue, Nov 24, 2020 at 05:22:07PM +0100, Claudio Fontana wrote: > >> apply this to the registration of the cpus accel interfaces, > >> > >> but this will be also in preparation for la

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-24 Thread Claudio Fontana
On 11/24/20 6:08 PM, Eduardo Habkost wrote: > On Tue, Nov 24, 2020 at 05:22:07PM +0100, Claudio Fontana wrote: >> apply this to the registration of the cpus accel interfaces, >> >> but this will be also in preparation for later use of this >> new module init step to also register per-accel x86 cpu

Re: [RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-24 Thread Eduardo Habkost
On Tue, Nov 24, 2020 at 05:22:07PM +0100, Claudio Fontana wrote: > apply this to the registration of the cpus accel interfaces, > > but this will be also in preparation for later use of this > new module init step to also register per-accel x86 cpu type > interfaces. > > Signed-off-by: Claudio Fo

[RFC v5 09/12] module: introduce MODULE_INIT_ACCEL_CPU

2020-11-24 Thread Claudio Fontana
apply this to the registration of the cpus accel interfaces, but this will be also in preparation for later use of this new module init step to also register per-accel x86 cpu type interfaces. Signed-off-by: Claudio Fontana --- accel/kvm/kvm-all.c | 11 +-- accel/qtest/qtest.c