s5pc100: OneNAND: Use generic OneNAND
authorKyungmin Park <kyungmin.park@samsung.com>
Tue, 21 Jul 2009 00:27:46 +0000 (09:27 +0900)
committerKyungmin Park <kyungmin.park@samsung.com>
Tue, 21 Jul 2009 00:27:46 +0000 (09:27 +0900)
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
board/samsung/universal/onenand.c
drivers/mtd/onenand/Makefile
drivers/mtd/onenand/s3c-onenand.c
onenand_ipl/onenand_read.c

index 7839891..11c6379 100644 (file)
@@ -87,7 +87,7 @@ void onenand_board_init(struct mtd_info *mtd)
 //     MEM_CFG0_REG |= ONENAND_SYS_CFG1_HF;
 
        this->base = (void *) 0xe7100000;
-//     this->base = (void *)CONFIG_SYS_ONENAND_BASE;
+       this->base = (void *)CONFIG_SYS_ONENAND_BASE;
 
-//     s3c_onenand_init(mtd);
+       s3c_onenand_init(mtd);
 }
index c9123ad..820bbeb 100644 (file)
@@ -25,10 +25,10 @@ include $(TOPDIR)/config.mk
 
 LIB    := $(obj)libonenand.a
 
-#COBJS-$(CONFIG_CMD_ONENAND)   := onenand_uboot.o onenand_base.o onenand_bbt.o
-#COBJS-$(CONFIG_S3C64XX)               += s3c-onenand.o
-#COBJS-$(CONFIG_S5PC1XX)               += s3c-onenand.o
-COBJS-$(CONFIG_S5PC1XX)                += onenand_uboot.o lsi_onenand.o
+COBJS-$(CONFIG_CMD_ONENAND)    := onenand_uboot.o onenand_base.o onenand_bbt.o
+COBJS-$(CONFIG_S3C64XX)                += s3c-onenand.o
+COBJS-$(CONFIG_S5PC1XX)                += s3c-onenand.o
+#COBJS-$(CONFIG_S5PC1XX)               += onenand_uboot.o lsi_onenand.o
 
 COBJS  := $(COBJS-y)
 SRCS   := $(COBJS:.o=.c)
index f58050d..313ce8f 100644 (file)
@@ -618,6 +618,4 @@ void s3c_onenand_init(struct mtd_info *mtd)
 
        this->read_bufferram = onenand_read_bufferram;
        this->write_bufferram = onenand_write_bufferram;
-
-       this->options |= ONENAND_RUNTIME_BADBLOCK_CHECK;
 }
index 113012d..2602dde 100644 (file)
@@ -132,9 +132,6 @@ int onenand_read_block(unsigned char *buf)
 
        erasesize = ONENAND_PAGES_PER_BLOCK * pagesize;
        nblocks = (CONFIG_SYS_MONITOR_LEN + erasesize - 1) >> erase_shift;
-#ifdef CONFIG_S5PC1XX
-       nblocks = 1;
-#endif
 
        /* NOTE: you must read page from page 1 of block 0 */
        /* read the block page by page*/