> -----Original Message----- > From: Intel-wired-lan <intel-wired-lan-bounces@xxxxxxxxxx> On Behalf Of > Maciej Fijalkowski > Sent: Thursday, March 24, 2022 12:49 PM > To: intel-wired-lan@xxxxxxxxxxxxxxxx > Cc: netdev@xxxxxxxxxxxxxxx; kuba@xxxxxxxxxx; bpf@xxxxxxxxxxxxxxx; > pabeni@xxxxxxxxxx; davem@xxxxxxxxxxxxx; Karlsson, Magnus > <magnus.karlsson@xxxxxxxxx> > Subject: [Intel-wired-lan] [PATCH intel-next] ice: introduce common helper > for retrieving VSI by vsi_num > > Both ice_idc.c and ice_virtchnl.c carry their own implementation of a helper > function that is looking for a given VSI based on provided vsi_num. Their > functionality is the same, so let's introduce the common function in ice.h that > both of the mentioned sites will use. > > This is a strictly cleanup thing, no functionality is changed. > > Reviewed-by: Alexander Lobakin <alexandr.lobakin@xxxxxxxxx> > Signed-off-by: Maciej Fijalkowski <maciej.fijalkowski@xxxxxxxxx> > --- > drivers/net/ethernet/intel/ice/ice.h | 15 +++++++++++++ > drivers/net/ethernet/intel/ice/ice_idc.c | 15 ------------- > drivers/net/ethernet/intel/ice/ice_virtchnl.c | 22 ++----------------- > 3 files changed, 17 insertions(+), 35 deletions(-) > > diff --git a/drivers/net/ethernet/intel/ice/ice.h > b/drivers/net/ethernet/intel/ice/ice.h > index e9aa1fb43c3a..a541446b96e8 100644 > --- a/drivers/net/ethernet/intel/ice/ice.h > +++ b/drivers/net/ethernet/intel/ice/ice.h Tested-by: Konrad Jankowski <konrad0.jankowski@xxxxxxxxx>