summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBertrik Sikken <bertrik@sikken.nl>2011-03-26 19:52:42 +0000
committerBertrik Sikken <bertrik@sikken.nl>2011-03-26 19:52:42 +0000
commit2543340bf4ee69f9005b14e5fb335187125a5e94 (patch)
tree16ad184f36cd5f34b4f057d64fad8ef6365f8155
parentd9bc251de1fd9a34b34bff44c6cd76659ea96c98 (diff)
downloadrockbox-2543340bf4ee69f9005b14e5fb335187125a5e94.tar.gz
rockbox-2543340bf4ee69f9005b14e5fb335187125a5e94.zip
AMSv2 SD: sd card communication speed can be changed back to full speed after CMD3 (SEND_RCA)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29647 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--firmware/target/arm/as3525/sd-as3525v2.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/firmware/target/arm/as3525/sd-as3525v2.c b/firmware/target/arm/as3525/sd-as3525v2.c
index c87a15ea09..6d07bcca97 100644
--- a/firmware/target/arm/as3525/sd-as3525v2.c
+++ b/firmware/target/arm/as3525/sd-as3525v2.c
@@ -546,6 +546,9 @@ static int sd_init_card(const int drive)
546#endif 546#endif
547 /* End of Card Identification Mode ************************************/ 547 /* End of Card Identification Mode ************************************/
548 548
549 /* Card back to full speed */
550 MCI_CLKDIV &= ~(0xFF); /* CLK_DIV_0 : bits 7:0 = 0x00 */
551
549 if (sd_v2) 552 if (sd_v2)
550 { 553 {
551 /* Attempt to switch cards to HS timings, non HS cards just ignore this */ 554 /* Attempt to switch cards to HS timings, non HS cards just ignore this */
@@ -585,9 +588,6 @@ static int sd_init_card(const int drive)
585 if(drive == INTERNAL_AS3525) /* The OF is stored in the first blocks */ 588 if(drive == INTERNAL_AS3525) /* The OF is stored in the first blocks */
586 card_info[INTERNAL_AS3525].numblocks -= AMS_OF_SIZE; 589 card_info[INTERNAL_AS3525].numblocks -= AMS_OF_SIZE;
587 590
588 /* Card back to full speed */
589 MCI_CLKDIV &= ~(0xFF); /* CLK_DIV_0 : bits 7:0 = 0x00 */
590
591 /* CMD7 w/rca: Select card to put it in TRAN state */ 591 /* CMD7 w/rca: Select card to put it in TRAN state */
592 if(!send_cmd(drive, SD_SELECT_CARD, card_info[drive].rca, MCI_RESP, &response)) 592 if(!send_cmd(drive, SD_SELECT_CARD, card_info[drive].rca, MCI_RESP, &response))
593 return -12; 593 return -12;