Re: [PATCH V3] wifi: rtlwifi: Drastically reduce the attempts to read efuse in case of failures
From: Guilherme G. Piccoli
Date: Fri Nov 01 2024 - 15:38:56 EST
>> [...]
>> struct rtl_priv *rtlpriv = rtl_priv(hw);
>> + u16 retry, max_attempts;
>> u32 value32;
>> u8 readbyte;
>> - u16 retry;
>> +
>> + /*
>> + * In case of USB devices, transfer speeds are limited, hence
>> + * efuse I/O reads could be (way) slower. So, decrease (a lot)
>> + * the read attempts in case of failures.
>> + */
>> + if (rtlpriv->rtlhal.interface == INTF_PCI)
>> + max_attempts = 10000;
>> + else
>> + max_attempts = 10;
>
> As your comment, setting max_atttempts to 10 under condition of INTF_USB would
> be more reasonable, like
>
> u16 max_attempts = 10000;
>
> if (rtlpriv->rtlhal.interface == INTF_USB)
> max_attempts = 10;
>
OK, thanks.
V4 just sent:
https://lore.kernel.org/r/20241101193412.1390391-1-gpiccoli@xxxxxxxxxx