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>
This commit is contained in:
Mark McLoughlin 2009-10-08 19:58:30 +01:00 committed by Anthony Liguori
parent 5869c4d515
commit 283c7c63f5
10 changed files with 45 additions and 20 deletions

View file

@ -590,7 +590,8 @@ void *etraxfs_eth_init(NICInfo *nd, target_phys_addr_t base, int phyaddr)
eth->ethregs = cpu_register_io_memory(eth_read, eth_write, eth);
cpu_register_physical_memory (base, 0x5c, eth->ethregs);
eth->vc = nd->vc = qemu_new_vlan_client(nd->vlan, nd->model, nd->name,
eth->vc = nd->vc = qemu_new_vlan_client(nd->vlan, nd->netdev,
nd->model, nd->name,
eth_can_receive, eth_receive,
NULL, eth_cleanup, eth);
eth->vc->opaque = eth;