aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic-2.6/patches-2.6.27/513-yaffs_2.6.26_fix.patch
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2008-09-29 01:08:17 +0000
committerFelix Fietkau <nbd@openwrt.org>2008-09-29 01:08:17 +0000
commitbc92b67c41bb9eb64dd342735cf04d0ca5098926 (patch)
treefb3cad267265be9ac8eb1532182422f278dc3d0a /target/linux/generic-2.6/patches-2.6.27/513-yaffs_2.6.26_fix.patch
parent9b2097af21c4298fb67622266d5587e4e680fc5c (diff)
downloadupstream-bc92b67c41bb9eb64dd342735cf04d0ca5098926.tar.gz
upstream-bc92b67c41bb9eb64dd342735cf04d0ca5098926.tar.bz2
upstream-bc92b67c41bb9eb64dd342735cf04d0ca5098926.zip
port generic and ixp4xx kernel patches to 2.6.27 (compiles except for iptables, but otherwise completely untested)
SVN-Revision: 12790
Diffstat (limited to 'target/linux/generic-2.6/patches-2.6.27/513-yaffs_2.6.26_fix.patch')
-rw-r--r--target/linux/generic-2.6/patches-2.6.27/513-yaffs_2.6.26_fix.patch69
1 files changed, 69 insertions, 0 deletions
diff --git a/target/linux/generic-2.6/patches-2.6.27/513-yaffs_2.6.26_fix.patch b/target/linux/generic-2.6/patches-2.6.27/513-yaffs_2.6.26_fix.patch
new file mode 100644
index 0000000000..32bd3a5d57
--- /dev/null
+++ b/target/linux/generic-2.6/patches-2.6.27/513-yaffs_2.6.26_fix.patch
@@ -0,0 +1,69 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -76,6 +76,12 @@
+
+ #endif
+
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26))
++#define YPROC_ROOT &proc_root
++#else
++#define YPROC_ROOT NULL
++#endif
++
+ #if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,17))
+ #define WRITE_SIZE_STR "writesize"
+ #define WRITE_SIZE(mtd) (mtd)->writesize
+@@ -189,7 +195,9 @@
+ #endif
+
+
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26))
+ static void yaffs_put_inode(struct inode *inode);
++#endif
+ static void yaffs_delete_inode(struct inode *);
+ static void yaffs_clear_inode(struct inode *);
+
+@@ -293,7 +301,9 @@
+ #if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25))
+ .read_inode = yaffs_read_inode,
+ #endif
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26))
+ .put_inode = yaffs_put_inode,
++#endif
+ .put_super = yaffs_put_super,
+ .delete_inode = yaffs_delete_inode,
+ .clear_inode = yaffs_clear_inode,
+@@ -437,6 +447,7 @@
+
+ }
+
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26))
+ /* For now put inode is just for debugging
+ * Put inode is called when the inode **structure** is put.
+ */
+@@ -447,6 +458,7 @@
+ atomic_read(&inode->i_count)));
+
+ }
++#endif
+
+ /* clear is called to tell the fs to release any per-inode data it holds */
+ static void yaffs_clear_inode(struct inode *inode)
+@@ -2279,7 +2291,7 @@
+ /* Install the proc_fs entry */
+ my_proc_entry = create_proc_entry("yaffs",
+ S_IRUGO | S_IFREG,
+- &proc_root);
++ YPROC_ROOT);
+
+ if (my_proc_entry) {
+ my_proc_entry->write_proc = yaffs_proc_write;
+@@ -2325,7 +2337,7 @@
+ T(YAFFS_TRACE_ALWAYS, ("yaffs " __DATE__ " " __TIME__
+ " removing. \n"));
+
+- remove_proc_entry("yaffs", &proc_root);
++ remove_proc_entry("yaffs", YPROC_ROOT);
+
+ fsinst = fs_to_install;
+