forked from len0rd/rockbox
sd-as3525v2: Set SD FIFO TX/RX watermarks once in init_controller() and leave them alone after that.
We only use DMA transfers so we should not need to change/reset the FIFO configuration. Also add comment showing what we set as the TX/RX watermarks. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25507 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
87eea33def
commit
f25f17c5b6
1 changed files with 2 additions and 5 deletions
|
|
@ -655,8 +655,8 @@ static void init_controller(void)
|
||||||
|
|
||||||
MCI_DEBNCE = 0xfffff; /* default value */
|
MCI_DEBNCE = 0xfffff; /* default value */
|
||||||
|
|
||||||
MCI_FIFOTH &= MCI_FIFOTH_MASK;
|
/* Rx watermark = 63(sd reads) Tx watermark = 128 (sd writes) */
|
||||||
MCI_FIFOTH |= 0x503f0080;
|
MCI_FIFOTH = (MCI_FIFOTH & MCI_FIFOTH_MASK) | 0x503f0080;
|
||||||
|
|
||||||
MCI_MASK = 0xffff & ~(MCI_INT_ACD|MCI_INT_CRDDET|MCI_INT_RXDR|MCI_INT_TXDR);
|
MCI_MASK = 0xffff & ~(MCI_INT_ACD|MCI_INT_CRDDET|MCI_INT_RXDR|MCI_INT_TXDR);
|
||||||
|
|
||||||
|
|
@ -820,9 +820,6 @@ static int sd_transfer_sectors(IF_MD2(int drive,) unsigned long start,
|
||||||
MCI_MASK |= (MCI_DATA_ERROR | MCI_INT_DTO);
|
MCI_MASK |= (MCI_DATA_ERROR | MCI_INT_DTO);
|
||||||
MCI_CTRL |= DMA_ENABLE;
|
MCI_CTRL |= DMA_ENABLE;
|
||||||
|
|
||||||
MCI_FIFOTH &= MCI_FIFOTH_MASK;
|
|
||||||
MCI_FIFOTH |= 0x503f0080;
|
|
||||||
|
|
||||||
int arg = start;
|
int arg = start;
|
||||||
if(!(card_info[drive].ocr & (1<<30))) /* not SDHC */
|
if(!(card_info[drive].ocr & (1<<30))) /* not SDHC */
|
||||||
arg *= SD_BLOCK_SIZE;
|
arg *= SD_BLOCK_SIZE;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue