blob: d1c5d4f26a305549f26565461abe924dd48484fb [file] [log] [blame]
Jaehoon Chung7aff9672012-10-15 19:10:31 +00001/*
2 * (C) Copyright 2012 SAMSUNG Electronics
3 * Jaehoon Chung <jh80.chung@samsung.com>
4 *
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02005 * SPDX-License-Identifier: GPL-2.0+
Jaehoon Chung7aff9672012-10-15 19:10:31 +00006 */
7
8#define DWMCI_CLKSEL 0x09C
9#define DWMCI_SHIFT_0 0x0
10#define DWMCI_SHIFT_1 0x1
11#define DWMCI_SHIFT_2 0x2
12#define DWMCI_SHIFT_3 0x3
13#define DWMCI_SET_SAMPLE_CLK(x) (x)
14#define DWMCI_SET_DRV_CLK(x) ((x) << 16)
15#define DWMCI_SET_DIV_RATIO(x) ((x) << 24)
16
Rajeshwari Shinde70163092013-10-29 12:53:13 +053017#define EMMCP_MPSBEGIN0 0x1200
18#define EMMCP_SEND0 0x1204
19#define EMMCP_CTRL0 0x120C
20
21#define MPSCTRL_SECURE_READ_BIT (0x1<<7)
22#define MPSCTRL_SECURE_WRITE_BIT (0x1<<6)
23#define MPSCTRL_NON_SECURE_READ_BIT (0x1<<5)
24#define MPSCTRL_NON_SECURE_WRITE_BIT (0x1<<4)
25#define MPSCTRL_USE_FUSE_KEY (0x1<<3)
26#define MPSCTRL_ECB_MODE (0x1<<2)
27#define MPSCTRL_ENCRYPTION (0x1<<1)
28#define MPSCTRL_VALID (0x1<<0)
29
Amard8501212013-04-27 11:42:55 +053030#ifdef CONFIG_OF_CONTROL
31int exynos_dwmmc_init(const void *blob);
32#endif
33int exynos_dwmci_add_port(int index, u32 regbase, int bus_width, u32 clksel);