The set of supported Rx descriptor formats is being read out of the HW registers every time the ice_vc_query_rxdid() function is called. This happens whenever a VF requests a non-default descriptor format.
This is unnecessary as these values only change when the DDP is loaded. The values will also be necessary when enabling live migration, as the migration logic must check that the Rx descriptor format is supported on the target VF. Refactor the logic so that we load the pf->supported_rxdids as soon as the DDP is loaded. I also noticed that the ice_vc_query_rxdid() function was unnecessarily allocating memory for the virtchnl payload. This is an unnecessary waste since the structure size is already no larger than a pointer. Signed-off-by: Jacob Keller <jacob.e.kel...@intel.com> --- Jacob Keller (2): ice: initialize pf->supported_rxdids immediately after loading DDP ice: use stack variable for virtchnl_supported_rxdids drivers/net/ethernet/intel/ice/ice_main.c | 31 +++++++++++++++++++++++ drivers/net/ethernet/intel/ice/ice_virtchnl.c | 36 +++------------------------ 2 files changed, 35 insertions(+), 32 deletions(-) --- base-commit: bfba7bc8b7c2c100b76edb3a646fdce256392129 change-id: 20240909-e810-live-migration-jk-vf-rxdid-cleanup-00ec8fcc62a7 Best regards, -- Jacob Keller <jacob.e.kel...@intel.com>