mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/
synced 2026-05-03 10:38:37 -04:00
ixgbe: Support 4 queue RSS on VFs with 1 or 2 queue RSS on PF
Instead of limiting the VFs if we don't use 4 queues for RSS in the PF we can instead just limit the RSS queues used to a power of 2. By doing this we can support use cases where VFs are using more queues than the PF is currently using and can support RSS if so desired. The only limitation on this is that we cannot support 3 queues of RSS in the PF or VF. In either of these cases we should fall back to 2 queues in order to be able to use the power of 2 masking provided by the psrtype register. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
This commit is contained in:
committed by
Jeff Kirsher
parent
fa81da7e5b
commit
e24fcf2895
@@ -515,15 +515,16 @@ static bool ixgbe_set_sriov_queues(struct ixgbe_adapter *adapter)
|
||||
vmdq_i = min_t(u16, IXGBE_MAX_VMDQ_INDICES, vmdq_i);
|
||||
|
||||
/* 64 pool mode with 2 queues per pool */
|
||||
if ((vmdq_i > 32) || (rss_i < 4) || (vmdq_i > 16 && pools)) {
|
||||
if ((vmdq_i > 32) || (vmdq_i > 16 && pools)) {
|
||||
vmdq_m = IXGBE_82599_VMDQ_2Q_MASK;
|
||||
rss_m = IXGBE_RSS_2Q_MASK;
|
||||
rss_i = min_t(u16, rss_i, 2);
|
||||
/* 32 pool mode with 4 queues per pool */
|
||||
/* 32 pool mode with up to 4 queues per pool */
|
||||
} else {
|
||||
vmdq_m = IXGBE_82599_VMDQ_4Q_MASK;
|
||||
rss_m = IXGBE_RSS_4Q_MASK;
|
||||
rss_i = 4;
|
||||
/* We can support 4, 2, or 1 queues */
|
||||
rss_i = (rss_i > 3) ? 4 : (rss_i > 1) ? 2 : 1;
|
||||
}
|
||||
|
||||
#ifdef IXGBE_FCOE
|
||||
|
||||
Reference in New Issue
Block a user