qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] qapi/x86: add control registers to query-cpus


From: Eduardo Habkost
Subject: Re: [Qemu-devel] [PATCH] qapi/x86: add control registers to query-cpus
Date: Fri, 25 Jan 2013 10:54:50 -0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Fri, Jan 25, 2013 at 10:45:11AM -0200, Luiz Capitulino wrote:
[...]
> > >> The obvious suggestion is to add query-cpu-registers. I understand this 
> > >> has a
> > >> few problems (see questions below), but I think the following incremental
> > >> approach could work:
> > >>
> > >>  1. Add a CPURegisters union
> > >>  2. Each CPU arch is added as a type to the union (eg. CPUX86Registers)
> > >>  3. query-cpu-registers returns the union
> > > 
> > > We already have CPU QOM objects, we just need to add a
> > > methods/properties so each per-architecture subclass will implement
> > > what's necessary for the command.
> > > 
> > > We could go even further: just use the qom-* commands. Then if there's
> > > some set of registers we really want to expose to the outside, just add
> > > them as properties to the CPU object.
> > 
> > Makes sense.
> 
> Oh, agreed. That would be a lot better and I didn't even consider this.
> 
> What's the status of the CPU work on QOM? Would it be possible to expose
> registers info already or some work is still needed? If work is needed,
> what's missing?

The CPUs are already DeviceState objects, but they are not on any bus. I
am not sure if they are visible in the device tree and acessible using
qom-* without a bus, but IIRC somebody told me that they are.

If they are already visible and acessible using qom-list/qom-get, we
just need to add properties for each register we want to expose.

-- 
Eduardo



reply via email to

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