summary refs log tree commit diff stats
path: root/hw/qdev.c
diff options
context:
space:
mode:
authorMark McLoughlin <markmc@redhat.com>2009-10-08 19:58:30 +0100
committerAnthony Liguori <aliguori@us.ibm.com>2009-10-15 09:32:02 -0500
commit283c7c63f5c56c4d0340fb39093fb47e75cb122e (patch)
treec07299f36322356dac05fb41d3059e614e0073a2 /hw/qdev.c
parent5869c4d515128cd3a938a7346a8037abcc232220 (diff)
downloadfocaccia-qemu-283c7c63f5c56c4d0340fb39093fb47e75cb122e.tar.gz
focaccia-qemu-283c7c63f5c56c4d0340fb39093fb47e75cb122e.zip
net: allow NICs to be connected to netdevs
Introduce a 'peer' member to VLANClientState as an alternative
to a vlan. The idea being that packets are transfered directly
from peer clients rather than going through a vlan.

Patchworks-ID: 35516
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/qdev.c')
-rw-r--r--hw/qdev.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/hw/qdev.c b/hw/qdev.c
index 906e897554..20f931c1c6 100644
--- a/hw/qdev.c
+++ b/hw/qdev.c
@@ -370,8 +370,10 @@ VLANClientState *qdev_get_vlan_client(DeviceState *dev,
 {
     NICInfo *nd = dev->nd;
     assert(nd);
-    nd->vc = qemu_new_vlan_client(nd->vlan, nd->model, nd->name, can_receive,
-                                  receive, receive_iov, cleanup, opaque);
+    nd->vc = qemu_new_vlan_client(nd->vlan, nd->netdev,
+                                  nd->model, nd->name,
+                                  can_receive, receive, receive_iov,
+                                  cleanup, opaque);
     return nd->vc;
 }