Re: [Qemu-devel] [PATCH for-1.2 v5 14/14] pci: Tidy up PCI host bridges

2012-08-13 Thread Anthony Liguori
Andreas Färber afaer...@suse.de writes: Uglify the parent field to enforce QOM-style access via casts. Don't just typedef PCIHostState, either use it directly or embed it. Signed-off-by: Andreas Färber afaer...@suse.de --- hw/alpha_typhoon.c |2 +- hw/dec_pci.c |2 +-

Re: [Qemu-devel] [PATCH for-1.2 v5 14/14] pci: Tidy up PCI host bridges

2012-08-13 Thread Michael S. Tsirkin
On Thu, Aug 02, 2012 at 03:47:06AM +0200, Andreas Färber wrote: Uglify the parent field to enforce QOM-style access via casts. Don't just typedef PCIHostState, either use it directly or embed it. Signed-off-by: Andreas Färber afaer...@suse.de IMHO only one chunk from this patch should be

Re: [Qemu-devel] [PATCH for-1.2 v5 14/14] pci: Tidy up PCI host bridges

2012-08-13 Thread Andreas Färber
Am 13.08.2012 15:14, schrieb Anthony Liguori: Andreas Färber afaer...@suse.de writes: diff --git a/hw/spapr_pci.c b/hw/spapr_pci.c index df70cd2..8937030 100644 --- a/hw/spapr_pci.c +++ b/hw/spapr_pci.c @@ -36,16 +36,18 @@ static PCIDevice *find_dev(sPAPREnvironment *spapr,

Re: [Qemu-devel] [PATCH for-1.2 v5 14/14] pci: Tidy up PCI host bridges

2012-08-13 Thread Anthony Liguori
Michael S. Tsirkin m...@redhat.com writes: On Thu, Aug 02, 2012 at 03:47:06AM +0200, Andreas Färber wrote: Uglify the parent field to enforce QOM-style access via casts. Don't just typedef PCIHostState, either use it directly or embed it. Signed-off-by: Andreas Färber afaer...@suse.de

Re: [Qemu-devel] [PATCH for-1.2 v5 14/14] pci: Tidy up PCI host bridges

2012-08-13 Thread Mark Cave-Ayland
On 13/08/12 15:16, Anthony Liguori wrote: I understand what your objection is but it's unreasonable IMHO. The purpose of QOM is to bring consistency across large swaths of code in QEMU that have historically done things there own way. This means expressing concepts like inheritence and

Re: [Qemu-devel] [PATCH for-1.2 v5 14/14] pci: Tidy up PCI host bridges

2012-08-02 Thread Michael S. Tsirkin
On Thu, Aug 02, 2012 at 03:47:06AM +0200, Andreas Färber wrote: Uglify the parent field to enforce QOM-style access via casts. Don't just typedef PCIHostState, either use it directly or embed it. Signed-off-by: Andreas Färber afaer...@suse.de NAK I'd prefer to drop this one for now. ---

[Qemu-devel] [PATCH for-1.2 v5 14/14] pci: Tidy up PCI host bridges

2012-08-01 Thread Andreas Färber
Uglify the parent field to enforce QOM-style access via casts. Don't just typedef PCIHostState, either use it directly or embed it. Signed-off-by: Andreas Färber afaer...@suse.de --- hw/alpha_typhoon.c |2 +- hw/dec_pci.c |2 +- hw/grackle_pci.c |2 +- hw/gt64xxx.c |