]> www.infradead.org Git - users/jedix/linux-maple.git/commit
ice: treat dyn_allowed only as suggestion
authorMichal Swiatkowski <michal.swiatkowski@linux.intel.com>
Tue, 3 Dec 2024 06:58:14 +0000 (07:58 +0100)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Wed, 5 Feb 2025 17:04:57 +0000 (09:04 -0800)
commita8c2d3932c1106af2764cc6869b29bcf3cb5bc47
treebb3786a9867d3366cd489eada53c842711ba94d6
parent3e0d3cb3fbe06a7bc09d98324a21a446c80f9d3b
ice: treat dyn_allowed only as suggestion

It can be needed to have some MSI-X allocated as static and rest as
dynamic. For example on PF VSI. We want to always have minimum one MSI-X
on it, because of that it is allocated as a static one, rest can be
dynamic if it is supported.

Change the ice_get_irq_res() to allow using static entries if they are
free even if caller wants dynamic one.

Adjust limit values to the new approach. Min and max in limit means the
values that are valid, so decrease max and num_static by one.

Set vsi::irq_dyn_alloc if dynamic allocation is supported.

Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
Reviewed-by: Wojciech Drewek <wojciech.drewek@intel.com>
Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@intel.com>
Signed-off-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ice/ice_irq.c
drivers/net/ethernet/intel/ice/ice_lib.c