Lines Matching refs:io_base
221 void __iomem *io_base; member
243 writel(SLCCTRL_SW_RESET, SLC_CTRL(host->io_base)); in lpc32xx_nand_setup()
247 writel(0, SLC_CFG(host->io_base)); in lpc32xx_nand_setup()
248 writel(0, SLC_IEN(host->io_base)); in lpc32xx_nand_setup()
250 SLC_ICR(host->io_base)); in lpc32xx_nand_setup()
266 writel(tmp, SLC_TAC(host->io_base)); in lpc32xx_nand_setup()
279 tmp = readl(SLC_CFG(host->io_base)); in lpc32xx_nand_cmd_ctrl()
284 writel(tmp, SLC_CFG(host->io_base)); in lpc32xx_nand_cmd_ctrl()
288 writel(cmd, SLC_CMD(host->io_base)); in lpc32xx_nand_cmd_ctrl()
290 writel(cmd, SLC_ADDR(host->io_base)); in lpc32xx_nand_cmd_ctrl()
302 if ((readl(SLC_STAT(host->io_base)) & SLCSTAT_NAND_READY) != 0) in lpc32xx_nand_device_ready()
355 return (uint8_t)readl(SLC_DATA(host->io_base)); in lpc32xx_nand_read_byte()
367 *buf++ = (uint8_t)readl(SLC_DATA(host->io_base)); in lpc32xx_nand_read_buf()
380 writel((uint32_t)*buf++, SLC_DATA(host->io_base)); in lpc32xx_nand_write_buf()
511 writel(readl(SLC_CFG(host->io_base)) | in lpc32xx_xfer()
513 SLCCFG_DMA_BURST, SLC_CFG(host->io_base)); in lpc32xx_xfer()
515 writel((readl(SLC_CFG(host->io_base)) | in lpc32xx_xfer()
518 SLC_CFG(host->io_base)); in lpc32xx_xfer()
522 writel(SLCCTRL_ECC_CLEAR, SLC_CTRL(host->io_base)); in lpc32xx_xfer()
525 writel(mtd->writesize, SLC_TC(host->io_base)); in lpc32xx_xfer()
528 writel(readl(SLC_CTRL(host->io_base)) | SLCCTRL_DMA_START, in lpc32xx_xfer()
529 SLC_CTRL(host->io_base)); in lpc32xx_xfer()
557 if (readl(SLC_STAT(host->io_base)) & SLCSTAT_DMA_FIFO) { in lpc32xx_xfer()
560 while ((readl(SLC_STAT(host->io_base)) & SLCSTAT_DMA_FIFO) && in lpc32xx_xfer()
573 readl(SLC_ECC(host->io_base)); in lpc32xx_xfer()
578 if (readl(SLC_STAT(host->io_base)) & SLCSTAT_DMA_FIFO || in lpc32xx_xfer()
579 readl(SLC_TC(host->io_base))) { in lpc32xx_xfer()
586 writel(readl(SLC_CTRL(host->io_base)) & ~SLCCTRL_DMA_START, in lpc32xx_xfer()
587 SLC_CTRL(host->io_base)); in lpc32xx_xfer()
588 writel(readl(SLC_CFG(host->io_base)) & in lpc32xx_xfer()
590 SLCCFG_DMA_BURST), SLC_CFG(host->io_base)); in lpc32xx_xfer()
830 host->io_base = devm_ioremap_resource(&pdev->dev, rc); in lpc32xx_nand_probe()
831 if (IS_ERR(host->io_base)) in lpc32xx_nand_probe()
832 return PTR_ERR(host->io_base); in lpc32xx_nand_probe()
872 chip->legacy.IO_ADDR_R = SLC_DATA(host->io_base); in lpc32xx_nand_probe()
873 chip->legacy.IO_ADDR_W = SLC_DATA(host->io_base); in lpc32xx_nand_probe()
955 tmp = readl(SLC_CTRL(host->io_base)); in lpc32xx_nand_remove()
957 writel(tmp, SLC_CTRL(host->io_base)); in lpc32xx_nand_remove()
991 tmp = readl(SLC_CTRL(host->io_base)); in lpc32xx_nand_suspend()
993 writel(tmp, SLC_CTRL(host->io_base)); in lpc32xx_nand_suspend()