[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f9d933e5-1272-b479-b09a-f46f4a179905@kernel.org>
Date: Thu, 5 Nov 2020 17:41:30 +0100
From: Jiri Slaby <jirislaby@...nel.org>
To: David Laight <David.Laight@...LAB.COM>,
Lee Jones <lee.jones@...aro.org>
Cc: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"paulkf@...rogate.com" <paulkf@...rogate.com>
Subject: Re: [PATCH 27/36] tty: synclinkmp: Mark never checked 'readval' as
__always_unused
On 05. 11. 20, 12:04, David Laight wrote:
>>>> And the loop can be turned into ndelay:
>>>>
>>>> /*
>>>> * Force at least 170ns delay before clearing
>>>> * reset bit. Each read from LCR takes at least
>>>> * 30ns so 10 times for 300ns to be safe.
>>>> */
>>>> for(i=0;i<10;i++)
>>>> readval = *MiscCtrl;
>>>
>>> Again, since I can't test this, I do not want this patch to contain
>>> any functional changes. AFAIC, the 10 register reads must still
>>> happen after this patch is applied.
>
> You can't use ndelay(); the writes can get posted so can appear
> much closer together by the time they get to the actual hardware.
Ah, indeed, this is on PCI. One read would need to stay before ndelay
then. But given it completely goes away, no need to worry. Thanks for
heads up.
--
js
suse labs
Powered by blists - more mailing lists