yaffs: By default route all writes into the yaffs cache
[yaffs2.git] / yaffs_guts.h
index 6e48d1361bfa5742955c669af5bed27bd8d983f8..f4fe47519677726c314e0e54d36cf2d35165b37d 100644 (file)
@@ -54,6 +54,8 @@
                                        YAFFS_TNODES_MAX_LEVEL)
 #define YAFFS_MAX_CHUNK_ID             ((1 << YAFFS_TNODES_MAX_BITS) - 1)
 
+#define YAFFS_MAX_FILE_SIZE_32         0x7fffffff
+
 /* Constants for YAFFS1 mode */
 #define YAFFS_BYTES_PER_SPARE          16
 #define YAFFS_BYTES_PER_CHUNK          512
@@ -75,7 +77,9 @@
 #define YAFFS_OBJECT_SPACE             0x40000
 #define YAFFS_MAX_OBJECT_ID            (YAFFS_OBJECT_SPACE - 1)
 
-#define YAFFS_CHECKPOINT_VERSION       5
+/* Binary data version stamps */
+#define YAFFS_SUMMARY_VERSION          1
+#define YAFFS_CHECKPOINT_VERSION       7
 
 #ifdef CONFIG_YAFFS_UNICODE
 #define YAFFS_MAX_NAME_LENGTH          127
@@ -516,7 +520,7 @@ struct yaffs_param {
        /*
         * Entry parameters set up way early. Yaffs sets up the rest.
         * The structure should be zeroed out before use so that unused
-        * and defualt values are zero.
+        * and default values are zero.
         */
 
        int inband_tags;        /* Use unband tags */
@@ -532,9 +536,13 @@ struct yaffs_param {
        int n_caches;           /* If <= 0, then short op caching is disabled,
                                 * else the number of short op caches.
                                 */
+       int cache_bypass_aligned; /* If non-zero then bypass the cache for
+                                  * aligned writes.
+                                  */
+
        int use_nand_ecc;       /* Flag to decide whether or not to use
                                 * NAND driver ECC on data (yaffs1) */
-        int tags_9bytes;       /* Use 9 byte tags */
+       int tags_9bytes;        /* Use 9 byte tags */
        int no_tags_ecc;        /* Flag to decide whether or not to do ECC
                                 * on packed tags (yaffs2) */
 
@@ -603,6 +611,11 @@ struct yaffs_param {
        int always_check_erased;        /* Force chunk erased check always on */
 
        int disable_summary;
+
+       int max_objects;        /*
+                                * Set to limit the number of objects created.
+                                * 0 = no limit.
+                               */
 };
 
 struct yaffs_dev {