]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ice: avoid rebuilding if MSI-X vector count is unchanged
authorJacob Keller <jacob.e.keller@intel.com>
Wed, 18 Jun 2025 22:24:42 +0000 (15:24 -0700)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Thu, 10 Jul 2025 21:36:58 +0000 (14:36 -0700)
commit922683498e847ef8b2db14afb2c52b7184dde466
tree00b616f3e89b735a56e72989c2f247ce70545124
parent4ef21c83ea4bb33aa12f2e927bbaabbd1bdd2ae9
ice: avoid rebuilding if MSI-X vector count is unchanged

Commit 05c16687e0cc ("ice: set MSI-X vector count on VF") added support to
change the vector count for VFs as part of ice_sriov_set_msix_vec_count().
This function modifies and rebuilds the target VF with the requested number
of MSI-X vectors.

Future support for live migration will add a call to
ice_sriov_set_msix_vec_count() to ensure that a migrated VF has the proper
MSI-X vector count. In most cases, this request will be to set the MSI-X
vector count to its current value. In that case, no work is necessary.
Rather than requiring the caller to check this, update the function to
check and exit early if the vector count is already at the requested value.
This avoids an unnecessary VF rebuild.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Tested-by: Rafal Romanowski <rafal.romanowski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ice/ice_sriov.c