mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Guilherme G. Piccoli" <gpiccoli@igalia.com>
To: Ping-Ke Shih <pkshih@realtek.com>
Cc: "kvalo@kernel.org" <kvalo@kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"kernel@gpiccoli.net" <kernel@gpiccoli.net>,
	"kernel-dev@igalia.com" <kernel-dev@igalia.com>,
	"rtl8821cerfe2@gmail.com" <rtl8821cerfe2@gmail.com>,
	"stable@vger.kernel.org" <stable@vger.kernel.org>,
	"syzbot+edd9fe0d3a65b14588d5@syzkaller.appspotmail.com"
	<syzbot+edd9fe0d3a65b14588d5@syzkaller.appspotmail.com>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH V3] wifi: rtlwifi: Drastically reduce the attempts to read efuse in case of failures
Date: Fri, 1 Nov 2024 16:38:32 -0300	[thread overview]
Message-ID: <a7d85678-c242-6a92-55d3-bb593e508f28@igalia.com> (raw)
In-Reply-To: <8363b94ee45c49c0996b12010c18b9f0@realtek.com>

>> [...]
>>         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@igalia.com





      reply	other threads:[~2024-11-01 19:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-31 15:55 Guilherme G. Piccoli
2024-11-01  2:26 ` Ping-Ke Shih
2024-11-01 19:29   ` Guilherme G. Piccoli
2024-11-01  4:22 ` Ping-Ke Shih
2024-11-01 19:38   ` Guilherme G. Piccoli [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a7d85678-c242-6a92-55d3-bb593e508f28@igalia.com \
    --to=gpiccoli@igalia.com \
    --cc=kernel-dev@igalia.com \
    --cc=kernel@gpiccoli.net \
    --cc=kvalo@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=pkshih@realtek.com \
    --cc=rtl8821cerfe2@gmail.com \
    --cc=stable@vger.kernel.org \
    --cc=syzbot+edd9fe0d3a65b14588d5@syzkaller.appspotmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®