Re: [Qemu-devel] [PATCH v7 6/6] Add gicversion option to virt machine

2015-08-03 Thread Peter Maydell
On 3 August 2015 at 12:41, Shlomo Pongratz wrote: > > > On Monday, August 3, 2015, Peter Maydell wrote: >> I'm surprised we tell the CPU about the GIC pointer for the >> system register stuff -- I was expecting that we'd give the >> GIC a CPU pointer. (We could in theory implement some >> equival

Re: [Qemu-devel] [PATCH v7 6/6] Add gicversion option to virt machine

2015-08-03 Thread Shlomo Pongratz
On Monday, August 3, 2015, Peter Maydell wrote: > On 3 August 2015 at 08:19, Pavel Fedin > > wrote: > > Hello! > > > >> > gicdev = qdev_create(NULL, gictype); > >> > -qdev_prop_set_uint32(gicdev, "revision", 2); > >> > + > >> > +for (i = 0; i < vbi->smp_cpus; i++) { > >> > +

Re: [Qemu-devel] [PATCH v7 6/6] Add gicversion option to virt machine

2015-08-03 Thread Peter Maydell
On 3 August 2015 at 08:19, Pavel Fedin wrote: > Hello! > >> > gicdev = qdev_create(NULL, gictype); >> > -qdev_prop_set_uint32(gicdev, "revision", 2); >> > + >> > +for (i = 0; i < vbi->smp_cpus; i++) { >> > +CPUState *cpu = qemu_get_cpu(i); >> > +CPUARMState *env = cpu

Re: [Qemu-devel] [PATCH v7 6/6] Add gicversion option to virt machine

2015-08-03 Thread Pavel Fedin
Hello! > > gicdev = qdev_create(NULL, gictype); > > -qdev_prop_set_uint32(gicdev, "revision", 2); > > + > > +for (i = 0; i < vbi->smp_cpus; i++) { > > +CPUState *cpu = qemu_get_cpu(i); > > +CPUARMState *env = cpu->env_ptr; > > +env->nvic = gicdev; > > +} >

Re: [Qemu-devel] [PATCH v7 6/6] Add gicversion option to virt machine

2015-07-31 Thread Peter Maydell
On 24 July 2015 at 10:55, Pavel Fedin wrote: > Set kernel_irqchip_type according to value of the option and pass it > around where necessary. Instantiate devices and fdt nodes according > to the choice. > > max_cpus for virt machine increased to 64. GICv2 compatibility check > happens inside arm_g

[Qemu-devel] [PATCH v7 6/6] Add gicversion option to virt machine

2015-07-24 Thread Pavel Fedin
Set kernel_irqchip_type according to value of the option and pass it around where necessary. Instantiate devices and fdt nodes according to the choice. max_cpus for virt machine increased to 64. GICv2 compatibility check happens inside arm_gic_common_realize(). Signed-off-by: Pavel Fedin --- hw