[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <87czbz1to6.fsf@tarshish>
Date: Tue, 13 Sep 2022 12:54:26 +0300
From: Baruch Siach <baruch@...s.co.il>
To: "Russell King (Oracle)" <linux@...linux.org.uk>
Cc: netdev@...r.kernel.org, Andrew Lunn <andrew@...n.ch>,
Baruch Siach <baruch.siach@...lu.com>
Subject: Re: [PATCH] net: sfp: workaround GPIO input signals bounce
Hi Russell,
On Tue, Sep 13 2022, Russell King (Oracle) wrote:
> On Tue, Sep 13, 2022 at 10:43:38AM +0300, Baruch Siach wrote:
>> From: Baruch Siach <baruch.siach@...lu.com>
>>
>> Add a trivial debounce to avoid miss of state changes when there is no
>> proper hardware debounce on the input signals. Otherwise a GPIO might
>> randomly indicate high level when the signal is actually going down,
>> and vice versa.
>>
>> This fixes observed miss of link up event when LOS signal goes down on
>> Armada 8040 based system with an optical SFP module.
>
> NAK. This needs more inteligent handling. For systems where we poll,
> your code introduces a 100us delay each time we poll and there has
> been no change.
I think we can avoid delay in the poll case by skipping the delay loop
when sfp->need_poll is true.
I'll send v2 with that fixed tomorrow.
Thanks for reviewing,
baruch
--
~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch@...s.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
Powered by blists - more mailing lists