[kernel] generic-2.6: yaffs cleanup
authorjuhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Fri, 6 Jun 2008 13:14:59 +0000 (13:14 +0000)
committerjuhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Fri, 6 Jun 2008 13:14:59 +0000 (13:14 +0000)
 * reduce compiler warnings,
 * renumber/rename patches

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@11379 3c298f89-4303-0410-b956-a3cf2f4a3e73

22 files changed:
target/linux/generic-2.6/patches-2.6.22/510-Yaffs.patch [deleted file]
target/linux/generic-2.6/patches-2.6.22/510-yaffs_support.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.22/511-yaffs_reduce_compiler_warnings.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.23/510-Yaffs.patch [deleted file]
target/linux/generic-2.6/patches-2.6.23/510-yaffs_support.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.23/511-yaffs_reduce_compiler_warnings.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.24/510-Yaffs.patch [deleted file]
target/linux/generic-2.6/patches-2.6.24/510-yaffs_support.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.24/511-yaffs_reduce_compiler_warnings.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.25/510-Yaffs.patch [deleted file]
target/linux/generic-2.6/patches-2.6.25/510-yaffs_support.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.25/511-yaffs_2.6.25_fix.patch [deleted file]
target/linux/generic-2.6/patches-2.6.25/511-yaffs_reduce_compiler_warnings.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.25/512-yaffs_2.6.25_fix.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.26/510-Yaffs.patch [deleted file]
target/linux/generic-2.6/patches-2.6.26/510-yaffs_support.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.26/511-yaffs_2.6.25_fix.patch [deleted file]
target/linux/generic-2.6/patches-2.6.26/511-yaffs_reduce_compiler_warnings.patch [new file with mode: 0644]
target/linux/generic-2.6/patches-2.6.26/512-yaffs_2.6.25_fix.patch [new file with mode: 0644]
target/linux/generic-2.6/patches/510-Yaffs.patch [deleted file]
target/linux/generic-2.6/patches/510-yaffs_support.patch [new file with mode: 0644]
target/linux/generic-2.6/patches/511-yaffs_reduce_compiler_warnings.patch [new file with mode: 0644]

