qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] Semantics of DeviceState::realized and BlockDriverState


From: Anthony Liguori
Subject: Re: [Qemu-devel] Semantics of DeviceState::realized and BlockDriverState
Date: Mon, 11 Jun 2012 20:26:26 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120329 Thunderbird/11.0.1

On 06/11/2012 07:29 PM, Andreas Färber wrote:
Am 12.06.2012 00:05, schrieb Anthony Liguori:
I think I'm becoming convinced that realized belongs in DeviceState and
that BlockDriverState does not have a realized equivalent.

To me, realized represents Vcc.  When realized=true, the guest has power
and is active.  When realized=false, the guest has lost power.  The
realize() event is the rising edge of Vcc, unrealized() is the falling
edge.

Then please name it appropriately: "powered" and "unpowered".

Realization has nothing to do with power, it's an OOP term that
distinguishes from instantiation.

Eh?  I'm not familiar with it as a OOP term.

The way this discussion has headed is very unfortunate for me since I
need such a hook for the CPUs today and not in a far future when the
whole of qdev has been refactored to match the QOM type / inheritance

I warned you early on that CPUs were not the best place to start...

I think the fundamental problem is that CPU wants to be a TYPE_DEVICE. We probably shouldn't have started with it as TYPE_OBJECT.

I think that's really the immediate problem that needs to be solved. I think avoiding making it TYPE_DEVICE is what's caused us to attempt to push realized into Object in the first place.

Regards,

Anthony Liguori



reply via email to

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