public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Vignesh R <vigneshr@ti.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v1] cmd/sf: probe flash with speed of last known flash or speed from devicetree
Date: Wed, 24 Aug 2016 16:05:46 +0530	[thread overview]
Message-ID: <86295f5e-70ad-e660-4ff4-2046e12a6780@ti.com> (raw)
In-Reply-To: <1472033154-31475-1-git-send-email-oe5hpm@oevsv.at>

Hi,

On Wednesday 24 August 2016 03:35 PM, Hannes Schmelzer wrote:
> During probing flashes on the spi bus using the "sf probe" command, a
> maybe existing flash (from fdt) is unbound and removed to force the
> 'spi_flash_probe_bus_cs' really scanning the bus.
> 
> Today the bus is probed with speed 0, this triggers several fall-back
> mechanism (mostly in the low-level drivers) to catch the impossible zero
> speed.
> Result of this is, that the spi-flash runs at very low speed depending
> on the minimum given by low-level driver/hardware.
> 
> Values like 'spi-max-frequency' from devicetree are ignored totally
> today.
> 
> This commit changes as following:
> - if there was already some flash binding in devicetree (having some
>   spi-max-frequency within) speed is taken from it
> - if no flash binding was present for speed the 'spi-max-frequency' from
>   the responsible spi node is taken.
> 
> Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>


With commit 96907c0fe50a8 ("dm: spi: Read default speed and mode values
from DT") sf probe picks spi-max-frequency from DT if not specified as
argument.

But when sf probe is called second time, the command fails to pick up
speed from DT. This is because flash node is unbound from the SPI
controller children nodes. Below patch should fix this issue:
https://patchwork.ozlabs.org/patch/659979/



-- 
Regards
Vignesh

  reply	other threads:[~2016-08-24 10:35 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-24 10:05 [U-Boot] [PATCH v1] cmd/sf: probe flash with speed of last known flash or speed from devicetree Hannes Schmelzer
2016-08-24 10:35 ` Vignesh R [this message]
2016-08-24 10:51   ` Hannes Schmelzer
2016-08-24 11:12     ` Vignesh R
2016-08-24 12:21       ` Hannes Schmelzer
2016-08-24 14:10         ` Hannes Schmelzer
2016-08-25  8:39           ` Vignesh R
2016-08-25  9:32             ` Hannes Schmelzer
2016-08-25 10:10               ` Vignesh R

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=86295f5e-70ad-e660-4ff4-2046e12a6780@ti.com \
    --to=vigneshr@ti.com \
    --cc=u-boot@lists.denx.de \
    /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