qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Andreas Färber" <afaerber@suse.de>
To: Zhi Yong Wu <zwu.kernel@gmail.com>
Cc: Jan Kiszka <jan.kiszka@siemens.com>,
	QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] about kvmclock QOM
Date: Tue, 13 Mar 2012 15:36:48 +0100	[thread overview]
Message-ID: <4F5F5B80.6080609@suse.de> (raw)
In-Reply-To: <CAEH94LjZ+T+bM2bnCVHvAqAvUUAAfxGp1S-hDmkJANpWVJTsCw@mail.gmail.com>

Am 13.03.2012 15:11, schrieb Zhi Yong Wu:
> On Tue, Mar 13, 2012 at 9:52 PM, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>> On 2012-03-13 14:40, Zhi Yong Wu wrote:
>>> On Tue, Mar 13, 2012 at 9:36 PM, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>>>> On 2012-03-13 13:57, Zhi Yong Wu wrote:
>>>>> HI, Jan
>>>>>
>>>>> Why can i not see kvmclock device in the output of qom-list? Since it
>>>>> has been converted to QOM.
>>>>
>>>> qom-list, like all QMP/ scripts, are currently broken for me, can't test
>>>> therefore. Please post any findings to the list while I'm digging into
>>> I can see other devices such emulated nics via qom-list, but didn't
>>> see kvmclock device in its output.
>>> what is kvmclock's path if it can work normally?
>>> My qemu command line is
>>>
>>> [root@f15 qemu]# x86_64-softmmu/qemu-system-x86_64 -m 512 -drive
>>> file=/home/zwu/work/misc/image/rh6.1.img,if=ide,cache=none -enable-kvm
>>> -qmp unix:/tmp/server.sock,server,nowait -netdev type=user,id=net
>>> -device virtio-net-pci,netdev=net,id=net -net user,vlan=1 -device
>>> virtio-net-pci,id=net2,vlan=1 -chardev id=stdio,backend=stdio -device
>>> isa-serial,chardev=stdio,id=serial
>>
>> Ah, now it works again (forgot mode="control" for -mon).
>>
>>>
>>> [root@f15 qemu]# QMP/qom-list -s /tmp/server.sock /
>>> vga/
>>> i440fx/
>>> peripheral/
>>> peripheral-anon/
>>> [root@f15 qemu]# QMP/qom-list -s /tmp/server.sock /peripheral
>>> serial/
>>> net2/
>>> net/
>>>
>>
>> kvmclock (like many devices) is not yet linked to some parent device, so
> static TypeInfo kvmclock_info = {
>     .name          = "kvmclock",
>     .parent        = TYPE_SYS_BUS_DEVICE,
> It seems to be linked from here

No. This specifies the parent class (base or super class).

What you are looking for is the "parent" property which gets set up by
adding a child property to some object. Many devices are not yet wired
up as such and can only be inspected by info qtree monitor command.

>     .instance_size = sizeof(KVMClockState),
>     .class_init    = kvmclock_class_init,
> };
> 
> I also checked other devices which can be seen in the output of
> qom-list. I have not seen kvmclock QOM is different from other
> devices.
> So i am very surprised that why kvmclock device can not be seen in
> qom-list output.
> 
>> it's not present in that tree. This also happens to auto-created
>> isa-serial, e.g. (just leave out -device isa-serial)
> Yeah, i can see it in qom-list output.

Devices created by -device should be listed in the "/anon-peripheral"
(or so) container. Check qom-list / for its child nodes.

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	other threads:[~2012-03-13 14:37 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAEH94Lj_+iEgXoMyzJu296NFm1R7hq1uOwAQrNd28khCctCKtQ@mail.gmail.com>
     [not found] ` <4F5F4D4C.7010805@siemens.com>
     [not found]   ` <CAEH94Lhs4b07mf3dN5bQX-qUePRUN8DeUbppoCtGTgNDS_O=Ng@mail.gmail.com>
     [not found]     ` <4F5F5139.8080205@siemens.com>
2012-03-13 14:11       ` [Qemu-devel] about kvmclock QOM Zhi Yong Wu
2012-03-13 14:36         ` Andreas Färber [this message]
2012-03-13 14:52           ` Zhi Yong Wu
2012-03-13 15:10             ` Andreas Färber
2012-03-13 15:17               ` Zhi Yong Wu
2012-03-13 15:18                 ` Andreas Färber
2012-03-13 15:24                   ` Zhi Yong Wu
2012-03-13 15:21               ` Zhi Yong Wu
2012-03-13 16:28                 ` Andreas Färber
2012-03-14  2:07                   ` Zhi Yong Wu
2012-03-14  4:27                     ` Gavin Shan
2012-03-14  5:23                       ` Zhi Yong Wu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F5F5B80.6080609@suse.de \
    --to=afaerber@suse.de \
    --cc=jan.kiszka@siemens.com \
    --cc=qemu-devel@nongnu.org \
    --cc=zwu.kernel@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).