Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-24 Thread Markus Armbruster
Peter Maydell writes: > On 21 October 2016 at 19:26, Markus Armbruster wrote: >> "Device not pluggable" does not imply "device has no configuration knobs >> a user may legitimately want to mess with". Plenty of onboard devices >> have such knobs. >>

Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-22 Thread Peter Maydell
On 21 October 2016 at 19:26, Markus Armbruster wrote: > "Device not pluggable" does not imply "device has no configuration knobs > a user may legitimately want to mess with". Plenty of onboard devices > have such knobs. > > Right now, users configure these mostly via

Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-21 Thread Markus Armbruster
Peter Maydell writes: > On 18 October 2016 at 21:49, Eduardo Habkost wrote: >> On Tue, Oct 18, 2016 at 09:30:01PM +0100, Peter Maydell wrote: >>> Lots of stuff in a device's C struct is strictly internal >>> and not to be messed with. I thought

Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-19 Thread Peter Maydell
On 19 October 2016 at 12:11, Eduardo Habkost wrote: > BTW, if most devices aren't supposed to be used with -device, > possibly many of them don't have > cannot_instantiate_with_device_add_yet set properly. They used to be covered by hw/core/sysbus.c setting it for them. In

Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-19 Thread Eduardo Habkost
On Tue, Oct 18, 2016 at 10:08:21PM +0100, Peter Maydell wrote: > On 18 October 2016 at 21:49, Eduardo Habkost wrote: > > On Tue, Oct 18, 2016 at 09:30:01PM +0100, Peter Maydell wrote: > >> Lots of stuff in a device's C struct is strictly internal > >> and not to be messed

Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-18 Thread Peter Maydell
On 18 October 2016 at 21:49, Eduardo Habkost wrote: > On Tue, Oct 18, 2016 at 09:30:01PM +0100, Peter Maydell wrote: >> Lots of stuff in a device's C struct is strictly internal >> and not to be messed with. I thought that QOM properties >> were essentially how a device

Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-18 Thread Eduardo Habkost
On Tue, Oct 18, 2016 at 09:30:01PM +0100, Peter Maydell wrote: > On 18 October 2016 at 19:45, Eduardo Habkost wrote: > > On Tue, Oct 18, 2016 at 07:12:51PM +0100, Peter Maydell wrote: > >> We actually have a concrete instance in the tree at the moment: > >> the raspberry pi

Re: [Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-18 Thread Peter Maydell
On 18 October 2016 at 19:45, Eduardo Habkost wrote: > On Tue, Oct 18, 2016 at 07:12:51PM +0100, Peter Maydell wrote: >> We actually have a concrete instance in the tree at the moment: >> the raspberry pi 2. Specifically hw/arm/bcm2836.c sets the >> mp_affinity for each cpu to

[Qemu-devel] QOM properties vs C functions/fields (was Re: [PATCH v3 2/3] exec: rename cpu_exec_init() as cpu_exec_realizefn())

2016-10-18 Thread Eduardo Habkost
On Tue, Oct 18, 2016 at 07:12:51PM +0100, Peter Maydell wrote: > On 18 October 2016 at 18:57, Andrew Jones wrote: > > On Tue, Oct 18, 2016 at 06:07:49PM +0100, Peter Maydell wrote: > >> Why do you want to un-property mp_affinity? Eventually it would > >> be nice for the