diff mbox series

[jkirsher/next-queue,1/5] ixgbe: Fix interaction between SR-IOV and macvlan offload

Message ID 20171102233315.15146.95215.stgit@localhost.localdomain
State Changes Requested
Delegated to: Jeff Kirsher
Headers show
Series macvlan offload fixes | expand

Commit Message

Alexander H Duyck Nov. 2, 2017, 11:33 p.m. UTC
From: Alexander Duyck <alexander.h.duyck@intel.com>

When SR-IOV was enabled the macvlan offload was configuring several filters
with the wrong pool value. This would result in the macvlan interfaces not
being able to receive traffic that had to pass over the physical interface.

To fix it wrap the pool argument in the VMDQ_P macro which will add the
necessary offset to get to the actual VMDq pool

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
---
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

Comments

Jesse Brandeburg Nov. 3, 2017, 5:05 p.m. UTC | #1
On Thu, 2 Nov 2017 16:33:30 -0700
Alexander Duyck <alexander.duyck@gmail.com> wrote:

> From: Alexander Duyck <alexander.h.duyck@intel.com>
> 
> When SR-IOV was enabled the macvlan offload was configuring several filters
> with the wrong pool value. This would result in the macvlan interfaces not
> being able to receive traffic that had to pass over the physical interface.
> 
> To fix it wrap the pool argument in the VMDQ_P macro which will add the
> necessary offset to get to the actual VMDq pool
> 
> Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>

Reviewed-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Bowers, AndrewX Nov. 9, 2017, 10:39 p.m. UTC | #2
> -----Original Message-----
> From: Intel-wired-lan [mailto:intel-wired-lan-bounces@osuosl.org] On
> Behalf Of Alexander Duyck
> Sent: Thursday, November 2, 2017 4:34 PM
> To: netdev@vger.kernel.org; intel-wired-lan@lists.osuosl.org
> Subject: [Intel-wired-lan] [jkirsher/next-queue PATCH 1/5] ixgbe: Fix
> interaction between SR-IOV and macvlan offload
> 
> From: Alexander Duyck <alexander.h.duyck@intel.com>
> 
> When SR-IOV was enabled the macvlan offload was configuring several filters
> with the wrong pool value. This would result in the macvlan interfaces not
> being able to receive traffic that had to pass over the physical interface.
> 
> To fix it wrap the pool argument in the VMDQ_P macro which will add the
> necessary offset to get to the actual VMDq pool
> 
> Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
> ---
>  drivers/net/ethernet/intel/ixgbe/ixgbe_main.c |    5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)

Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Duyck, Alexander H Nov. 10, 2017, 5:37 p.m. UTC | #3
On Thu, 2017-11-09 at 22:39 +0000, Bowers, AndrewX wrote:
> > -----Original Message-----
> > From: Intel-wired-lan [mailto:intel-wired-lan-bounces@osuosl.org] On
> > Behalf Of Alexander Duyck
> > Sent: Thursday, November 2, 2017 4:34 PM
> > To: netdev@vger.kernel.org; intel-wired-lan@lists.osuosl.org
> > Subject: [Intel-wired-lan] [jkirsher/next-queue PATCH 1/5] ixgbe: Fix
> > interaction between SR-IOV and macvlan offload
> > 
> > From: Alexander Duyck <alexander.h.duyck@intel.com>
> > 
> > When SR-IOV was enabled the macvlan offload was configuring several filters
> > with the wrong pool value. This would result in the macvlan interfaces not
> > being able to receive traffic that had to pass over the physical interface.
> > 
> > To fix it wrap the pool argument in the VMDQ_P macro which will add the
> > necessary offset to get to the actual VMDq pool
> > 
> > Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
> > ---
> >  drivers/net/ethernet/intel/ixgbe/ixgbe_main.c |    5 +++--
> >  1 file changed, 3 insertions(+), 2 deletions(-)
> 
> Tested-by: Andrew Bowers <andrewx.bowers@intel.com>

Actually I think I want to NAK this patch and the fm10k one that came
after it. I need to redo both of them anyway so I might as well just
re-submit the whole set.

- Alex
diff mbox series

Patch

diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index 2d0232254a7a..69ef35d13c36 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -5426,10 +5426,11 @@  static int ixgbe_fwd_ring_up(struct net_device *vdev,
 		goto fwd_queue_err;
 
 	if (is_valid_ether_addr(vdev->dev_addr))
-		ixgbe_add_mac_filter(adapter, vdev->dev_addr, accel->pool);
+		ixgbe_add_mac_filter(adapter, vdev->dev_addr,
+				     VMDQ_P(accel->pool));
 
 	ixgbe_fwd_psrtype(accel);
-	ixgbe_macvlan_set_rx_mode(vdev, accel->pool, adapter);
+	ixgbe_macvlan_set_rx_mode(vdev, VMDQ_P(accel->pool), adapter);
 	return err;
 fwd_queue_err:
 	ixgbe_fwd_ring_down(vdev, accel);