]> git.baikalelectronics.ru Git - kernel.git/commit
ixgbe: Prevent unsupported configurations with XDP
authorTony Nguyen <anthony.l.nguyen@intel.com>
Mon, 30 Jul 2018 22:52:48 +0000 (15:52 -0700)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Fri, 24 Aug 2018 15:52:35 +0000 (08:52 -0700)
commite6d3c7b58f9d9e93842723744284e9c283c7ee0d
treed2bddb5c35a3eb93c321a3f88fbfe26c1b3ab892
parent4dc638292020b15047a89f0a8f4bf431fd1d9394
ixgbe: Prevent unsupported configurations with XDP

These changes address comments by Jakub Kicinski on
commit 6de16b241b98 ("ixgbe: Do not allow LRO or MTU change with XDP").

Change the MTU check with XDP to allow any supported value and only
reject those outside of the range as opposed to rejecting any change
when XDP is active. In situations where MTU size is not supported,
return -EINVAL instead of -EPERM.

Add checks when enabling SRIOV, DCB, or adding L2FW offloaded device
as they are not supported with XDP.

CC: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
drivers/net/ethernet/intel/ixgbe/ixgbe_sriov.c