[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 6 Jun 2023 17:42:53 +0200
From: Alexander Lobakin <aleksander.lobakin@...el.com>
To: Simon Horman <simon.horman@...igine.com>, Przemek Kitszel
<przemyslaw.kitszel@...el.com>
CC: <intel-wired-lan@...ts.osuosl.org>, Jesse Brandeburg
<jesse.brandeburg@...el.com>, Tony Nguyen <anthony.l.nguyen@...el.com>,
Anirudh Venkataramanan <anirudh.venkataramanan@...el.com>, "Sudheer
Mogilappagari" <sudheer.mogilappagari@...el.com>, <netdev@...r.kernel.org>
Subject: Re: [PATCH iwl-next] ice: clean up __ice_aq_get_set_rss_lut()
From: Simon Horman <simon.horman@...igine.com>
Date: Tue, 6 Jun 2023 17:38:19 +0200
> On Tue, Jun 06, 2023 at 01:11:49PM +0200, Przemek Kitszel wrote:
>
> ...
>
>> diff --git a/drivers/net/ethernet/intel/ice/ice_common.c b/drivers/net/ethernet/intel/ice/ice_common.c
>> index 6acb40f3c202..af4c8ddcafb0 100644
>> --- a/drivers/net/ethernet/intel/ice/ice_common.c
>> +++ b/drivers/net/ethernet/intel/ice/ice_common.c
>> @@ -3869,6 +3869,30 @@ ice_aq_sff_eeprom(struct ice_hw *hw, u16 lport, u8 bus_addr,
>> return status;
>> }
>>
>> +static enum ice_lut_size ice_lut_type_to_size(enum ice_lut_type type)
>> +{
>> + switch (type) {
>> + case ICE_LUT_VSI:
>> + return ICE_LUT_VSI_SIZE;
>> + case ICE_LUT_GLOBAL:
>> + return ICE_LUT_GLOBAL_SIZE;
>> + case ICE_LUT_PF:
>> + return ICE_LUT_PF_SIZE;
>> + }
>
> Hi Przemek,
>
> I see where you are going here, but gcc-12 W=1 wants a return here.
So that it can't see that every enumeration entry is handled here? O_o
>
>> +}
>> +
>> +static enum ice_aqc_lut_flags ice_lut_size_to_flag(enum ice_lut_size size)
>> +{
>> + switch (size) {
>> + case ICE_LUT_VSI_SIZE:
>> + return ICE_AQC_LUT_SIZE_SMALL;
>> + case ICE_LUT_GLOBAL_SIZE:
>> + return ICE_AQC_LUT_SIZE_512;
>> + case ICE_LUT_PF_SIZE:
>> + return ICE_AQC_LUT_SIZE_2K;
>> + }
>
> And here.
>
>> +}
>> +
>> /**
>> * __ice_aq_get_set_rss_lut
>> * @hw: pointer to the hardware structure
>
Thanks,
Olek
Powered by blists - more mailing lists