I would like to know if some one is playing around with the patchset. If yes, can any one make one response? I am very interested in rebasing it, and then playing with it.
On Tue, Jan 24, 2012 at 6:42 PM, Stefan Hajnoczi <stefa...@gmail.com> wrote: > On Tue, Jan 24, 2012 at 6:22 PM, Benjamin <mlspira...@gmail.com> wrote: >> Hello Stefan, > > Hi, > Please send QEMU development emails to the mailing list so others can > help or we can avoid duplicating work in case someone else is already > looking into this. I have CCed the mailing list. > >> I've seen your blog and I hope you can help me address the issue of >> -net dump not being compatible with the new -netdev syntax. > > The reason is because packet capture is implemented as a net client - > it receives packets on the "VLAN" and writes them to the pcap file. > In the -netdev model each client has a peer (another net client that > is communicates with). So it's not possible to plug the "dump" net > client together with an emulated NIC client and a host tap client, for > example. Since "VLANs" broadcast packets to all attached net clients > it works there. > >> I think it is possible to achieve but I've had a lot of trouble >> understanding the code, VLANs are everywhere and even though the new >> syntax doesn't use them it looks like the code still uses a VLAN logic. >> >> Before I really start to get serious about this task, do you have any >> advice or recommendation? > > I refactored the network subsystem to drop the "VLAN" concept a while > back but never got around to submitting the patches: > > http://repo.or.cz/w/qemu/stefanha.git/shortlog/refs/heads/vlan-hub > > This branch completely removes the "VLAN" feature. Instead it > introduces hubs, which are net clients that have multiple ports and > broadcast packets between them. This allows you to achieve the same > behavior as "VLANs" except we remove all the hardcoded special cases > in the net subsystem and instead push that feature out into the hub > net client. > > If you rebase the vlan-hub branch onto a recent qemu.git, then you can > use -netdev syntax to create an emulated NIC, host device, dump > device, and a hub. The three clients must be attached to the hub. > > I think the code is already there, it should work. I didn't submit > this because I wanted to implement automated tests to ensure that > these changes don't brake the old syntax for "VLANs". > > Feel free to play around with the vlan-hub branch, test it, and push > it upstream along with changes that you make. > > Stefan > -- Regards, Zhi Yong Wu