• Home
  • Raw
  • Download

Lines Matching refs:base

106 static inline void sh_mmcif_boot_cmd_send(void __iomem *base,  in sh_mmcif_boot_cmd_send()  argument
109 sh_mmcif_writel(base, MMCIF_CE_INT, 0); in sh_mmcif_boot_cmd_send()
110 sh_mmcif_writel(base, MMCIF_CE_ARG, arg); in sh_mmcif_boot_cmd_send()
111 sh_mmcif_writel(base, MMCIF_CE_CMD_SET, cmd); in sh_mmcif_boot_cmd_send()
114 static inline int sh_mmcif_boot_cmd_poll(void __iomem *base, unsigned long mask) in sh_mmcif_boot_cmd_poll() argument
120 tmp = sh_mmcif_readl(base, MMCIF_CE_INT); in sh_mmcif_boot_cmd_poll()
122 sh_mmcif_writel(base, MMCIF_CE_INT, tmp & ~mask); in sh_mmcif_boot_cmd_poll()
130 static inline int sh_mmcif_boot_cmd(void __iomem *base, in sh_mmcif_boot_cmd() argument
133 sh_mmcif_boot_cmd_send(base, cmd, arg); in sh_mmcif_boot_cmd()
134 return sh_mmcif_boot_cmd_poll(base, 0x00010000); in sh_mmcif_boot_cmd()
137 static inline int sh_mmcif_boot_do_read_single(void __iomem *base, in sh_mmcif_boot_do_read_single() argument
144 sh_mmcif_boot_cmd(base, 0x0d400000, 0x00010000); in sh_mmcif_boot_do_read_single()
146 if (sh_mmcif_readl(base, MMCIF_CE_RESP0) != 0x0900) in sh_mmcif_boot_do_read_single()
150 sh_mmcif_boot_cmd(base, 0x11480000, block_nr * SH_MMCIF_BBS); in sh_mmcif_boot_do_read_single()
151 if (sh_mmcif_boot_cmd_poll(base, 0x00100000) < 0) in sh_mmcif_boot_do_read_single()
155 buf[k] = sh_mmcif_readl(base, MMCIF_CE_DATA); in sh_mmcif_boot_do_read_single()
160 static inline int sh_mmcif_boot_do_read(void __iomem *base, in sh_mmcif_boot_do_read() argument
169 sh_mmcif_writel(base, MMCIF_CE_CLK_CTRL, in sh_mmcif_boot_do_read()
174 sh_mmcif_boot_cmd(base, 0x09806000, 0x00010000); in sh_mmcif_boot_do_read()
177 sh_mmcif_boot_cmd(base, 0x07400000, 0x00010000); in sh_mmcif_boot_do_read()
180 sh_mmcif_boot_cmd(base, 0x10400000, SH_MMCIF_BBS); in sh_mmcif_boot_do_read()
183 ret = sh_mmcif_boot_do_read_single(base, first_block + k, in sh_mmcif_boot_do_read()
189 static inline void sh_mmcif_boot_init(void __iomem *base) in sh_mmcif_boot_init() argument
192 sh_mmcif_writel(base, MMCIF_CE_VERSION, SOFT_RST_ON); in sh_mmcif_boot_init()
193 sh_mmcif_writel(base, MMCIF_CE_VERSION, SOFT_RST_OFF); in sh_mmcif_boot_init()
196 sh_mmcif_writel(base, MMCIF_CE_BUF_ACC, BUF_ACC_ATYP); in sh_mmcif_boot_init()
199 sh_mmcif_writel(base, MMCIF_CE_BLOCK_SET, SH_MMCIF_BBS); in sh_mmcif_boot_init()
202 sh_mmcif_writel(base, MMCIF_CE_CLK_CTRL, in sh_mmcif_boot_init()
207 sh_mmcif_boot_cmd(base, 0x00000040, 0); in sh_mmcif_boot_init()
211 sh_mmcif_boot_cmd(base, 0x01405040, 0x40300000); /* CMD1 */ in sh_mmcif_boot_init()
212 } while ((sh_mmcif_readl(base, MMCIF_CE_RESP0) & 0x80000000) in sh_mmcif_boot_init()
216 sh_mmcif_boot_cmd(base, 0x02806040, 0); in sh_mmcif_boot_init()
219 sh_mmcif_boot_cmd(base, 0x03400040, 0x00010000); in sh_mmcif_boot_init()