mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
To: Alexander Kurz <akurz@blala.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 0/2] spi: imx: don't loop endlessly
Date: Mon, 2 Oct 2017 07:31:23 +0200	[thread overview]
Message-ID: <20171002053123.tphz7c44xofordvk@pengutronix.de> (raw)
In-Reply-To: <alpine.DEB.2.00.1709291955001.32464@blala.de>

On Fri, Sep 29, 2017 at 08:08:28PM +0200, Alexander Kurz wrote:
> Hi,
> during xchg_single 32 bits will be sent and received:
> 2x32 bits / 10 Microseconds = 6.4MHz Clock.

why 2x?

> Hence, a 10 Microseconds timeout will break SPI communication for
> boards with SPI frequencies less then 6.4MHz.
> On some boards spi-max-frequency is limited due to improper communication
> at higher frequencies, e.g. for the kindle4 it is 1MHz and there 
> also exists one board with 100kHz.
> 
> Before sending a patch calculating the timeout from spi-max-frequency,
> is 640 Microseconds (to fit imx28-cfa10049.dts 100kHz) acceptable?

I would expect that the hardware and software add some latency, so maybe
round it up to 1 ms?

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      reply	other threads:[~2017-10-02  5:31 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-02 19:39 Uwe Kleine-König
2017-08-02 19:39 ` [PATCH 1/2] spi: imx: add error checking Uwe Kleine-König
2017-08-02 19:39 ` [PATCH 2/2] spi: imx: add timeout to xchg_single Uwe Kleine-König
2017-08-02 19:54 ` [PATCH 0/2] spi: imx: don't loop endlessly Sam Ravnborg
2017-08-02 20:19   ` Uwe Kleine-König
2017-08-02 20:32     ` Sam Ravnborg
2017-08-03  9:07       ` Uwe Kleine-König
2017-08-03 10:43         ` Sam Ravnborg
2017-08-03 18:41       ` Uwe Kleine-König
2017-09-29 18:08 ` Alexander Kurz
2017-10-02  5:31   ` Uwe Kleine-König [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=20171002053123.tphz7c44xofordvk@pengutronix.de \
    --to=u.kleine-koenig@pengutronix.de \
    --cc=akurz@blala.de \
    --cc=barebox@lists.infradead.org \
    /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