add At91SAM9260 SDIO highspeed and SDIO IRQ capability, fixed compiling warnning

This commit is contained in:
weety 2013-04-02 20:42:11 +08:00
parent 0594734d8d
commit e7885df2f1
1 changed files with 5 additions and 4 deletions

View File

@ -340,7 +340,7 @@ static void at91_mci_send_command(struct at91_mci *mci, struct rt_mmcsd_cmd *cmd
* Handle a read
*/
mmu_invalidate_dcache(data->buf, data->blksize*data->blks);
mmu_invalidate_dcache((rt_uint32_t)data->buf, data->blksize*data->blks);
at91_mci_init_dma_read(mci);
ier = AT91_MCI_ENDRX /* | AT91_MCI_RXBUFF */;
}
@ -367,14 +367,14 @@ static void at91_mci_send_command(struct at91_mci *mci, struct rt_mmcsd_cmd *cmd
}
rt_memset(mci->buf, 0, 12);
rt_memcpy(mci->buf, data->buf, length);
mmu_clean_dcache(mci->buf, length);
mmu_clean_dcache((rt_uint32_t)mci->buf, length);
at91_mci_write(AT91_PDC_TPR, (rt_uint32_t)(mci->buf));
at91_mci_write(AT91_PDC_TCR, (data->blksize & 0x3) ?
length : length / 4);
}
else
{
mmu_clean_dcache(data->buf, data->blksize*data->blks);
mmu_clean_dcache((rt_uint32_t)data->buf, data->blksize*data->blks);
at91_mci_write(AT91_PDC_TPR, (rt_uint32_t)(data->buf));
at91_mci_write(AT91_PDC_TCR, (data->blksize & 0x3) ?
length : length / 4);
@ -848,7 +848,8 @@ rt_int32_t at91_mci_init(void)
host->freq_min = 375000;
host->freq_max = 25000000;
host->valid_ocr = VDD_32_33 | VDD_33_34;
host->flags = MMCSD_BUSWIDTH_4 | MMCSD_MUTBLKWRITE;
host->flags = MMCSD_BUSWIDTH_4 | MMCSD_MUTBLKWRITE | \
MMCSD_SUP_HIGHSPEED | MMCSD_SUP_SDIO_IRQ;
host->max_seg_size = 65535;
host->max_dma_segs = 2;
host->max_blk_size = 512;