mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Alexander Aring <alex.aring@gmail.com>
Cc: barebox@lists.infradead.org
Subject: Re: raspberry pi mmc issue
Date: Tue, 15 Oct 2013 14:23:32 +0200	[thread overview]
Message-ID: <20131015122332.GI30088@pengutronix.de> (raw)
In-Reply-To: <20131015115116.GC2839@omega>

On Tue, Oct 15, 2013 at 01:51:17PM +0200, Alexander Aring wrote:
> Hi all,
> 
> I using a not mainlined raspberry pi qemu implementation [1] and tried to
> run barebox on it. All seems to working but if I probe the mmc with
> mci0.probe=1 qemu will crash on a assert on 4 byte assert [2].
> 
> I dig a little bit into the Datasheet of bcm2835 [3] which says:
> 
> "Contrary to Arasan™’s documentation the EMMC module registers can only
> be accessed as 32 bit registers, i.e. the two LSBs of the address are
> always zero."
> 
> Then I dig into the barebox bcm2835_mci implementation and found
> something [4]. We use there a readb on SDHCI_RESPONSE_0 which is not a
> 32 bit access. I just commented the if branch and it works.
> 
> Maybe this can make some errors on a real raspberry, too.
> 
> Maybe somebody knows a little bit more about mci and can help me to find
> a proper solution? Perhaps just make a 32 bit access and do some bit
> magic with masks and shifts?

Here the SD card works (both read and write). I can surely test a patch
converting this access into a 32bit access.

The only thing I realize here is that my 3.6.4 kernel fails to access
the SD card when barebox has accessed it before:

[    3.623861] mmc0: SD Status: Invalid Allocation Unit size.
[    3.635586] mmc0: error -110 whilst initialising SD card
[    3.724743] mmc0: SD Status: Invalid Allocation Unit size.
[    3.739073] mmc0: error -110 whilst initialising SD card
[    3.836341] mmc0: SD Status: Invalid Allocation Unit size.
[    3.847708] mmc0: error -110 whilst initialising SD card
[    3.965447] mmc0: read SD Status register (SSR) after 3 attempts
[    3.971483] mmc0: SD Status: Invalid Allocation Unit size.

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

  reply	other threads:[~2013-10-15 12:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-15 11:51 Alexander Aring
2013-10-15 12:23 ` Sascha Hauer [this message]
2013-10-15 18:31   ` Alexander Aring
2013-10-15 18:39     ` Andre Heider
2013-10-16  7:23       ` 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=20131015122332.GI30088@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=alex.aring@gmail.com \
    --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