qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RFC] Plan for moving forward with QOM


From: Gleb Natapov
Subject: Re: [Qemu-devel] [RFC] Plan for moving forward with QOM
Date: Fri, 16 Sep 2011 21:22:46 +0300

On Fri, Sep 16, 2011 at 01:08:27PM -0500, Anthony Liguori wrote:
> On 09/16/2011 12:47 PM, Peter Maydell wrote:
> >On 16 September 2011 17:33, Gleb Natapov<address@hidden>  wrote:
> >>On Thu, Sep 15, 2011 at 09:45:33PM +0100, Peter Maydell wrote:
> >>>On 15 September 2011 21:29, Gleb Natapov<address@hidden>  wrote:
> >>>>16650A is not a device. ISA card it resides on is a device.
> >>>
> >>>The 16550A is an encapsulated set of functionality with some
> >>>well defined interfaces ("I provide a set of memory mapped
> >>>registers", "I have an output gpio line (irq)"), which we
> >>>need to be able to compose into other things (lots of models
> >>>use a 16550A one way or another, not just the ISA serial card),
> >>>connect up (ie connect that irq to an appropriate interrupt
> >>>controller, map the registers in system memory or under ISA
> >>>or whatever), and configure (eg specify the backend chardev).
> >>>
> >>>I don't think there's any difference at all between that
> >>>and (say) the NE2000 PCI model, which also is encapsulated
> >>>functionality with well defined interfaces that we need to
> >>>be able to compose and connect and configure. We should be
> >>>using the same implementation and abstractions for both
> >>>cases.
> >>>
> >>IDE is another such device (it was ISA later converted to PCI).
> >>As far as I understand your view of UART is the same as mine.
> >>It is not a whole device, but only a part of it.
> >
> >If we have the same view of the UART then one of us is rather
> >misunderstanding the other (could be me).
> >
> >I don't care whether you apply the label "device" to the
> >UART, but I definitely want it to be exactly the same kind
> >of QEMU "object", in terms of how you implement it and use it,
> >as a PCI NE2000 model or an ISA serial card or an ARM-Cortex-A8
> >CPU model or a "vexpress-a9" board model.
> 
> Exactly.  This is what I dislike about qdev today.  The UART
> (SerialState) is not a DeviceState.  That's a major problem for me.
> 
> There should be no different between IsaSerialState and SerialState
> in terms of what they are and how you interact with them.  Whether
> IsaSerialState should even exist is a separate discussion that's
> really just a minor detail.
> 
Then we are arguing about minor detail. But according to you this minor
detail will prevent us from walking device tree up to the root, so it is
not so minor for me.

--
                        Gleb.



reply via email to

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