qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Anthony Liguori <anthony@codemonkey.ws>
To: qemu-devel@nongnu.org
Cc: Juergen Lock <nox@jelal.kn-bremen.de>,
	Jung-uk Kim <jkim@FreeBSD.org>,
	Sebastian Herbszt <herbszt@gmx.de>
Subject: Re: [Qemu-devel] Re: [PATCH] networking using libpcap
Date: Fri, 25 Jul 2008 15:51:12 -0500	[thread overview]
Message-ID: <488A3CC0.60802@codemonkey.ws> (raw)
In-Reply-To: <200807181639.49136.jkim@FreeBSD.org>

Jung-uk Kim wrote:
> On Friday 18 July 2008 12:12 pm, Sebastian Herbszt wrote:
>
> I simplified FreeBSD ports patch with the above patch:
>
> http://people.freebsd.org/~jkim/qemu-devel-20080620_1-pcap.diff
>   

I spent some time with this patch looking to merge it.  It seems to have 
decent performance and is very easy to use.  Unfortunately, I ran into 
the following:

1) If I specify -net pcap,ifname=eth0 -net nic,model=rtl8139, I get an 
error, whereas if I specify -net nic,model=rtl8139 -net pcap,ifname=eth0 
it works.  The reason for this is that in net_pcap_init(), you search 
the vlan to discover what the IP address is of the NIC on the vlan is.

This is a big no-no as you can have one or more NICs on a single vlan.  
Moreover, NICs can be added and removed from a vlan long after it's 
created.  The patch needs a fair bit more work to handle this proper 
(presumably building a new filter rule as NICs are added and removed 
from the vlan).

2) When using ifname=eth0, traffic doesn't work from host=>guest nor 
from guest=>host.  This seems like a major short-coming to me.  Having 
another networking option that is easy to use but doesn't work in some 
fundamental way that a user would expect seems like it's just going to 
lead to even further confusion.  This patch isn't attractive to me 
unless it works just like you were bridging to a physical interface (and 
I don't think there's anything fundamental preventing that).

If you can fix these issues, I'd be happy to merge this feature.

Regards,

Anthony Liguori

> Thanks!
>
> Jung-uk Kim
>
>
>   

  parent reply	other threads:[~2008-07-25 20:51 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-17 22:12 [Qemu-devel] Re: [PATCH] networking using libpcap Jung-uk Kim
2008-07-18 16:12 ` Sebastian Herbszt
2008-07-18 20:39   ` Jung-uk Kim
2008-07-18 23:07     ` Jung-uk Kim
2008-07-21 15:35     ` Sebastian Herbszt
2008-07-25 20:51     ` Anthony Liguori [this message]
2008-07-26 17:30       ` Sebastian Herbszt
2008-07-27  0:28         ` Anthony Liguori
2008-07-27 12:55       ` Paul Brook
2008-07-23  1:55 ` Anthony Liguori
  -- strict thread matches above, loose matches on Subject: below --
2008-07-02 15:02 [Qemu-devel] " Ulrich Hecht
2008-07-02 23:39 ` [Qemu-devel] " Sebastian Herbszt

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=488A3CC0.60802@codemonkey.ws \
    --to=anthony@codemonkey.ws \
    --cc=herbszt@gmx.de \
    --cc=jkim@FreeBSD.org \
    --cc=nox@jelal.kn-bremen.de \
    --cc=qemu-devel@nongnu.org \
    /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).