diff options
author | Jaehoon Chung <jh80.chung@samsung.com> | 2012-01-11 04:28:21 -0500 |
---|---|---|
committer | Chris Ball <cjb@laptop.org> | 2012-01-12 15:17:16 -0500 |
commit | 8234e86960b07f5a3cf9973de3f9ba9a50450464 (patch) | |
tree | eea2ad109fe9d5cec12fd224e73973c49934fce3 | |
parent | 069c9f142822d552ec885572945d8bce9eff0519 (diff) |
mmc: dw_mmc: miscaculated the fifo-depth with wrong bit operation
In FIFOTH register, the RX_WMark field (bits[27:16]) defaults to
FIFO_DEPTH - 1. When reading it, bits[26:16] were being used, so
fix it to use the mask 0xfff instead of 0x7ff.
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Reviewed-by: James Hogan <james.hogan@imgtec.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
-rw-r--r-- | drivers/mmc/host/dw_mmc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mmc/host/dw_mmc.c b/drivers/mmc/host/dw_mmc.c index 94e223825a45..0e342793ff14 100644 --- a/drivers/mmc/host/dw_mmc.c +++ b/drivers/mmc/host/dw_mmc.c | |||
@@ -1949,7 +1949,7 @@ static int dw_mci_probe(struct platform_device *pdev) | |||
1949 | * should put it in the platform data. | 1949 | * should put it in the platform data. |
1950 | */ | 1950 | */ |
1951 | fifo_size = mci_readl(host, FIFOTH); | 1951 | fifo_size = mci_readl(host, FIFOTH); |
1952 | fifo_size = 1 + ((fifo_size >> 16) & 0x7ff); | 1952 | fifo_size = 1 + ((fifo_size >> 16) & 0xfff); |
1953 | } else { | 1953 | } else { |
1954 | fifo_size = host->pdata->fifo_depth; | 1954 | fifo_size = host->pdata->fifo_depth; |
1955 | } | 1955 | } |