[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210413201740.GC2751@kunai>
Date: Tue, 13 Apr 2021 22:17:40 +0200
From: Wolfram Sang <wsa@...-dreams.de>
To: Qii Wang <qii.wang@...iatek.com>
Cc: matthias.bgg@...il.com, linux-i2c@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
linux-mediatek@...ts.infradead.org, srv_heupstream@...iatek.com,
leilk.liu@...iatek.com
Subject: Re: [RESEND] i2c: mediatek: Get device clock-stretch time via dts
On Mon, Apr 12, 2021 at 08:03:14PM +0800, Qii Wang wrote:
> On Wed, 2021-04-07 at 20:19 +0200, Wolfram Sang wrote:
> > > Due to clock stretch, our HW IP cannot meet the ac-timing
> > > spec(tSU;STA,tSU;STO).
> > > There isn't a same delay for clock stretching, so we need pass a
> > > parameter which can be found through measurement to meet most
> > > conditions.
> >
> > What about using this existing binding?
> >
> > - i2c-scl-internal-delay-ns
> > Number of nanoseconds the IP core additionally needs to setup SCL.
> >
>
> I can't see the relationship between "i2c-scl-falling-time-ns" and clock
> stretching, is there a parameter related to clock stretching?
( you wrote "i2c-scl-falling-time-ns" above, didn't you mean
"i2c-scl-internal-delay-ns" instead? )
Not yet, and I wonder if there can be one. In I2C (not SMBus), devices
are allowed to stretch the clock as long as they want, so what should be
specified here?
I suggesteed "internal-delay" because AFAIU your hardware needs this
delay to be able to cope with clock stretching.
> If you think both of them will affect the ac-timing of SCL, at this
> point, "i2c-scl-falling-time-ns" maybe a good choice.
Do you mean "i2c-scl-falling-time-ns" or "i2c-scl-internal-delay-ns"?
Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)
Powered by blists - more mailing lists