diff --git a/target/linux/generic-2.6/patches-2.6.22/510-Yaffs.patch b/target/linux/generic-2.6/patches-2.6.22/510-Yaffs.patch
deleted file mode 100644 (file)
index 5720556..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-Index: linux-2.6.22.19/fs/Kconfig
-===================================================================
---- linux-2.6.22.19.orig/fs/Kconfig
-+++ linux-2.6.22.19/fs/Kconfig
-@@ -419,6 +419,7 @@ config FS_POSIX_ACL
- source "fs/xfs/Kconfig"
- source "fs/gfs2/Kconfig"
-+source "fs/yaffs2/Kconfig"
- config OCFS2_FS
-       tristate "OCFS2 file system support"
-Index: linux-2.6.22.19/fs/Makefile
-===================================================================
---- linux-2.6.22.19.orig/fs/Makefile
-+++ linux-2.6.22.19/fs/Makefile
-@@ -120,3 +120,4 @@ obj-$(CONFIG_HPPFS)                += hppfs/
- obj-$(CONFIG_DEBUG_FS)                += debugfs/
- obj-$(CONFIG_OCFS2_FS)                += ocfs2/
- obj-$(CONFIG_GFS2_FS)           += gfs2/
-+obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.22/510-yaffs_support.patch b/target/linux/generic-2.6/patches-2.6.22/510-yaffs_support.patch
new file mode 100644 (file)
index 0000000..5720556
--- /dev/null
@@ -0,0 +1,21 @@
+Index: linux-2.6.22.19/fs/Kconfig
+===================================================================
+--- linux-2.6.22.19.orig/fs/Kconfig
++++ linux-2.6.22.19/fs/Kconfig
+@@ -419,6 +419,7 @@ config FS_POSIX_ACL
+ source "fs/xfs/Kconfig"
+ source "fs/gfs2/Kconfig"
++source "fs/yaffs2/Kconfig"
+ config OCFS2_FS
+       tristate "OCFS2 file system support"
+Index: linux-2.6.22.19/fs/Makefile
+===================================================================
+--- linux-2.6.22.19.orig/fs/Makefile
++++ linux-2.6.22.19/fs/Makefile
+@@ -120,3 +120,4 @@ obj-$(CONFIG_HPPFS)                += hppfs/
+ obj-$(CONFIG_DEBUG_FS)                += debugfs/
+ obj-$(CONFIG_OCFS2_FS)                += ocfs2/
+ obj-$(CONFIG_GFS2_FS)           += gfs2/
++obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.22/511-yaffs_reduce_compiler_warnings.patch b/target/linux/generic-2.6/patches-2.6.22/511-yaffs_reduce_compiler_warnings.patch
new file mode 100644 (file)
index 0000000..61d0a75
--- /dev/null
@@ -0,0 +1,80 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -969,7 +970,7 @@
+               f->f_version = inode->i_version;
+       }
+-      list_for_each(i, &obj->variant.directoryVariant.children) {
++      list_for_each(i, (struct list_head *)&obj->variant.directoryVariant.children) {
+               curoffs++;
+               if (curoffs >= offset) {
+                       l = list_entry(i, yaffs_Object, siblings);
+@@ -1273,7 +1275,7 @@
+       if (target &&
+           target->variantType == YAFFS_OBJECT_TYPE_DIRECTORY &&
+-          !list_empty(&target->variant.directoryVariant.children)) {
++          !list_empty((struct list_head *)&target->variant.directoryVariant.children)) {
+               T(YAFFS_TRACE_OS, (KERN_DEBUG "target is non-empty dir\n"));
+@@ -1529,7 +1531,7 @@
+       yaffs_GrossUnlock(dev);
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_del(&dev->devList);
++      list_del((struct list_head *)&dev->devList);
+       if(dev->spareBuffer){
+               YFREE(dev->spareBuffer);
+@@ -1864,7 +1866,7 @@
+       dev->skipCheckpointWrite = options.skip_checkpoint_write;
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_add_tail(&dev->devList, &yaffs_dev_list);
++      list_add_tail((struct list_head *)&dev->devList, &yaffs_dev_list);
+       init_MUTEX(&dev->grossLock);
+--- a/fs/yaffs2/yaffs_mtdif1.c
++++ b/fs/yaffs2/yaffs_mtdif1.c
+@@ -323,7 +323,7 @@
+  * Always returns YAFFS_OK.
+  */
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * pState, int *pSequenceNumber)
++      yaffs_BlockState * pState, __u32 *pSequenceNumber)
+ {
+       struct mtd_info * mtd = dev->genericDevice;
+       int chunkNo = blockNo * dev->nChunksPerBlock;
+--- a/fs/yaffs2/yaffs_mtdif1.h
++++ b/fs/yaffs2/yaffs_mtdif1.h
+@@ -23,6 +23,6 @@
+ int nandmtd1_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * state, int *sequenceNumber);
++      yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
+--- a/fs/yaffs2/yaffs_mtdif2.c
++++ b/fs/yaffs2/yaffs_mtdif2.c
+@@ -204,7 +204,7 @@
+ }
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber)
++                          yaffs_BlockState * state, __u32 *sequenceNumber)
+ {
+       struct mtd_info *mtd = (struct mtd_info *)(dev->genericDevice);
+       int retval;
+--- a/fs/yaffs2/yaffs_mtdif2.h
++++ b/fs/yaffs2/yaffs_mtdif2.h
+@@ -24,6 +24,6 @@
+                                      __u8 * data, yaffs_ExtendedTags * tags);
+ int nandmtd2_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber);
++                          yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
diff --git a/target/linux/generic-2.6/patches-2.6.23/510-Yaffs.patch b/target/linux/generic-2.6/patches-2.6.23/510-Yaffs.patch
deleted file mode 100644 (file)
index a48dfbb..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
---- a/fs/Kconfig
-+++ b/fs/Kconfig
-@@ -419,6 +419,7 @@
- source "fs/xfs/Kconfig"
- source "fs/gfs2/Kconfig"
-+source "fs/yaffs2/Kconfig"
- config OCFS2_FS
-       tristate "OCFS2 file system support"
---- a/fs/Makefile
-+++ b/fs/Makefile
-@@ -120,3 +120,4 @@
- obj-$(CONFIG_DEBUG_FS)                += debugfs/
- obj-$(CONFIG_OCFS2_FS)                += ocfs2/
- obj-$(CONFIG_GFS2_FS)           += gfs2/
-+obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.23/510-yaffs_support.patch b/target/linux/generic-2.6/patches-2.6.23/510-yaffs_support.patch
new file mode 100644 (file)
index 0000000..a48dfbb
--- /dev/null
@@ -0,0 +1,17 @@
+--- a/fs/Kconfig
++++ b/fs/Kconfig
+@@ -419,6 +419,7 @@
+ source "fs/xfs/Kconfig"
+ source "fs/gfs2/Kconfig"
++source "fs/yaffs2/Kconfig"
+ config OCFS2_FS
+       tristate "OCFS2 file system support"
+--- a/fs/Makefile
++++ b/fs/Makefile
+@@ -120,3 +120,4 @@
+ obj-$(CONFIG_DEBUG_FS)                += debugfs/
+ obj-$(CONFIG_OCFS2_FS)                += ocfs2/
+ obj-$(CONFIG_GFS2_FS)           += gfs2/
++obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.23/511-yaffs_reduce_compiler_warnings.patch b/target/linux/generic-2.6/patches-2.6.23/511-yaffs_reduce_compiler_warnings.patch
new file mode 100644 (file)
index 0000000..61d0a75
--- /dev/null
@@ -0,0 +1,80 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -969,7 +970,7 @@
+               f->f_version = inode->i_version;
+       }
+-      list_for_each(i, &obj->variant.directoryVariant.children) {
++      list_for_each(i, (struct list_head *)&obj->variant.directoryVariant.children) {
+               curoffs++;
+               if (curoffs >= offset) {
+                       l = list_entry(i, yaffs_Object, siblings);
+@@ -1273,7 +1275,7 @@
+       if (target &&
+           target->variantType == YAFFS_OBJECT_TYPE_DIRECTORY &&
+-          !list_empty(&target->variant.directoryVariant.children)) {
++          !list_empty((struct list_head *)&target->variant.directoryVariant.children)) {
+               T(YAFFS_TRACE_OS, (KERN_DEBUG "target is non-empty dir\n"));
+@@ -1529,7 +1531,7 @@
+       yaffs_GrossUnlock(dev);
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_del(&dev->devList);
++      list_del((struct list_head *)&dev->devList);
+       if(dev->spareBuffer){
+               YFREE(dev->spareBuffer);
+@@ -1864,7 +1866,7 @@
+       dev->skipCheckpointWrite = options.skip_checkpoint_write;
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_add_tail(&dev->devList, &yaffs_dev_list);
++      list_add_tail((struct list_head *)&dev->devList, &yaffs_dev_list);
+       init_MUTEX(&dev->grossLock);
+--- a/fs/yaffs2/yaffs_mtdif1.c
++++ b/fs/yaffs2/yaffs_mtdif1.c
+@@ -323,7 +323,7 @@
+  * Always returns YAFFS_OK.
+  */
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * pState, int *pSequenceNumber)
++      yaffs_BlockState * pState, __u32 *pSequenceNumber)
+ {
+       struct mtd_info * mtd = dev->genericDevice;
+       int chunkNo = blockNo * dev->nChunksPerBlock;
+--- a/fs/yaffs2/yaffs_mtdif1.h
++++ b/fs/yaffs2/yaffs_mtdif1.h
+@@ -23,6 +23,6 @@
+ int nandmtd1_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * state, int *sequenceNumber);
++      yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
+--- a/fs/yaffs2/yaffs_mtdif2.c
++++ b/fs/yaffs2/yaffs_mtdif2.c
+@@ -204,7 +204,7 @@
+ }
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber)
++                          yaffs_BlockState * state, __u32 *sequenceNumber)
+ {
+       struct mtd_info *mtd = (struct mtd_info *)(dev->genericDevice);
+       int retval;
+--- a/fs/yaffs2/yaffs_mtdif2.h
++++ b/fs/yaffs2/yaffs_mtdif2.h
+@@ -24,6 +24,6 @@
+                                      __u8 * data, yaffs_ExtendedTags * tags);
+ int nandmtd2_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber);
++                          yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
diff --git a/target/linux/generic-2.6/patches-2.6.24/510-Yaffs.patch b/target/linux/generic-2.6/patches-2.6.24/510-Yaffs.patch
deleted file mode 100644 (file)
index d344136..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
---- a/fs/Kconfig
-+++ b/fs/Kconfig
-@@ -420,6 +420,7 @@
- source "fs/xfs/Kconfig"
- source "fs/gfs2/Kconfig"
-+source "fs/yaffs2/Kconfig"
- config OCFS2_FS
-       tristate "OCFS2 file system support"
---- a/fs/Makefile
-+++ b/fs/Makefile
-@@ -120,3 +120,4 @@
- obj-$(CONFIG_DEBUG_FS)                += debugfs/
- obj-$(CONFIG_OCFS2_FS)                += ocfs2/
- obj-$(CONFIG_GFS2_FS)           += gfs2/
-+obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.24/510-yaffs_support.patch b/target/linux/generic-2.6/patches-2.6.24/510-yaffs_support.patch
new file mode 100644 (file)
index 0000000..d344136
--- /dev/null
@@ -0,0 +1,17 @@
+--- a/fs/Kconfig
++++ b/fs/Kconfig
+@@ -420,6 +420,7 @@
+ source "fs/xfs/Kconfig"
+ source "fs/gfs2/Kconfig"
++source "fs/yaffs2/Kconfig"
+ config OCFS2_FS
+       tristate "OCFS2 file system support"
+--- a/fs/Makefile
++++ b/fs/Makefile
+@@ -120,3 +120,4 @@
+ obj-$(CONFIG_DEBUG_FS)                += debugfs/
+ obj-$(CONFIG_OCFS2_FS)                += ocfs2/
+ obj-$(CONFIG_GFS2_FS)           += gfs2/
++obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.24/511-yaffs_reduce_compiler_warnings.patch b/target/linux/generic-2.6/patches-2.6.24/511-yaffs_reduce_compiler_warnings.patch
new file mode 100644 (file)
index 0000000..118cb67
--- /dev/null
@@ -0,0 +1,80 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -969,7 +969,7 @@
+               f->f_version = inode->i_version;
+       }
+-      list_for_each(i, &obj->variant.directoryVariant.children) {
++      list_for_each(i, (struct list_head *)&obj->variant.directoryVariant.children) {
+               curoffs++;
+               if (curoffs >= offset) {
+                       l = list_entry(i, yaffs_Object, siblings);
+@@ -1273,7 +1273,7 @@
+       if (target &&
+           target->variantType == YAFFS_OBJECT_TYPE_DIRECTORY &&
+-          !list_empty(&target->variant.directoryVariant.children)) {
++          !list_empty((struct list_head *)&target->variant.directoryVariant.children)) {
+               T(YAFFS_TRACE_OS, (KERN_DEBUG "target is non-empty dir\n"));
+@@ -1529,7 +1529,7 @@
+       yaffs_GrossUnlock(dev);
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_del(&dev->devList);
++      list_del((struct list_head *)&dev->devList);
+       if(dev->spareBuffer){
+               YFREE(dev->spareBuffer);
+@@ -1864,7 +1864,7 @@
+       dev->skipCheckpointWrite = options.skip_checkpoint_write;
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_add_tail(&dev->devList, &yaffs_dev_list);
++      list_add_tail((struct list_head *)&dev->devList, &yaffs_dev_list);
+       init_MUTEX(&dev->grossLock);
+--- a/fs/yaffs2/yaffs_mtdif1.c
++++ b/fs/yaffs2/yaffs_mtdif1.c
+@@ -323,7 +323,7 @@
+  * Always returns YAFFS_OK.
+  */
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * pState, int *pSequenceNumber)
++      yaffs_BlockState * pState, __u32 *pSequenceNumber)
+ {
+       struct mtd_info * mtd = dev->genericDevice;
+       int chunkNo = blockNo * dev->nChunksPerBlock;
+--- a/fs/yaffs2/yaffs_mtdif1.h
++++ b/fs/yaffs2/yaffs_mtdif1.h
+@@ -23,6 +23,6 @@
+ int nandmtd1_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * state, int *sequenceNumber);
++      yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
+--- a/fs/yaffs2/yaffs_mtdif2.c
++++ b/fs/yaffs2/yaffs_mtdif2.c
+@@ -204,7 +204,7 @@
+ }
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber)
++                          yaffs_BlockState * state, __u32 *sequenceNumber)
+ {
+       struct mtd_info *mtd = (struct mtd_info *)(dev->genericDevice);
+       int retval;
+--- a/fs/yaffs2/yaffs_mtdif2.h
++++ b/fs/yaffs2/yaffs_mtdif2.h
+@@ -24,6 +24,6 @@
+                                      __u8 * data, yaffs_ExtendedTags * tags);
+ int nandmtd2_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber);
++                          yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
diff --git a/target/linux/generic-2.6/patches-2.6.25/510-Yaffs.patch b/target/linux/generic-2.6/patches-2.6.25/510-Yaffs.patch
deleted file mode 100644 (file)
index e0f1a9b..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
---- a/fs/Kconfig
-+++ b/fs/Kconfig
-@@ -421,6 +421,7 @@
- source "fs/xfs/Kconfig"
- source "fs/gfs2/Kconfig"
-+source "fs/yaffs2/Kconfig"
- config OCFS2_FS
-       tristate "OCFS2 file system support"
---- a/fs/Makefile
-+++ b/fs/Makefile
-@@ -121,3 +121,4 @@
- obj-$(CONFIG_DEBUG_FS)                += debugfs/
- obj-$(CONFIG_OCFS2_FS)                += ocfs2/
- obj-$(CONFIG_GFS2_FS)           += gfs2/
-+obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.25/510-yaffs_support.patch b/target/linux/generic-2.6/patches-2.6.25/510-yaffs_support.patch
new file mode 100644 (file)
index 0000000..e0f1a9b
--- /dev/null
@@ -0,0 +1,17 @@
+--- a/fs/Kconfig
++++ b/fs/Kconfig
+@@ -421,6 +421,7 @@
+ source "fs/xfs/Kconfig"
+ source "fs/gfs2/Kconfig"
++source "fs/yaffs2/Kconfig"
+ config OCFS2_FS
+       tristate "OCFS2 file system support"
+--- a/fs/Makefile
++++ b/fs/Makefile
+@@ -121,3 +121,4 @@
+ obj-$(CONFIG_DEBUG_FS)                += debugfs/
+ obj-$(CONFIG_OCFS2_FS)                += ocfs2/
+ obj-$(CONFIG_GFS2_FS)           += gfs2/
++obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.25/511-yaffs_2.6.25_fix.patch b/target/linux/generic-2.6/patches-2.6.25/511-yaffs_2.6.25_fix.patch
deleted file mode 100644 (file)
index ac89534..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
---- a/fs/yaffs2/yaffs_fs.c
-+++ b/fs/yaffs2/yaffs_fs.c
-@@ -181,7 +181,13 @@
- #else
- static int yaffs_statfs(struct super_block *sb, struct statfs *buf);
- #endif
-+
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
-+static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino);
-+#else
- static void yaffs_read_inode(struct inode *inode);
-+#endif
-+
- static void yaffs_put_inode(struct inode *inode);
- static void yaffs_delete_inode(struct inode *);
-@@ -284,7 +290,9 @@
- static struct super_operations yaffs_super_ops = {
-       .statfs = yaffs_statfs,
-+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25))
-       .read_inode = yaffs_read_inode,
-+#endif
-       .put_inode = yaffs_put_inode,
-       .put_super = yaffs_put_super,
-       .delete_inode = yaffs_delete_inode,
-@@ -844,11 +852,17 @@
-       T(YAFFS_TRACE_OS,
-         (KERN_DEBUG "yaffs_get_inode for object %d\n", obj->objectId));
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
-+      inode = yaffs_iget(sb, obj->objectId);
-+      if (IS_ERR(inode))
-+              return NULL;
-+#else
-       inode = iget(sb, obj->objectId);
-       /* NB Side effect: iget calls back to yaffs_read_inode(). */
-       /* iget also increments the inode's i_count */
-       /* NB You can't be holding grossLock or deadlock will happen! */
-+#endif
-       return inode;
- }
-@@ -1427,6 +1441,39 @@
- }
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
-+static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino)
-+{
-+      yaffs_Object *obj;
-+      yaffs_Device *dev = yaffs_SuperToDevice(sb);
-+      struct inode *inode;
-+
-+      T(YAFFS_TRACE_OS,
-+        (KERN_DEBUG "yaffs_iget for %lu\n", ino));
-+
-+      inode = iget_locked(sb, ino);
-+      if (!inode)
-+              return ERR_PTR(-ENOMEM);
-+      if (!(inode->i_state & I_NEW))
-+              return inode;
-+
-+      /* NB This is called as a side effect of other functions, but
-+       * we had to release the lock to prevent deadlocks, so
-+       * need to lock again.
-+       */
-+
-+      yaffs_GrossLock(dev);
-+
-+      obj = yaffs_FindObjectByNumber(dev, inode->i_ino);
-+
-+      yaffs_FillInodeFromObject(inode, obj);
-+
-+      yaffs_GrossUnlock(dev);
-+
-+      unlock_new_inode(inode);
-+      return inode;
-+}
-+#else
- static void yaffs_read_inode(struct inode *inode)
- {
-       /* NB This is called as a side effect of other functions, but
-@@ -1448,6 +1495,7 @@
-       yaffs_GrossUnlock(dev);
- }
-+#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25)) */
- static LIST_HEAD(yaffs_dev_list);
diff --git a/target/linux/generic-2.6/patches-2.6.25/511-yaffs_reduce_compiler_warnings.patch b/target/linux/generic-2.6/patches-2.6.25/511-yaffs_reduce_compiler_warnings.patch
new file mode 100644 (file)
index 0000000..61d0a75
--- /dev/null
@@ -0,0 +1,80 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -969,7 +970,7 @@
+               f->f_version = inode->i_version;
+       }
+-      list_for_each(i, &obj->variant.directoryVariant.children) {
++      list_for_each(i, (struct list_head *)&obj->variant.directoryVariant.children) {
+               curoffs++;
+               if (curoffs >= offset) {
+                       l = list_entry(i, yaffs_Object, siblings);
+@@ -1273,7 +1275,7 @@
+       if (target &&
+           target->variantType == YAFFS_OBJECT_TYPE_DIRECTORY &&
+-          !list_empty(&target->variant.directoryVariant.children)) {
++          !list_empty((struct list_head *)&target->variant.directoryVariant.children)) {
+               T(YAFFS_TRACE_OS, (KERN_DEBUG "target is non-empty dir\n"));
+@@ -1529,7 +1531,7 @@
+       yaffs_GrossUnlock(dev);
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_del(&dev->devList);
++      list_del((struct list_head *)&dev->devList);
+       if(dev->spareBuffer){
+               YFREE(dev->spareBuffer);
+@@ -1864,7 +1866,7 @@
+       dev->skipCheckpointWrite = options.skip_checkpoint_write;
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_add_tail(&dev->devList, &yaffs_dev_list);
++      list_add_tail((struct list_head *)&dev->devList, &yaffs_dev_list);
+       init_MUTEX(&dev->grossLock);
+--- a/fs/yaffs2/yaffs_mtdif1.c
++++ b/fs/yaffs2/yaffs_mtdif1.c
+@@ -323,7 +323,7 @@
+  * Always returns YAFFS_OK.
+  */
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * pState, int *pSequenceNumber)
++      yaffs_BlockState * pState, __u32 *pSequenceNumber)
+ {
+       struct mtd_info * mtd = dev->genericDevice;
+       int chunkNo = blockNo * dev->nChunksPerBlock;
+--- a/fs/yaffs2/yaffs_mtdif1.h
++++ b/fs/yaffs2/yaffs_mtdif1.h
+@@ -23,6 +23,6 @@
+ int nandmtd1_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * state, int *sequenceNumber);
++      yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
+--- a/fs/yaffs2/yaffs_mtdif2.c
++++ b/fs/yaffs2/yaffs_mtdif2.c
+@@ -204,7 +204,7 @@
+ }
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber)
++                          yaffs_BlockState * state, __u32 *sequenceNumber)
+ {
+       struct mtd_info *mtd = (struct mtd_info *)(dev->genericDevice);
+       int retval;
+--- a/fs/yaffs2/yaffs_mtdif2.h
++++ b/fs/yaffs2/yaffs_mtdif2.h
+@@ -24,6 +24,6 @@
+                                      __u8 * data, yaffs_ExtendedTags * tags);
+ int nandmtd2_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber);
++                          yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
diff --git a/target/linux/generic-2.6/patches-2.6.25/512-yaffs_2.6.25_fix.patch b/target/linux/generic-2.6/patches-2.6.25/512-yaffs_2.6.25_fix.patch
new file mode 100644 (file)
index 0000000..ac89534
--- /dev/null
@@ -0,0 +1,92 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -181,7 +181,13 @@
+ #else
+ static int yaffs_statfs(struct super_block *sb, struct statfs *buf);
+ #endif
++
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
++static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino);
++#else
+ static void yaffs_read_inode(struct inode *inode);
++#endif
++
+ static void yaffs_put_inode(struct inode *inode);
+ static void yaffs_delete_inode(struct inode *);
+@@ -284,7 +290,9 @@
+ static struct super_operations yaffs_super_ops = {
+       .statfs = yaffs_statfs,
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25))
+       .read_inode = yaffs_read_inode,
++#endif
+       .put_inode = yaffs_put_inode,
+       .put_super = yaffs_put_super,
+       .delete_inode = yaffs_delete_inode,
+@@ -844,11 +852,17 @@
+       T(YAFFS_TRACE_OS,
+         (KERN_DEBUG "yaffs_get_inode for object %d\n", obj->objectId));
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
++      inode = yaffs_iget(sb, obj->objectId);
++      if (IS_ERR(inode))
++              return NULL;
++#else
+       inode = iget(sb, obj->objectId);
+       /* NB Side effect: iget calls back to yaffs_read_inode(). */
+       /* iget also increments the inode's i_count */
+       /* NB You can't be holding grossLock or deadlock will happen! */
++#endif
+       return inode;
+ }
+@@ -1427,6 +1441,39 @@
+ }
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
++static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino)
++{
++      yaffs_Object *obj;
++      yaffs_Device *dev = yaffs_SuperToDevice(sb);
++      struct inode *inode;
++
++      T(YAFFS_TRACE_OS,
++        (KERN_DEBUG "yaffs_iget for %lu\n", ino));
++
++      inode = iget_locked(sb, ino);
++      if (!inode)
++              return ERR_PTR(-ENOMEM);
++      if (!(inode->i_state & I_NEW))
++              return inode;
++
++      /* NB This is called as a side effect of other functions, but
++       * we had to release the lock to prevent deadlocks, so
++       * need to lock again.
++       */
++
++      yaffs_GrossLock(dev);
++
++      obj = yaffs_FindObjectByNumber(dev, inode->i_ino);
++
++      yaffs_FillInodeFromObject(inode, obj);
++
++      yaffs_GrossUnlock(dev);
++
++      unlock_new_inode(inode);
++      return inode;
++}
++#else
+ static void yaffs_read_inode(struct inode *inode)
+ {
+       /* NB This is called as a side effect of other functions, but
+@@ -1448,6 +1495,7 @@
+       yaffs_GrossUnlock(dev);
+ }
++#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25)) */
+ static LIST_HEAD(yaffs_dev_list);
diff --git a/target/linux/generic-2.6/patches-2.6.26/510-Yaffs.patch b/target/linux/generic-2.6/patches-2.6.26/510-Yaffs.patch
deleted file mode 100644 (file)
index e0f1a9b..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
---- a/fs/Kconfig
-+++ b/fs/Kconfig
-@@ -421,6 +421,7 @@
- source "fs/xfs/Kconfig"
- source "fs/gfs2/Kconfig"
-+source "fs/yaffs2/Kconfig"
- config OCFS2_FS
-       tristate "OCFS2 file system support"
---- a/fs/Makefile
-+++ b/fs/Makefile
-@@ -121,3 +121,4 @@
- obj-$(CONFIG_DEBUG_FS)                += debugfs/
- obj-$(CONFIG_OCFS2_FS)                += ocfs2/
- obj-$(CONFIG_GFS2_FS)           += gfs2/
-+obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.26/510-yaffs_support.patch b/target/linux/generic-2.6/patches-2.6.26/510-yaffs_support.patch
new file mode 100644 (file)
index 0000000..e0f1a9b
--- /dev/null
@@ -0,0 +1,17 @@
+--- a/fs/Kconfig
++++ b/fs/Kconfig
+@@ -421,6 +421,7 @@
+ source "fs/xfs/Kconfig"
+ source "fs/gfs2/Kconfig"
++source "fs/yaffs2/Kconfig"
+ config OCFS2_FS
+       tristate "OCFS2 file system support"
+--- a/fs/Makefile
++++ b/fs/Makefile
+@@ -121,3 +121,4 @@
+ obj-$(CONFIG_DEBUG_FS)                += debugfs/
+ obj-$(CONFIG_OCFS2_FS)                += ocfs2/
+ obj-$(CONFIG_GFS2_FS)           += gfs2/
++obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches-2.6.26/511-yaffs_2.6.25_fix.patch b/target/linux/generic-2.6/patches-2.6.26/511-yaffs_2.6.25_fix.patch
deleted file mode 100644 (file)
index ac89534..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
---- a/fs/yaffs2/yaffs_fs.c
-+++ b/fs/yaffs2/yaffs_fs.c
-@@ -181,7 +181,13 @@
- #else
- static int yaffs_statfs(struct super_block *sb, struct statfs *buf);
- #endif
-+
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
-+static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino);
-+#else
- static void yaffs_read_inode(struct inode *inode);
-+#endif
-+
- static void yaffs_put_inode(struct inode *inode);
- static void yaffs_delete_inode(struct inode *);
-@@ -284,7 +290,9 @@
- static struct super_operations yaffs_super_ops = {
-       .statfs = yaffs_statfs,
-+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25))
-       .read_inode = yaffs_read_inode,
-+#endif
-       .put_inode = yaffs_put_inode,
-       .put_super = yaffs_put_super,
-       .delete_inode = yaffs_delete_inode,
-@@ -844,11 +852,17 @@
-       T(YAFFS_TRACE_OS,
-         (KERN_DEBUG "yaffs_get_inode for object %d\n", obj->objectId));
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
-+      inode = yaffs_iget(sb, obj->objectId);
-+      if (IS_ERR(inode))
-+              return NULL;
-+#else
-       inode = iget(sb, obj->objectId);
-       /* NB Side effect: iget calls back to yaffs_read_inode(). */
-       /* iget also increments the inode's i_count */
-       /* NB You can't be holding grossLock or deadlock will happen! */
-+#endif
-       return inode;
- }
-@@ -1427,6 +1441,39 @@
- }
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
-+static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino)
-+{
-+      yaffs_Object *obj;
-+      yaffs_Device *dev = yaffs_SuperToDevice(sb);
-+      struct inode *inode;
-+
-+      T(YAFFS_TRACE_OS,
-+        (KERN_DEBUG "yaffs_iget for %lu\n", ino));
-+
-+      inode = iget_locked(sb, ino);
-+      if (!inode)
-+              return ERR_PTR(-ENOMEM);
-+      if (!(inode->i_state & I_NEW))
-+              return inode;
-+
-+      /* NB This is called as a side effect of other functions, but
-+       * we had to release the lock to prevent deadlocks, so
-+       * need to lock again.
-+       */
-+
-+      yaffs_GrossLock(dev);
-+
-+      obj = yaffs_FindObjectByNumber(dev, inode->i_ino);
-+
-+      yaffs_FillInodeFromObject(inode, obj);
-+
-+      yaffs_GrossUnlock(dev);
-+
-+      unlock_new_inode(inode);
-+      return inode;
-+}
-+#else
- static void yaffs_read_inode(struct inode *inode)
- {
-       /* NB This is called as a side effect of other functions, but
-@@ -1448,6 +1495,7 @@
-       yaffs_GrossUnlock(dev);
- }
-+#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25)) */
- static LIST_HEAD(yaffs_dev_list);
diff --git a/target/linux/generic-2.6/patches-2.6.26/511-yaffs_reduce_compiler_warnings.patch b/target/linux/generic-2.6/patches-2.6.26/511-yaffs_reduce_compiler_warnings.patch
new file mode 100644 (file)
index 0000000..61d0a75
--- /dev/null
@@ -0,0 +1,80 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -969,7 +970,7 @@
+               f->f_version = inode->i_version;
+       }
+-      list_for_each(i, &obj->variant.directoryVariant.children) {
++      list_for_each(i, (struct list_head *)&obj->variant.directoryVariant.children) {
+               curoffs++;
+               if (curoffs >= offset) {
+                       l = list_entry(i, yaffs_Object, siblings);
+@@ -1273,7 +1275,7 @@
+       if (target &&
+           target->variantType == YAFFS_OBJECT_TYPE_DIRECTORY &&
+-          !list_empty(&target->variant.directoryVariant.children)) {
++          !list_empty((struct list_head *)&target->variant.directoryVariant.children)) {
+               T(YAFFS_TRACE_OS, (KERN_DEBUG "target is non-empty dir\n"));
+@@ -1529,7 +1531,7 @@
+       yaffs_GrossUnlock(dev);
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_del(&dev->devList);
++      list_del((struct list_head *)&dev->devList);
+       if(dev->spareBuffer){
+               YFREE(dev->spareBuffer);
+@@ -1864,7 +1866,7 @@
+       dev->skipCheckpointWrite = options.skip_checkpoint_write;
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_add_tail(&dev->devList, &yaffs_dev_list);
++      list_add_tail((struct list_head *)&dev->devList, &yaffs_dev_list);
+       init_MUTEX(&dev->grossLock);
+--- a/fs/yaffs2/yaffs_mtdif1.c
++++ b/fs/yaffs2/yaffs_mtdif1.c
+@@ -323,7 +323,7 @@
+  * Always returns YAFFS_OK.
+  */
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * pState, int *pSequenceNumber)
++      yaffs_BlockState * pState, __u32 *pSequenceNumber)
+ {
+       struct mtd_info * mtd = dev->genericDevice;
+       int chunkNo = blockNo * dev->nChunksPerBlock;
+--- a/fs/yaffs2/yaffs_mtdif1.h
++++ b/fs/yaffs2/yaffs_mtdif1.h
+@@ -23,6 +23,6 @@
+ int nandmtd1_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * state, int *sequenceNumber);
++      yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
+--- a/fs/yaffs2/yaffs_mtdif2.c
++++ b/fs/yaffs2/yaffs_mtdif2.c
+@@ -204,7 +204,7 @@
+ }
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber)
++                          yaffs_BlockState * state, __u32 *sequenceNumber)
+ {
+       struct mtd_info *mtd = (struct mtd_info *)(dev->genericDevice);
+       int retval;
+--- a/fs/yaffs2/yaffs_mtdif2.h
++++ b/fs/yaffs2/yaffs_mtdif2.h
+@@ -24,6 +24,6 @@
+                                      __u8 * data, yaffs_ExtendedTags * tags);
+ int nandmtd2_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber);
++                          yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
diff --git a/target/linux/generic-2.6/patches-2.6.26/512-yaffs_2.6.25_fix.patch b/target/linux/generic-2.6/patches-2.6.26/512-yaffs_2.6.25_fix.patch
new file mode 100644 (file)
index 0000000..ac89534
--- /dev/null
@@ -0,0 +1,92 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -181,7 +181,13 @@
+ #else
+ static int yaffs_statfs(struct super_block *sb, struct statfs *buf);
+ #endif
++
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
++static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino);
++#else
+ static void yaffs_read_inode(struct inode *inode);
++#endif
++
+ static void yaffs_put_inode(struct inode *inode);
+ static void yaffs_delete_inode(struct inode *);
+@@ -284,7 +290,9 @@
+ static struct super_operations yaffs_super_ops = {
+       .statfs = yaffs_statfs,
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25))
+       .read_inode = yaffs_read_inode,
++#endif
+       .put_inode = yaffs_put_inode,
+       .put_super = yaffs_put_super,
+       .delete_inode = yaffs_delete_inode,
+@@ -844,11 +852,17 @@
+       T(YAFFS_TRACE_OS,
+         (KERN_DEBUG "yaffs_get_inode for object %d\n", obj->objectId));
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
++      inode = yaffs_iget(sb, obj->objectId);
++      if (IS_ERR(inode))
++              return NULL;
++#else
+       inode = iget(sb, obj->objectId);
+       /* NB Side effect: iget calls back to yaffs_read_inode(). */
+       /* iget also increments the inode's i_count */
+       /* NB You can't be holding grossLock or deadlock will happen! */
++#endif
+       return inode;
+ }
+@@ -1427,6 +1441,39 @@
+ }
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25))
++static struct inode *yaffs_iget(struct super_block *sb, unsigned long ino)
++{
++      yaffs_Object *obj;
++      yaffs_Device *dev = yaffs_SuperToDevice(sb);
++      struct inode *inode;
++
++      T(YAFFS_TRACE_OS,
++        (KERN_DEBUG "yaffs_iget for %lu\n", ino));
++
++      inode = iget_locked(sb, ino);
++      if (!inode)
++              return ERR_PTR(-ENOMEM);
++      if (!(inode->i_state & I_NEW))
++              return inode;
++
++      /* NB This is called as a side effect of other functions, but
++       * we had to release the lock to prevent deadlocks, so
++       * need to lock again.
++       */
++
++      yaffs_GrossLock(dev);
++
++      obj = yaffs_FindObjectByNumber(dev, inode->i_ino);
++
++      yaffs_FillInodeFromObject(inode, obj);
++
++      yaffs_GrossUnlock(dev);
++
++      unlock_new_inode(inode);
++      return inode;
++}
++#else
+ static void yaffs_read_inode(struct inode *inode)
+ {
+       /* NB This is called as a side effect of other functions, but
+@@ -1448,6 +1495,7 @@
+       yaffs_GrossUnlock(dev);
+ }
++#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25)) */
+ static LIST_HEAD(yaffs_dev_list);
diff --git a/target/linux/generic-2.6/patches/510-Yaffs.patch b/target/linux/generic-2.6/patches/510-Yaffs.patch
deleted file mode 100644 (file)
index 233cd20..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-Index: linux-2.6.21.7/fs/Kconfig
-===================================================================
---- linux-2.6.21.7.orig/fs/Kconfig
-+++ linux-2.6.21.7/fs/Kconfig
-@@ -419,6 +419,7 @@ config FS_POSIX_ACL
- source "fs/xfs/Kconfig"
- source "fs/gfs2/Kconfig"
-+source "fs/yaffs2/Kconfig"
- config OCFS2_FS
-       tristate "OCFS2 file system support"
-Index: linux-2.6.21.7/fs/Makefile
-===================================================================
---- linux-2.6.21.7.orig/fs/Makefile
-+++ linux-2.6.21.7/fs/Makefile
-@@ -116,3 +116,4 @@ obj-$(CONFIG_HPPFS)                += hppfs/
- obj-$(CONFIG_DEBUG_FS)                += debugfs/
- obj-$(CONFIG_OCFS2_FS)                += ocfs2/
- obj-$(CONFIG_GFS2_FS)           += gfs2/
-+obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches/510-yaffs_support.patch b/target/linux/generic-2.6/patches/510-yaffs_support.patch
new file mode 100644 (file)
index 0000000..233cd20
--- /dev/null
@@ -0,0 +1,21 @@
+Index: linux-2.6.21.7/fs/Kconfig
+===================================================================
+--- linux-2.6.21.7.orig/fs/Kconfig
++++ linux-2.6.21.7/fs/Kconfig
+@@ -419,6 +419,7 @@ config FS_POSIX_ACL
+ source "fs/xfs/Kconfig"
+ source "fs/gfs2/Kconfig"
++source "fs/yaffs2/Kconfig"
+ config OCFS2_FS
+       tristate "OCFS2 file system support"
+Index: linux-2.6.21.7/fs/Makefile
+===================================================================
+--- linux-2.6.21.7.orig/fs/Makefile
++++ linux-2.6.21.7/fs/Makefile
+@@ -116,3 +116,4 @@ obj-$(CONFIG_HPPFS)                += hppfs/
+ obj-$(CONFIG_DEBUG_FS)                += debugfs/
+ obj-$(CONFIG_OCFS2_FS)                += ocfs2/
+ obj-$(CONFIG_GFS2_FS)           += gfs2/
++obj-$(CONFIG_YAFFS_FS)                += yaffs2/
diff --git a/target/linux/generic-2.6/patches/511-yaffs_reduce_compiler_warnings.patch b/target/linux/generic-2.6/patches/511-yaffs_reduce_compiler_warnings.patch
new file mode 100644 (file)
index 0000000..61d0a75
--- /dev/null
@@ -0,0 +1,80 @@
+--- a/fs/yaffs2/yaffs_fs.c
++++ b/fs/yaffs2/yaffs_fs.c
+@@ -969,7 +970,7 @@
+               f->f_version = inode->i_version;
+       }
+-      list_for_each(i, &obj->variant.directoryVariant.children) {
++      list_for_each(i, (struct list_head *)&obj->variant.directoryVariant.children) {
+               curoffs++;
+               if (curoffs >= offset) {
+                       l = list_entry(i, yaffs_Object, siblings);
+@@ -1273,7 +1275,7 @@
+       if (target &&
+           target->variantType == YAFFS_OBJECT_TYPE_DIRECTORY &&
+-          !list_empty(&target->variant.directoryVariant.children)) {
++          !list_empty((struct list_head *)&target->variant.directoryVariant.children)) {
+               T(YAFFS_TRACE_OS, (KERN_DEBUG "target is non-empty dir\n"));
+@@ -1529,7 +1531,7 @@
+       yaffs_GrossUnlock(dev);
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_del(&dev->devList);
++      list_del((struct list_head *)&dev->devList);
+       if(dev->spareBuffer){
+               YFREE(dev->spareBuffer);
+@@ -1864,7 +1866,7 @@
+       dev->skipCheckpointWrite = options.skip_checkpoint_write;
+       /* we assume this is protected by lock_kernel() in mount/umount */
+-      list_add_tail(&dev->devList, &yaffs_dev_list);
++      list_add_tail((struct list_head *)&dev->devList, &yaffs_dev_list);
+       init_MUTEX(&dev->grossLock);
+--- a/fs/yaffs2/yaffs_mtdif1.c
++++ b/fs/yaffs2/yaffs_mtdif1.c
+@@ -323,7 +323,7 @@
+  * Always returns YAFFS_OK.
+  */
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * pState, int *pSequenceNumber)
++      yaffs_BlockState * pState, __u32 *pSequenceNumber)
+ {
+       struct mtd_info * mtd = dev->genericDevice;
+       int chunkNo = blockNo * dev->nChunksPerBlock;
+--- a/fs/yaffs2/yaffs_mtdif1.h
++++ b/fs/yaffs2/yaffs_mtdif1.h
+@@ -23,6 +23,6 @@
+ int nandmtd1_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd1_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-      yaffs_BlockState * state, int *sequenceNumber);
++      yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
+--- a/fs/yaffs2/yaffs_mtdif2.c
++++ b/fs/yaffs2/yaffs_mtdif2.c
+@@ -204,7 +204,7 @@
+ }
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber)
++                          yaffs_BlockState * state, __u32 *sequenceNumber)
+ {
+       struct mtd_info *mtd = (struct mtd_info *)(dev->genericDevice);
+       int retval;
+--- a/fs/yaffs2/yaffs_mtdif2.h
++++ b/fs/yaffs2/yaffs_mtdif2.h
+@@ -24,6 +24,6 @@
+                                      __u8 * data, yaffs_ExtendedTags * tags);
+ int nandmtd2_MarkNANDBlockBad(struct yaffs_DeviceStruct *dev, int blockNo);
+ int nandmtd2_QueryNANDBlock(struct yaffs_DeviceStruct *dev, int blockNo,
+-                          yaffs_BlockState * state, int *sequenceNumber);
++                          yaffs_BlockState * state, __u32 *sequenceNumber);
+ #endif
This page took 0.050265 seconds and 4 git commands to generate.