summaryrefslogtreecommitdiff
path: root/drivers/mmc/sh_mmcif.h
diff options
context:
space:
mode:
authorNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>2014-12-03 17:57:01 +0900
committerNobuhiro Iwamatsu <iwamatsu@nigauri.org>2014-12-05 11:15:52 +0900
commit7a7eb983a4cd7531843de875572bf5a1c96297ca (patch)
treeb4a74e7b876fafdf8941de8683421ddea8f84f6d /drivers/mmc/sh_mmcif.h
parent21ea350385149e0e96c51b2cac5e91cd4fd143bc (diff)
downloadu-boot-imx-7a7eb983a4cd7531843de875572bf5a1c96297ca.zip
u-boot-imx-7a7eb983a4cd7531843de875572bf5a1c96297ca.tar.gz
u-boot-imx-7a7eb983a4cd7531843de875572bf5a1c96297ca.tar.bz2
mmc: sh_mmcif: Change maximum and minimum value of MMC clock
Maximum value and the minimum value of clock for sh_mmcif instead by base of MMC clock. This removes fixed clock, make the changes to be calculated according to environment. Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com> Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Diffstat (limited to 'drivers/mmc/sh_mmcif.h')
-rw-r--r--drivers/mmc/sh_mmcif.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/mmc/sh_mmcif.h b/drivers/mmc/sh_mmcif.h
index bd6fbf7..70034e2 100644
--- a/drivers/mmc/sh_mmcif.h
+++ b/drivers/mmc/sh_mmcif.h
@@ -199,7 +199,8 @@ struct sh_mmcif_regs {
#define SOFT_RST_OFF (0 << 31)
#define CLKDEV_EMMC_DATA 52000000 /* 52MHz */
-#define CLKDEV_MMC_INIT 400000 /* 100 - 400 KHz */
+#define MMC_CLK_DIV_MIN(clk) (clk / (1 << 8))
+#define MMC_CLK_DIV_MAX CLKDEV_EMMC_DATA
#define MMC_BUS_WIDTH_1 0
#define MMC_BUS_WIDTH_4 2