qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH qom-cpu 00/15 v8] target-i386: convert CPU featu


From: Andreas Färber
Subject: Re: [Qemu-devel] [PATCH qom-cpu 00/15 v8] target-i386: convert CPU features into properties, part 1
Date: Wed, 05 Jun 2013 19:29:46 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130510 Thunderbird/17.0.6

Am 05.06.2013 19:17, schrieb Eduardo Habkost:
> On Wed, Jun 05, 2013 at 07:04:59PM +0200, Andreas Färber wrote:
>> Am 05.06.2013 16:39, schrieb Igor Mammedov:
>>> On Wed, 05 Jun 2013 15:29:08 +0200
>>> Andreas Färber <address@hidden> wrote:
>>>> Why is conversion of dynamic properties to static properties still
>>>> needed after I applied a solution to override values of dynamic
>>>> properties with -global for 1.5?
>>> Do you mean qdev_prop_set_globals_for_type() & co?
>>
>> Yes.
>>
>>> If yes, then I recall it was acceptable hack to permit more clean
>>> approach for compat props fixes to work. And we promised Anthony to
>>> get rid of it when possible.
>>
>> Indeed, but no one talked about reverting to static properties as the
>> solution. :) Instead I was talking about solving this very general
>> problem at DeviceState / QOM level.
> 
> We have had this discussion before, and I remember Anthony saying that
> anything set using global properties _must_ be static properties,
> period.

Obviously I am not aware of that, might that have been an IRC discussion?!

> That was the main motivation we even started doing the static properties
> work, months ago.

Towards Paolo and me, Anthony rejected having static properties for QOM
at all! That was back when I temporarily maintained a qom-next tree
during some Hard Freeze, I had to unqueue patches to that effect.

>> Instead we have a very generic problem: instance_init is called
>> recursively, parents first, so a parent class cannot do any instance
>> initialization *after* its derived classes initialized the instance.
>> That's contrary to how realize and other QOM methods work but in
>> exchange for the flexibility put the burden of saving and calling the
>> parent's implementation onto subclasses.
>>
>> That's what I would like to change in some way, possibly a
>> instance_post_init hook or the like, similar to how DeviceState got its
>> own base class initialization hook to handle static props.
>> That would not only keep the work low in this case but may also solve
>> the virtio-net initialization problem reported elsewhere.
> 
> You mean this?
> https://lists.gnu.org/archive/html/qemu-devel/2012-10/msg00434.html

No, wasn't aware of that patchset yet, but yes, something like that I
had suggested in the qdev_set_custom_globals() context last Soft Freeze.

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg



reply via email to

[Prev in Thread] Current Thread [Next in Thread]