• Home
  • Raw
  • Download

Lines Matching refs:base

93 static inline void sh_mmcif_boot_cmd_send(void __iomem *base,  in sh_mmcif_boot_cmd_send()  argument
96 sh_mmcif_writel(base, MMCIF_CE_INT, 0); in sh_mmcif_boot_cmd_send()
97 sh_mmcif_writel(base, MMCIF_CE_ARG, arg); in sh_mmcif_boot_cmd_send()
98 sh_mmcif_writel(base, MMCIF_CE_CMD_SET, cmd); in sh_mmcif_boot_cmd_send()
101 static inline int sh_mmcif_boot_cmd_poll(void __iomem *base, unsigned long mask) in sh_mmcif_boot_cmd_poll() argument
107 tmp = sh_mmcif_readl(base, MMCIF_CE_INT); in sh_mmcif_boot_cmd_poll()
109 sh_mmcif_writel(base, MMCIF_CE_INT, tmp & ~mask); in sh_mmcif_boot_cmd_poll()
117 static inline int sh_mmcif_boot_cmd(void __iomem *base, in sh_mmcif_boot_cmd() argument
120 sh_mmcif_boot_cmd_send(base, cmd, arg); in sh_mmcif_boot_cmd()
121 return sh_mmcif_boot_cmd_poll(base, 0x00010000); in sh_mmcif_boot_cmd()
124 static inline int sh_mmcif_boot_do_read_single(void __iomem *base, in sh_mmcif_boot_do_read_single() argument
131 sh_mmcif_boot_cmd(base, 0x0d400000, 0x00010000); in sh_mmcif_boot_do_read_single()
133 if (sh_mmcif_readl(base, MMCIF_CE_RESP0) != 0x0900) in sh_mmcif_boot_do_read_single()
137 sh_mmcif_boot_cmd(base, 0x11480000, block_nr * SH_MMCIF_BBS); in sh_mmcif_boot_do_read_single()
138 if (sh_mmcif_boot_cmd_poll(base, 0x00100000) < 0) in sh_mmcif_boot_do_read_single()
142 buf[k] = sh_mmcif_readl(base, MMCIF_CE_DATA); in sh_mmcif_boot_do_read_single()
147 static inline int sh_mmcif_boot_do_read(void __iomem *base, in sh_mmcif_boot_do_read() argument
156 sh_mmcif_writel(base, MMCIF_CE_CLK_CTRL, in sh_mmcif_boot_do_read()
161 sh_mmcif_boot_cmd(base, 0x09806000, 0x00010000); in sh_mmcif_boot_do_read()
164 sh_mmcif_boot_cmd(base, 0x07400000, 0x00010000); in sh_mmcif_boot_do_read()
167 sh_mmcif_boot_cmd(base, 0x10400000, SH_MMCIF_BBS); in sh_mmcif_boot_do_read()
170 ret = sh_mmcif_boot_do_read_single(base, first_block + k, in sh_mmcif_boot_do_read()
176 static inline void sh_mmcif_boot_init(void __iomem *base) in sh_mmcif_boot_init() argument
179 sh_mmcif_writel(base, MMCIF_CE_VERSION, SOFT_RST_ON); in sh_mmcif_boot_init()
180 sh_mmcif_writel(base, MMCIF_CE_VERSION, SOFT_RST_OFF); in sh_mmcif_boot_init()
183 sh_mmcif_writel(base, MMCIF_CE_BUF_ACC, BUF_ACC_ATYP); in sh_mmcif_boot_init()
186 sh_mmcif_writel(base, MMCIF_CE_BLOCK_SET, SH_MMCIF_BBS); in sh_mmcif_boot_init()
189 sh_mmcif_writel(base, MMCIF_CE_CLK_CTRL, in sh_mmcif_boot_init()
194 sh_mmcif_boot_cmd(base, 0x00000040, 0); in sh_mmcif_boot_init()
198 sh_mmcif_boot_cmd(base, 0x01405040, 0x40300000); /* CMD1 */ in sh_mmcif_boot_init()
199 } while ((sh_mmcif_readl(base, MMCIF_CE_RESP0) & 0x80000000) in sh_mmcif_boot_init()
203 sh_mmcif_boot_cmd(base, 0x02806040, 0); in sh_mmcif_boot_init()
206 sh_mmcif_boot_cmd(base, 0x03400040, 0x00010000); in sh_mmcif_boot_init()