From: Sascha Hauer <s.hauer@pengutronix.de>
To: joacim.zetterling@westermo.se
Cc: barebox@lists.infradead.org
Subject: Re: Boot using SPI-NOR device
Date: Wed, 8 Jul 2015 14:32:00 +0200 [thread overview]
Message-ID: <20150708123200.GH18700@pengutronix.de> (raw)
In-Reply-To: <OF2C7718AB.DA224B8D-ONC1257E7C.002375F3-C1257E7C.0023CCF2@beijer.se>
On Wed, Jul 08, 2015 at 08:31:02AM +0200, joacim.zetterling@westermo.se wrote:
> Hi
>
> I have some problem booting a linux from a spi-nor device (Spansion,
> s25fl512s). There is no trouble booting up barebox from the first
> partition.
> When I debugged our system (ARM based) I find out that when we probe the
> file system, we get -22 as a result code from a memmap(s->fd, PROT_READ)
> function call.
> With further investigations I see that memmap is set to 0 with no ops is
> defined, witch probably means that I do not have any memory mapped spi.
>
> I add my partitions like this
> addpart -n /dev/s25fl512s
> 2048k(barebox),24M(primary),24M(reserved),2048k(config),4096k(barebox-environment)
>
> And my dts section for the spi looks like this
> ...
> ...
> spi: spi@10600 {
> spi-flash@0 {
> #address-cells = <1>;
> #size-cells = <1>;
> compatible = "s25fl512s", "nor-jedec";
> spi-max-frequency = <20000000>;
> reg = <0>; /* Chip select 0 */
> };
> };
> ...
> ...
>
> I also have all the configurations for spi, mtd and env in place.
> And I have no issues reading/writing/erasing the spi flash.
>
> My simple question is. How do I enable memory mapped spi-nor support in
> barebox?
That's not possible because spi-nor is never memory mapped. The good
news is that you won't need this. What exactly are you doing to get the
memmap error? Are you trying to use the 'go' command to start something
from spi-nor? Use bootm instead.
Regards,
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next parent reply other threads:[~2015-07-08 12:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <OF2C7718AB.DA224B8D-ONC1257E7C.002375F3-C1257E7C.0023CCF2@beijer.se>
2015-07-08 12:32 ` Sascha Hauer [this message]
[not found] ` <OF33093548.0EB61029-ONC1257E7C.004A9EB9-C1257E7C.004A9EBC@beijer.se>
2015-07-09 6:52 ` Sascha Hauer
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=20150708123200.GH18700@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=joacim.zetterling@westermo.se \
/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