Re: [Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-02-01 Thread Jan Kiszka
On 2012-02-01 08:29, Paolo Bonzini wrote: > On 01/31/2012 09:49 PM, Anthony Liguori wrote: >>> >>> +DEFINE_PROP_HEX32("iobase", PCSpkState, iobase, -1), >>> +DEFINE_PROP_PTR("pit", PCSpkState, pit), >> >> Please don't introduce a pointer property here. They cannot be used in >> a

Re: [Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-01-31 Thread Paolo Bonzini
On 01/31/2012 09:49 PM, Anthony Liguori wrote: +DEFINE_PROP_HEX32("iobase", PCSpkState, iobase, -1), +DEFINE_PROP_PTR("pit", PCSpkState, pit), Please don't introduce a pointer property here. They cannot be used in a meaningful way in qdev. Why not register a link in instance

Re: [Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-01-31 Thread Anthony Liguori
On 01/31/2012 04:48 PM, Jan Kiszka wrote: On 2012-01-31 23:40, Anthony Liguori wrote: Why is what's in the tree not usable? Just don't do pcspk_init as a static inline (which is not that nice to do anyway) and you don't need to worry about the availability of an accessor. The current pattern

Re: [Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-01-31 Thread Jan Kiszka
On 2012-01-31 23:40, Anthony Liguori wrote: > On 01/31/2012 04:00 PM, Jan Kiszka wrote: >> On 2012-01-31 21:49, Anthony Liguori wrote: >>> On 01/31/2012 11:41 AM, Jan Kiszka wrote: Convert the PC speaker device to a qdev ISA model. Move the public interface to a dedicated header file at t

Re: [Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-01-31 Thread Anthony Liguori
On 01/31/2012 04:00 PM, Jan Kiszka wrote: On 2012-01-31 21:49, Anthony Liguori wrote: On 01/31/2012 11:41 AM, Jan Kiszka wrote: Convert the PC speaker device to a qdev ISA model. Move the public interface to a dedicated header file at this chance. Signed-off-by: Jan Kiszka Heh, I did this to

Re: [Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-01-31 Thread Jan Kiszka
On 2012-01-31 21:49, Anthony Liguori wrote: > On 01/31/2012 11:41 AM, Jan Kiszka wrote: >> Convert the PC speaker device to a qdev ISA model. Move the public >> interface to a dedicated header file at this chance. >> >> Signed-off-by: Jan Kiszka > > Heh, I did this too more or less the same way.

Re: [Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-01-31 Thread Anthony Liguori
On 01/31/2012 11:41 AM, Jan Kiszka wrote: Convert the PC speaker device to a qdev ISA model. Move the public interface to a dedicated header file at this chance. Signed-off-by: Jan Kiszka Heh, I did this too more or less the same way. Some comments below: --- arch_init.c|1 + hw/

[Qemu-devel] [PATCH v3 6/7] pcspk: Convert to qdev

2012-01-31 Thread Jan Kiszka
Convert the PC speaker device to a qdev ISA model. Move the public interface to a dedicated header file at this chance. Signed-off-by: Jan Kiszka --- arch_init.c|1 + hw/i82378.c|3 +- hw/mips_jazz.c |3 +- hw/pc.c|3 +- hw/pc.h|4 --- hw/pcspk.c |