Re: [Qemu-devel] [PATCH] Fix SPI SD emulation

2012-04-30 Thread Paul Brook
> >> If this command could be issued in transfer state maybe in addition to > >> IDLE_STATE you also need to set other bits (ADDRESS_ERROR, > >> COM_CRC_ERROR, ILLEGAL_COMMAND, ERASE_SEQ_ERROR) in MSB of R3 response? > > > > In theory, yes. I was thinking of a follow-up patch to move the spi > >

Re: [Qemu-devel] [PATCH] Fix SPI SD emulation

2012-04-29 Thread Igor Mitsyanko
On 29.04.2012 6:31 PM, Paul Brook wrote: -sd_adtc, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, +sd_adtc, sd_none, sd_bc, sd_bc, sd_none, sd_none, sd_bcr? not that it really matters though Err, probably. +case 58:/* CMD58: READ_OCR */ +if (!sd->spi) { +

Re: [Qemu-devel] [PATCH] Fix SPI SD emulation

2012-04-29 Thread Paul Brook
> > -sd_adtc, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, > > +sd_adtc, sd_none, sd_bc, sd_bc, sd_none, sd_none, > > sd_bcr? not that it really matters though Err, probably. > > +case 58:/* CMD58: READ_OCR */ > > +if (!sd->spi) { > > +goto bad_cm

Re: [Qemu-devel] [PATCH] Fix SPI SD emulation

2012-04-26 Thread Igor Mitsyanko
On 04/26/2012 01:12 AM, Paul Brook wrote: When in SPI mode, we give a bogus response to CMD8 (part of the SD physical spec v2). Fixing this also makes most drivers also issue CMD58. Despite some skeleton code in hw/ssi-sd.c this isn't actually implemented in hw/sd.h. CMD58 is valid in both idl

[Qemu-devel] [PATCH] Fix SPI SD emulation

2012-04-25 Thread Paul Brook
When in SPI mode, we give a bogus response to CMD8 (part of the SD physical spec v2). Fixing this also makes most drivers also issue CMD58. Despite some skeleton code in hw/ssi-sd.c this isn't actually implemented in hw/sd.h. CMD58 is valid in both idle and active states, so the hardcoded status