All of lore.kernel.org
 help / color / mirror / Atom feed
* au1100 MMC support
@ 2006-08-09 10:29 Rodolfo Giometti
  2006-08-09 13:32 ` Rodolfo Giometti
  0 siblings, 1 reply; 3+ messages in thread
From: Rodolfo Giometti @ 2006-08-09 10:29 UTC (permalink / raw)
  To: linux-mips

Hello,

I'm just working on MMC support for au1100 CPUs. I patched au1xmmc.c
in order to disable DMA support (which is different from au1200 and
au1100) and forcing PIO mode.

Both MMC controllers of au1200 and au1100 seems similar to me...

Here what I get when I insert the card:

   mmc0: clock 0Hz busmode 1 powermode 0 cs 0 Vdd 0 width 0
   mmc0: clock 0Hz busmode 1 powermode 1 cs 0 Vdd 23 width 0
   mmc0: clock 450000Hz busmode 1 powermode 2 cs 0 Vdd 23 width 0
   mmc0: clock 450000Hz busmode 1 powermode 2 cs 1 Vdd 23 width 0
   mmc0: starting CMD0 arg 00000000 flags 00000040
   mmc0: req done (CMD0): 0/0/0: 00000000 00000000 00000000 00000000
   mmc0: clock 450000Hz busmode 1 powermode 2 cs 0 Vdd 23 width 0
   mmc0: starting CMD55 arg 00000000 flags 00000015
   mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
   mmc0: starting CMD41 arg 00000000 flags 00000061
   mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
   mmc0: clock 450000Hz busmode 1 powermode 2 cs 0 Vdd 15 width 0
   mmc0: clock 450000Hz busmode 1 powermode 2 cs 1 Vdd 15 width 0
   mmc0: starting CMD0 arg 00000000 flags 00000040
   mmc0: req done (CMD0): 0/0/0: 00000000 00000000 00000000 00000000
   mmc0: clock 450000Hz busmode 1 powermode 2 cs 0 Vdd 15 width 0
   mmc0: starting CMD55 arg 00000000 flags 00000015
   mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
   mmc0: starting CMD41 arg 00018000 flags 00000061
   mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
   mmc0: starting CMD55 arg 00000000 flags 00000015
   mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
   mmc0: starting CMD41 arg 00018000 flags 00000061
   mmc0: req done (CMD41): 0/0/0: 80ff8000 00000000 00000000 00000000
   mmc0: starting CMD2 arg 00000000 flags 00000067
   mmc0: req done (CMD2): 0/0/0: 1d41444d 494e4953 10310001 9a005500
   mmc0: starting CMD3 arg 00000000 flags 00000065
   mmc0: req done (CMD3): 0/0/0: 019a0055 00000000 00000000 00000000
   mmc0: host does not support reading read-only switch. assuming write-enable.
   mmc0: starting CMD2 arg 00000000 flags 00000067
   mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: clock 450000Hz busmode 2 powermode 2 cs 0 Vdd 15 width 0
   mmc0: starting CMD9 arg 019a0000 flags 00000007
   mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
   mmc0: selected 24.000MHz transfer rate
   mmc0: clock 24000000Hz busmode 2 powermode 2 cs 0 Vdd 15 width 0
   mmc0: clock 0Hz busmode 1 powermode 0 cs 0 Vdd 0 width 0

It seems that the driver doesn't recognize the card.

Any suggestions? Do you think that the controller is talking with the
card?

Thanks,

Rodolfo

-- 

GNU/Linux Solutions                  e-mail:    giometti@enneenne.com
Linux Device Driver                             giometti@gnudd.com
Embedded Systems                     		giometti@linux.it
UNIX programming                     phone:     +39 349 2432127

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: au1100 MMC support
  2006-08-09 10:29 au1100 MMC support Rodolfo Giometti
@ 2006-08-09 13:32 ` Rodolfo Giometti
  2006-08-09 15:44   ` Rodolfo Giometti
  0 siblings, 1 reply; 3+ messages in thread
From: Rodolfo Giometti @ 2006-08-09 13:32 UTC (permalink / raw)
  To: linux-mips

On Wed, Aug 09, 2006 at 12:29:50PM +0200, Rodolfo Giometti wrote:
> 
>    mmc0: starting CMD2 arg 00000000 flags 00000067
>    mmc0: req done (CMD2): 0/0/0: 1d41444d 494e4953 10310001 9a005500

Ok. This the CID number.

>    mmc0: starting CMD3 arg 00000000 flags 00000065
>    mmc0: req done (CMD3): 0/0/0: 019a0055 00000000 00000000 00000000

And this is the RCA.

>    mmc0: host does not support reading read-only switch. assuming write-enable.
>    mmc0: starting CMD2 arg 00000000 flags 00000067
>    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
>    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
>    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
>    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
>    mmc0: clock 450000Hz busmode 2 powermode 2 cs 0 Vdd 15 width 0
>    mmc0: starting CMD9 arg 019a0000 flags 00000007
>    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
>    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
>    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
>    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000

Here is the problem! I get no answer to CMD9 (CSD request) due a
timeout (sd0_status=0x3028080).

Rodolfo

-- 

GNU/Linux Solutions                  e-mail:    giometti@enneenne.com
Linux Device Driver                             giometti@gnudd.com
Embedded Systems                     		giometti@linux.it
UNIX programming                     phone:     +39 349 2432127

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: au1100 MMC support
  2006-08-09 13:32 ` Rodolfo Giometti
@ 2006-08-09 15:44   ` Rodolfo Giometti
  0 siblings, 0 replies; 3+ messages in thread
From: Rodolfo Giometti @ 2006-08-09 15:44 UTC (permalink / raw)
  To: linux-mips

On Wed, Aug 09, 2006 at 03:32:40PM +0200, Rodolfo Giometti wrote:
> 
> >    mmc0: host does not support reading read-only switch. assuming write-enable.
> >    mmc0: starting CMD2 arg 00000000 flags 00000067
> >    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
> >    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
> >    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
> >    mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
> >    mmc0: clock 450000Hz busmode 2 powermode 2 cs 0 Vdd 15 width 0
> >    mmc0: starting CMD9 arg 019a0000 flags 00000007
> >    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
> >    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
> >    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
> >    mmc0: req done (CMD9): 1/0/0: 00000000 00000000 00000000 00000000
> 
> Here is the problem! I get no answer to CMD9 (CSD request) due a
> timeout (sd0_status=0x3028080).

Fixed. Here the patch in file drivers/mmc/au1xmmc.c:

           case MMC_RSP_R3:
                   mmccmd |= SD_CMD_RT_3;
                   break;
   +       case MMC_RSP_R6:
   +               mmccmd |= SD_CMD_RT_6;
   +               break;
           }
    
           switch(cmd->opcode) {

However the driver is still not functional since read/write operations
on the MMC are broken. :'(

Ciao,

Rodolfo

-- 

GNU/Linux Solutions                  e-mail:    giometti@enneenne.com
Linux Device Driver                             giometti@gnudd.com
Embedded Systems                     		giometti@linux.it
UNIX programming                     phone:     +39 349 2432127

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-08-09 15:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-08-09 10:29 au1100 MMC support Rodolfo Giometti
2006-08-09 13:32 ` Rodolfo Giometti
2006-08-09 15:44   ` Rodolfo Giometti

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.