Lines Matching refs:arasan_nand_base

57 #define arasan_nand_base ((struct nand_regs __iomem *)ARASAN_NAND_BASEADDR)  macro
268 reg_val = readl(&arasan_nand_base->memadr_reg2); in arasan_nand_select_chip()
271 writel(reg_val, &arasan_nand_base->memadr_reg2); in arasan_nand_select_chip()
274 writel(reg_val, &arasan_nand_base->memadr_reg2); in arasan_nand_select_chip()
282 reg_val = readl(&arasan_nand_base->cmd_reg); in arasan_nand_enable_ecc()
285 writel(reg_val, &arasan_nand_base->cmd_reg); in arasan_nand_enable_ecc()
343 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_read_page()
346 writel(reg_val, &arasan_nand_base->intsts_enr); in arasan_nand_read_page()
348 reg_val = readl(&arasan_nand_base->pkt_reg); in arasan_nand_read_page()
353 writel(reg_val, &arasan_nand_base->pkt_reg); in arasan_nand_read_page()
364 &arasan_nand_base->ecc_sprcmd_reg); in arasan_nand_read_page()
366 writel(curr_cmd->pgm, &arasan_nand_base->pgm_reg); in arasan_nand_read_page()
370 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_read_page()
383 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_read_page()
385 writel(reg_val, &arasan_nand_base->intsts_enr); in arasan_nand_read_page()
387 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_read_page()
389 &arasan_nand_base->intsts_enr); in arasan_nand_read_page()
391 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_read_page()
393 &arasan_nand_base->intsts_reg); in arasan_nand_read_page()
396 bufptr[i] = readl(&arasan_nand_base->buf_dataport); in arasan_nand_read_page()
405 &arasan_nand_base->intsts_enr); in arasan_nand_read_page()
410 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_read_page()
420 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_read_page()
422 &arasan_nand_base->intsts_enr); in arasan_nand_read_page()
423 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_read_page()
425 &arasan_nand_base->intsts_reg); in arasan_nand_read_page()
428 if (readl(&arasan_nand_base->intsts_reg) & in arasan_nand_read_page()
434 if (readl(&arasan_nand_base->intsts_reg) & in arasan_nand_read_page()
460 u32 __iomem *nand = &arasan_nand_base->buf_dataport; in arasan_nand_fill_tx()
520 reg_val = readl(&arasan_nand_base->pkt_reg); in arasan_nand_write_page_hwecc()
524 writel(reg_val, &arasan_nand_base->pkt_reg); in arasan_nand_write_page_hwecc()
532 &arasan_nand_base->ecc_sprcmd_reg); in arasan_nand_write_page_hwecc()
534 writel(curr_cmd->pgm, &arasan_nand_base->pgm_reg); in arasan_nand_write_page_hwecc()
538 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_write_page_hwecc()
552 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_write_page_hwecc()
554 writel(reg_val, &arasan_nand_base->intsts_enr); in arasan_nand_write_page_hwecc()
556 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_write_page_hwecc()
558 &arasan_nand_base->intsts_enr); in arasan_nand_write_page_hwecc()
561 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_write_page_hwecc()
563 &arasan_nand_base->intsts_reg); in arasan_nand_write_page_hwecc()
566 writel(bufptr[i], &arasan_nand_base->buf_dataport); in arasan_nand_write_page_hwecc()
574 &arasan_nand_base->intsts_enr); in arasan_nand_write_page_hwecc()
579 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_write_page_hwecc()
589 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_write_page_hwecc()
591 &arasan_nand_base->intsts_enr); in arasan_nand_write_page_hwecc()
592 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_write_page_hwecc()
594 &arasan_nand_base->intsts_reg); in arasan_nand_write_page_hwecc()
629 &arasan_nand_base->intsts_enr); in arasan_nand_reset()
630 cmd_reg = readl(&arasan_nand_base->cmd_reg); in arasan_nand_reset()
635 writel(cmd_reg, &arasan_nand_base->cmd_reg); in arasan_nand_reset()
636 writel(curr_cmd->pgm, &arasan_nand_base->pgm_reg); in arasan_nand_reset()
638 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_reset()
649 &arasan_nand_base->intsts_enr); in arasan_nand_reset()
652 &arasan_nand_base->intsts_reg); in arasan_nand_reset()
695 &arasan_nand_base->intsts_enr); in arasan_nand_send_wrcmd()
696 reg_val = readl(&arasan_nand_base->cmd_reg); in arasan_nand_send_wrcmd()
714 writel(reg_val, &arasan_nand_base->cmd_reg); in arasan_nand_send_wrcmd()
722 writel(page|column, &arasan_nand_base->memadr_reg1); in arasan_nand_send_wrcmd()
724 reg_val = readl(&arasan_nand_base->memadr_reg2); in arasan_nand_send_wrcmd()
727 writel(reg_val, &arasan_nand_base->memadr_reg2); in arasan_nand_send_wrcmd()
737 reg_val = readl(&arasan_nand_base->pkt_reg); in arasan_nand_write_buf()
742 writel(reg_val, &arasan_nand_base->pkt_reg); in arasan_nand_write_buf()
743 writel(curr_cmd->pgm, &arasan_nand_base->pgm_reg); in arasan_nand_write_buf()
745 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_write_buf()
754 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_write_buf()
756 writel(reg_val, &arasan_nand_base->intsts_enr); in arasan_nand_write_buf()
758 &arasan_nand_base->intsts_enr); in arasan_nand_write_buf()
759 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_write_buf()
761 &arasan_nand_base->intsts_reg); in arasan_nand_write_buf()
766 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_write_buf()
774 writel(readl(&arasan_nand_base->intsts_enr) | in arasan_nand_write_buf()
776 &arasan_nand_base->intsts_enr); in arasan_nand_write_buf()
777 writel(readl(&arasan_nand_base->intsts_reg) | in arasan_nand_write_buf()
779 &arasan_nand_base->intsts_reg); in arasan_nand_write_buf()
790 &arasan_nand_base->intsts_enr); in arasan_nand_erase()
791 reg_val = readl(&arasan_nand_base->cmd_reg); in arasan_nand_erase()
804 writel(reg_val, &arasan_nand_base->cmd_reg); in arasan_nand_erase()
810 &arasan_nand_base->memadr_reg1); in arasan_nand_erase()
812 reg_val = readl(&arasan_nand_base->memadr_reg2); in arasan_nand_erase()
815 writel(reg_val, &arasan_nand_base->memadr_reg2); in arasan_nand_erase()
816 writel(curr_cmd->pgm, &arasan_nand_base->pgm_reg); in arasan_nand_erase()
818 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_erase()
828 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_erase()
830 &arasan_nand_base->intsts_enr); in arasan_nand_erase()
831 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_erase()
833 &arasan_nand_base->intsts_reg); in arasan_nand_erase()
846 &arasan_nand_base->intsts_enr); in arasan_nand_read_status()
847 reg_val = readl(&arasan_nand_base->cmd_reg); in arasan_nand_read_status()
860 writel(reg_val, &arasan_nand_base->cmd_reg); in arasan_nand_read_status()
862 reg_val = readl(&arasan_nand_base->pkt_reg); in arasan_nand_read_status()
866 writel(reg_val, &arasan_nand_base->pkt_reg); in arasan_nand_read_status()
868 writel(curr_cmd->pgm, &arasan_nand_base->pgm_reg); in arasan_nand_read_status()
869 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_read_status()
880 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_read_status()
882 &arasan_nand_base->intsts_enr); in arasan_nand_read_status()
883 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_read_status()
885 &arasan_nand_base->intsts_reg); in arasan_nand_read_status()
896 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_send_rdcmd()
898 &arasan_nand_base->intsts_enr); in arasan_nand_send_rdcmd()
900 reg_val = readl(&arasan_nand_base->cmd_reg); in arasan_nand_send_rdcmd()
922 writel(reg_val, &arasan_nand_base->cmd_reg); in arasan_nand_send_rdcmd()
930 writel(page | column, &arasan_nand_base->memadr_reg1); in arasan_nand_send_rdcmd()
932 reg_val = readl(&arasan_nand_base->memadr_reg2); in arasan_nand_send_rdcmd()
935 writel(reg_val, &arasan_nand_base->memadr_reg2); in arasan_nand_send_rdcmd()
948 reg_val = readl(&arasan_nand_base->pkt_reg); in arasan_nand_read_buf()
952 writel(reg_val, &arasan_nand_base->pkt_reg); in arasan_nand_read_buf()
954 writel(curr_cmd->pgm, &arasan_nand_base->pgm_reg); in arasan_nand_read_buf()
956 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_read_buf()
965 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_read_buf()
967 writel(reg_val, &arasan_nand_base->intsts_enr); in arasan_nand_read_buf()
970 &arasan_nand_base->intsts_enr); in arasan_nand_read_buf()
971 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_read_buf()
973 &arasan_nand_base->intsts_reg); in arasan_nand_read_buf()
977 bufptr[i] = readl(&arasan_nand_base->buf_dataport); in arasan_nand_read_buf()
980 bufptr[i] = readl(&arasan_nand_base->buf_dataport); in arasan_nand_read_buf()
984 while (!(readl(&arasan_nand_base->intsts_reg) & in arasan_nand_read_buf()
993 reg_val = readl(&arasan_nand_base->intsts_enr); in arasan_nand_read_buf()
995 &arasan_nand_base->intsts_enr); in arasan_nand_read_buf()
996 reg_val = readl(&arasan_nand_base->intsts_reg); in arasan_nand_read_buf()
998 &arasan_nand_base->intsts_reg); in arasan_nand_read_buf()
1019 return readb(&arasan_nand_base->flash_sts_reg); in arasan_nand_read_byte()
1040 &arasan_nand_base->intsts_enr); in arasan_nand_cmd_function()
1160 writel(regval, &arasan_nand_base->ecc_reg); in arasan_nand_ecc_init()
1163 regval = readl(&arasan_nand_base->memadr_reg2); in arasan_nand_ecc_init()
1167 writel(regval, &arasan_nand_base->memadr_reg2); in arasan_nand_ecc_init()
1199 nand->nand_base = arasan_nand_base; in arasan_nand_init()
1217 writel(0x0, &arasan_nand_base->cmd_reg); in arasan_nand_init()
1218 writel(0x0, &arasan_nand_base->pgm_reg); in arasan_nand_init()