diff options
Diffstat (limited to 'drivers/mmc/au1xmmc.c')
-rw-r--r-- | drivers/mmc/au1xmmc.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/mmc/au1xmmc.c b/drivers/mmc/au1xmmc.c index c0326bbc5f28..5dc4bee7abeb 100644 --- a/drivers/mmc/au1xmmc.c +++ b/drivers/mmc/au1xmmc.c | |||
@@ -310,7 +310,7 @@ static void au1xmmc_data_complete(struct au1xmmc_host *host, u32 status) | |||
310 | } | 310 | } |
311 | else | 311 | else |
312 | data->bytes_xfered = | 312 | data->bytes_xfered = |
313 | (data->blocks * (1 << data->blksz_bits)) - | 313 | (data->blocks * data->blksz) - |
314 | host->pio.len; | 314 | host->pio.len; |
315 | } | 315 | } |
316 | 316 | ||
@@ -575,7 +575,7 @@ static int | |||
575 | au1xmmc_prepare_data(struct au1xmmc_host *host, struct mmc_data *data) | 575 | au1xmmc_prepare_data(struct au1xmmc_host *host, struct mmc_data *data) |
576 | { | 576 | { |
577 | 577 | ||
578 | int datalen = data->blocks * (1 << data->blksz_bits); | 578 | int datalen = data->blocks * data->blksz; |
579 | 579 | ||
580 | if (dma != 0) | 580 | if (dma != 0) |
581 | host->flags |= HOST_F_DMA; | 581 | host->flags |= HOST_F_DMA; |
@@ -596,7 +596,7 @@ au1xmmc_prepare_data(struct au1xmmc_host *host, struct mmc_data *data) | |||
596 | if (host->dma.len == 0) | 596 | if (host->dma.len == 0) |
597 | return MMC_ERR_TIMEOUT; | 597 | return MMC_ERR_TIMEOUT; |
598 | 598 | ||
599 | au_writel((1 << data->blksz_bits) - 1, HOST_BLKSIZE(host)); | 599 | au_writel(data->blksz - 1, HOST_BLKSIZE(host)); |
600 | 600 | ||
601 | if (host->flags & HOST_F_DMA) { | 601 | if (host->flags & HOST_F_DMA) { |
602 | int i; | 602 | int i; |
@@ -720,10 +720,6 @@ static void au1xmmc_set_ios(struct mmc_host* mmc, struct mmc_ios* ios) | |||
720 | { | 720 | { |
721 | struct au1xmmc_host *host = mmc_priv(mmc); | 721 | struct au1xmmc_host *host = mmc_priv(mmc); |
722 | 722 | ||
723 | DBG("set_ios (power=%u, clock=%uHz, vdd=%u, mode=%u)\n", | ||
724 | host->id, ios->power_mode, ios->clock, ios->vdd, | ||
725 | ios->bus_mode); | ||
726 | |||
727 | if (ios->power_mode == MMC_POWER_OFF) | 723 | if (ios->power_mode == MMC_POWER_OFF) |
728 | au1xmmc_set_power(host, 0); | 724 | au1xmmc_set_power(host, 0); |
729 | else if (ios->power_mode == MMC_POWER_ON) { | 725 | else if (ios->power_mode == MMC_POWER_ON) { |