aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/s3c24xx/patches-2.6.24/1009-s3c2410-bbt.patch.patch
diff options
context:
space:
mode:
authorMirko Vogt <mirko@openwrt.org>2008-12-12 11:58:53 +0000
committerMirko Vogt <mirko@openwrt.org>2008-12-12 11:58:53 +0000
commitfac7f7f84f3771c5247c7fdee825c092077984f5 (patch)
tree54644c1229434d7ee13c5872bda4129e34337fc0 /target/linux/s3c24xx/patches-2.6.24/1009-s3c2410-bbt.patch.patch
parenta34279723a9cf0796f9261f2fb90bea18cd95711 (diff)
downloadmaster-187ad058-fac7f7f84f3771c5247c7fdee825c092077984f5.tar.gz
master-187ad058-fac7f7f84f3771c5247c7fdee825c092077984f5.tar.bz2
master-187ad058-fac7f7f84f3771c5247c7fdee825c092077984f5.zip
changed Makefile and profiles, added patches for kernel 2.6.24
(stable-branch of Openmoko) git-svn-id: svn://svn.openwrt.org/openwrt/trunk@13613 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/s3c24xx/patches-2.6.24/1009-s3c2410-bbt.patch.patch')
-rw-r--r--target/linux/s3c24xx/patches-2.6.24/1009-s3c2410-bbt.patch.patch54
1 files changed, 54 insertions, 0 deletions
diff --git a/target/linux/s3c24xx/patches-2.6.24/1009-s3c2410-bbt.patch.patch b/target/linux/s3c24xx/patches-2.6.24/1009-s3c2410-bbt.patch.patch
new file mode 100644
index 0000000000..bfa3d1c915
--- /dev/null
+++ b/target/linux/s3c24xx/patches-2.6.24/1009-s3c2410-bbt.patch.patch
@@ -0,0 +1,54 @@
+From 8e01740813dc6a1d804e61d303549b04e160d153 Mon Sep 17 00:00:00 2001
+From: mokopatches <mokopatches@openmoko.org>
+Date: Fri, 4 Apr 2008 11:30:37 +0100
+Subject: [PATCH] s3c2410-bbt.patch
+ [PATCH] Add Kconfig option to enable NAND bad-block-table support for s3c2410
+
+This patch adds a new CONFIG_MTD_NAND_S3C2410_BBT which, if enabled,
+asks the mtd NAND core to use a bad-block table.
+
+Signed-off-by: Harald Welte <laforge@openmoko.org>
+---
+ drivers/mtd/nand/s3c2410.c | 6 +++++-
+ include/asm-arm/plat-s3c/nand.h | 3 +++
+ 2 files changed, 8 insertions(+), 1 deletions(-)
+
+diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c
+index 355de78..770306c 100644
+--- a/drivers/mtd/nand/s3c2410.c
++++ b/drivers/mtd/nand/s3c2410.c
+@@ -612,9 +612,13 @@ static void s3c2410_nand_init_chip(struct s3c2410_nand_info *info,
+ chip->select_chip = s3c2410_nand_select_chip;
+ chip->chip_delay = 50;
+ chip->priv = nmtd;
+- chip->options = 0;
+ chip->controller = &info->controller;
+
++ if (set->flags & S3C2410_NAND_BBT)
++ chip->options = NAND_USE_FLASH_BBT;
++ else
++ chip->options = 0;
++
+ switch (info->cpu_type) {
+ case TYPE_S3C2410:
+ chip->IO_ADDR_W = regs + S3C2410_NFDATA;
+diff --git a/include/asm-arm/plat-s3c/nand.h b/include/asm-arm/plat-s3c/nand.h
+index 8816f7f..cb87f9e 100644
+--- a/include/asm-arm/plat-s3c/nand.h
++++ b/include/asm-arm/plat-s3c/nand.h
+@@ -21,9 +21,12 @@
+ * partitions = mtd partition list
+ */
+
++#define S3C2410_NAND_BBT 0x0001
++
+ struct s3c2410_nand_set {
+ int nr_chips;
+ int nr_partitions;
++ unsigned int flags;
+ char *name;
+ int *nr_map;
+ struct mtd_partition *partitions;
+--
+1.5.6.5
+