qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] Questions on DeviceState and Virtio infrastructure
@ 2011-06-29 13:59 Wei Liu
  2011-06-30  8:31 ` Alexander Graf
  0 siblings, 1 reply; 8+ messages in thread
From: Wei Liu @ 2011-06-29 13:59 UTC (permalink / raw)
  To: qemu-devel; +Cc: Anthony Perard, Wei LIU, Stefano Stabellini

Hi, QEMU folks

I know that I might have a bad title for this post, but I just don't
have better idea for the title.

I'm developing virtio support for Xen pv guest, hoping to reuse the
virtio infrastructure in qemu, i.e. I'm planning to use qemu as
"virtio backend" for Xen pv. And qemu can be run as pv backend if
proper "machine" option is given.

Maybe you've known that Xen pv guest utilizes Xenbus/Xenstore to
configure its paravirt devices. So I'm to configure virtio devices
with Xenbus/Xenstore as well. But in nowdays XenDevice in qemu does
not include a DeviceState. To my understanding, it is not connected to
qemu's internal buses or whatever (correct me if I'm wrong, I'm
relatively new to qemu).

Here is the problem, say I'm to implement virtio nic for Xen pv guest,
I use Xenbus to probe and initialize the device. When doing
initialization, I am to reuse virtio_net_init, which takes DeviceState
as the first argument -- but I just don't have one in XenDevice. All I
need is to use qemu's virtio infrastructure.

What's the purpose of this DeviceState argument?

If I just construct my own DeviceState and pass it to virtio_net_init,
what will happen? Will qemu emulates virtio nic as usual?

Thanks.

Wei.

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2011-06-30 17:39 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-29 13:59 [Qemu-devel] Questions on DeviceState and Virtio infrastructure Wei Liu
2011-06-30  8:31 ` Alexander Graf
2011-06-30  8:44   ` Wei Liu
2011-06-30 10:21     ` Stefano Stabellini
2011-06-30 11:12       ` Alexander Graf
2011-06-30 14:11         ` Stefano Stabellini
2011-06-30 14:28           ` Alexander Graf
2011-06-30 17:43             ` Stefano Stabellini

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).