summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/pxamci.c
diff options
context:
space:
mode:
authorPavel Pisa <ppisa@pikron.com>2006-05-19 21:48:03 +0100
committerRussell King <rmk+kernel@arm.linux.org.uk>2006-05-19 21:48:03 +0100
commit2c171bf13423dc5293188cea7f6c2da1720926e2 (patch)
treed251705f564c8ffb081ba84c769fd2d1b229db53 /drivers/mmc/pxamci.c
parenta54c9d30dbb06391ec4422aaf0e1dc2c8c53bd3e (diff)
downloadlinux-stable-2c171bf13423dc5293188cea7f6c2da1720926e2.tar.gz
linux-stable-2c171bf13423dc5293188cea7f6c2da1720926e2.tar.bz2
linux-stable-2c171bf13423dc5293188cea7f6c2da1720926e2.zip
[ARM] 3531/1: i.MX/MX1 SD/MMC ensure, that clock are stopped before new command and cleanups
Patch from Pavel Pisa There has been problems that for some paths that clock are not stopped during new command programming and initiation. Result is issuing of incorrect command to the card. Some other problems are cleaned too. Noisy report of known ERRATUM #4 has been suppressed. Signed-off-by: Pavel Pisa <pisa@cmp.felk.cvut.cz> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/mmc/pxamci.c')
-rw-r--r--drivers/mmc/pxamci.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/pxamci.c b/drivers/mmc/pxamci.c
index f97b472085cb..b49368fd96b8 100644
--- a/drivers/mmc/pxamci.c
+++ b/drivers/mmc/pxamci.c
@@ -119,7 +119,7 @@ static void pxamci_setup_data(struct pxamci_host *host, struct mmc_data *data)
nob = 0xffff;
writel(nob, host->base + MMC_NOB);
- writel(1 << data->blksz_bits, host->base + MMC_BLKLEN);
+ writel(data->blksz, host->base + MMC_BLKLEN);
clks = (unsigned long long)data->timeout_ns * CLOCKRATE;
do_div(clks, 1000000000UL);
@@ -283,7 +283,7 @@ static int pxamci_data_done(struct pxamci_host *host, unsigned int stat)
* data blocks as being in error.
*/
if (data->error == MMC_ERR_NONE)
- data->bytes_xfered = data->blocks << data->blksz_bits;
+ data->bytes_xfered = data->blocks * data->blksz;
else
data->bytes_xfered = 0;