linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Ricardo Ribalda Delgado <ricardo.ribalda@uam.es>
To: Lorenz Kolb <lorenz@missinglinkelectronics.com>
Cc: joachim@missinglinkelectronics.com,
	dbrownell@users.sourceforge.net, Joachim Foerster <JOFT@gmx.de>,
	hp@axis.com, linuxppc-dev@ozlabs.org, mike@steroidmicros.com,
	pierre@ossman.eu, jan.nikitenko@gmail.com, john.linn@xilinx.com,
	linuxkernel@vger.kernel.org
Subject: Re: SD card over (xilinx_)SPI, timeout error while CID
Date: Thu, 11 Jun 2009 22:49:05 +0200	[thread overview]
Message-ID: <aa76a2be0906111349s2ff947eo35149ef14e29d05a@mail.gmail.com> (raw)
In-Reply-To: <4A316386.4020404@missinglinkelectronics.com>

Hello

  Thanks for your reply

> Is the I/O logged from within the Xilinx-SPI-Driver or from within the
> mmc-spi-layer?

It is take from inside the spi driver.

>
> The response to CMD10 seems quite strange to me. The R1 answer to that
> command says that everything is OK, so what is done next is that the 0xfe
> token will be expected by the mmc-spi-layer. Obviously that one is not
> received within the proper time (assuming your data-logging was done from
> within xilinx-spi-driver). Also be aware of printk() taking milliseconds =
for
> printing to console, within time critical routines that might not be the
> best choice for debugging.

I will retry tomorrow removing all the spi debug and report what happens.

>
> What frequency does Your SPI-Bus use?
>

33Mhz.... arghh. just checked is over the standard...  Tomorrow I will
test with a slower clk

>
> Also double check to completely disable the whole
>
> =A0if (spi->master->dev.parent->dma_mask) {
> =A0 =A0...
> =A0}
>
Tomorow morning i will double check it, but it was something we
removed from the very begining (we dont have dma for the spi and we
suppose it was an error)  In my last log check:

[   48.990098] mmc_spi spi1.0: SD/MMC host mmc0, no DMA, no WP, no
poweroff, cd polling





Anyway the problem is definitely here:

[   52.094569] mmc0: starting CMD10 arg 00000000 flags 000000b5
[   52.113755] mmc0:     blksz 16 blocks 1 flags 00000200 tsac 0 ms nsac 64
[   52.134240] mmc_spi spi1.0:   mmc_spi: CMD10, resp R1
[   52.152922] Xilinx SPI: cs on
[   52.169228] Spi  Transfer at 0x8A000000
[   52.186386] Sending 9 bytes
[   52.187978] ff 4a 00 00 00 00 1b ff ff
[   52.218225] Received 9 bytes
[   52.219911] ff ff ff ff ff ff ff ff 00
[   52.249970] mmc_spi spi1.0:     mmc_spi: read block, 16 bytes
[   52.269009] Xilinx SPI: cs on
[   52.285210] Spi  Transfer at 0x8A000000
[   52.302276] Sending 1 bytes
[   52.303867] ff
[   52.332598] Received 1 bytes
[   52.334287] ff
[   52.362345] Xilinx SPI: cs on
[   52.377675] Spi  Transfer at 0x8A000000
[   52.393815] Sending 1 bytes
[   52.395408] ff
[   52.422215] Received 1 bytes
[   52.423901] ff


It tries to read the cid and the only thing it get from the sd back
are 0xff. I have made it loop without timeout and I keep receiving
0xff


Also after the cid read the sd card dont reply to any command....
weird.  lets see tomorrow with a slower clk.


         Thanks for your commends


          Best regards


--=20
Ricardo Ribalda
http://www.eps.uam.es/~rribalda/

  reply	other threads:[~2009-06-11 20:56 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-05 15:34 SD card over (xilinx_)SPI, timeout error while CID Joachim Foerster
2009-06-05 21:15 ` John Linn
2009-06-06 15:14 ` Peter Korsgaard
2009-06-08 15:14   ` Lorenz Kolb
2009-06-09 17:26 ` Joachim Foerster
2009-06-11 19:15   ` Ricardo Ribalda Delgado
     [not found]   ` <aa76a2be0906111215j15933053rf128f1985a982ca0__26561.0047536486$1244748319$gmane$org@mail.gmail.com>
2009-06-11 20:05     ` Lorenz Kolb
2009-06-11 20:49       ` Ricardo Ribalda Delgado [this message]
2009-06-11 21:07         ` Wolfgang Denk
2009-06-11 21:16           ` Ricardo Ribalda Delgado

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=aa76a2be0906111349s2ff947eo35149ef14e29d05a@mail.gmail.com \
    --to=ricardo.ribalda@uam.es \
    --cc=JOFT@gmx.de \
    --cc=dbrownell@users.sourceforge.net \
    --cc=hp@axis.com \
    --cc=jan.nikitenko@gmail.com \
    --cc=joachim@missinglinkelectronics.com \
    --cc=john.linn@xilinx.com \
    --cc=linuxkernel@vger.kernel.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=lorenz@missinglinkelectronics.com \
    --cc=mike@steroidmicros.com \
    --cc=pierre@ossman.eu \
    /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;
as well as URLs for NNTP newsgroup(s).