All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexander Duyck <alexander.h.duyck@redhat.com>
To: intel-wired-lan@osuosl.org
Subject: [Intel-wired-lan] vlan packet handling in ixgbevf driver when in	promiscuous mode
Date: Thu, 04 Jun 2015 13:34:46 -0700	[thread overview]
Message-ID: <5570B666.3030603@redhat.com> (raw)
In-Reply-To: <5570998C.60600@windriver.com>

On 06/04/2015 11:31 AM, Chris Friesen wrote:
> On 06/04/2015 09:54 AM, Rose, Gregory V wrote:
>>> -----Original Message----- From: Chris Friesen
>>> [mailto:chris.friesen at windriver.com] Sent: Monday, June 01, 2015 
>>> 5:02 PM
>>> To: Rose, Gregory V; intel-wired-lan at lists.osuosl.org Subject: Re:
>>> [Intel-wired-lan] vlan packet handling in ixgbevf driver when in
>>> promiscuous mode
>>>
>>> Could you elaborate?
>>>
>>> The use-case here is for NFV/SDN type stuff, where we want to be 
>>> able to
>>> run a router or something similar in the guest--so it needs to be 
>>> able to
>>> receive packets from all VLANs.
>>>
>>> From what I see if you enable promiscuous mode on the PF then the 
>>> VFs get
>>> packets from all VLANs.
>
>> If you have a working configuration then that's fine.  I was merely 
>> pointing
>> out that promiscuous mode, as the semantics are commonly applied to 
>> word in a
>> networking context, is not supported for virtual functions on the 82599
>> controller.  There are configurations you can apply to suit your own 
>> purposes
>> and we would like to support that for you if we can.
>
> Well, it's "working" but it means we have to patch the ixgbevf driver, 
> which is a bit of a pain.
>
> I'd like to see something like what Alexander Duyck suggested where 
> the stock ixgbevf driver would only strip the VLAN tags off for 
> packets where the VLAN matches the port VLAN ID and let all the other 
> VLAN tags through.  (If the guest interface is in promiscuous mode.)
>
> Arguably if the guest interface is not in promiscuous mode then I 
> think we should be dropping packets from all VLANs other than what the 
> guest has explicitly registered for (or that the PF has assigned to 
> the VF.  It makes no sense to me that we would let them all through 
> but strip off the VLAN header.
>
> Chris

Chris,

Based on what is in current net-next I don't see how you can enable VLAN 
promiscuous mode on the PF without having a modified driver of some 
sort.  That is the first issue.  That is the one we have been discussing 
with Hiroshi as he had submitted patches to enable such a feature.

That is what leads us to your request.  If you enable VLAN promiscous 
the VF drivers currently don't support it and generally make a mess of 
things since this misidentify the VLAN ID on the incoming frames.  So 
you would need to do two things.  The first would be to update the PF 
driver so that if VLAN promiscuous mode is enabled you turn off any 
legacy VFs that might be running.  The second would be to generate a new 
API version for the VF driver and add the necessary bits so that the VFs 
can identify which VLAN they are assigned to, if any.  We did something 
similar for Jumbo Frames and FCoE/DCB so that we could allow a PF to 
enable these features even though it caused some legacy VFs to crash if 
such a feature was enabled.  If you are wanting to enable VLAN 
promiscuous mode then that is the route you would like need to take.

- Alex

  reply	other threads:[~2015-06-04 20:34 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-29 20:59 [Intel-wired-lan] vlan packet handling in ixgbevf driver when in promiscuous mode Chris Friesen
2015-06-01 16:48 ` Rose, Gregory V
2015-06-02  0:01   ` Chris Friesen
2015-06-02  0:47     ` Hiroshi Shimamoto
2015-06-02  3:18       ` Alexander Duyck
2015-06-04 15:54     ` Rose, Gregory V
2015-06-04 18:31       ` Chris Friesen
2015-06-04 20:34         ` Alexander Duyck [this message]
2015-06-04 20:45           ` Chris Friesen
2015-06-04 21:02             ` Alexander Duyck

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=5570B666.3030603@redhat.com \
    --to=alexander.h.duyck@redhat.com \
    --cc=intel-wired-lan@osuosl.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.