proc: move /proc/diskstats boilerplate to block/genhd.c
[safe/jmp/linux-2.6] / include / linux / jffs2.h
index 2cac60e..da720bc 100644 (file)
@@ -7,20 +7,17 @@
  *
  * For licensing information, see the file 'LICENCE' in the
  * jffs2 directory.
- *
- * $Id: jffs2.h,v 1.38 2005/09/26 11:37:23 havasi Exp $
- *
  */
 
 #ifndef __LINUX_JFFS2_H__
 #define __LINUX_JFFS2_H__
 
+#include <linux/magic.h>
+
 /* You must include something which defines the C99 uintXX_t types. 
    We don't do it from here because this file is used in too many
    different environments. */
 
-#define JFFS2_SUPER_MAGIC 0x72b6
-
 /* Values we may expect to find in the 'magic' field */
 #define JFFS2_OLD_MAGIC_BITMASK 0x1984
 #define JFFS2_MAGIC_BITMASK 0x1985
@@ -46,6 +43,7 @@
 #define JFFS2_COMPR_COPY       0x04
 #define JFFS2_COMPR_DYNRUBIN   0x05
 #define JFFS2_COMPR_ZLIB       0x06
+#define JFFS2_COMPR_LZO                0x07
 /* Compatibility flags. */
 #define JFFS2_COMPAT_MASK 0xc000      /* What do to if an unknown nodetype is found */
 #define JFFS2_NODE_ACCURATE 0x2000
 
 typedef struct {
        uint32_t v32;
-} __attribute__((packed))  jint32_t;
+} __attribute__((packed)) jint32_t;
 
 typedef struct {
        uint32_t m;
-} __attribute__((packed))  jmode_t;
+} __attribute__((packed)) jmode_t;
 
 typedef struct {
        uint16_t v16;
@@ -111,7 +109,7 @@ struct jffs2_unknown_node
        jint16_t nodetype;
        jint32_t totlen; /* So we can skip over nodes we don't grok */
        jint32_t hdr_crc;
-} __attribute__((packed));
+};
 
 struct jffs2_raw_dirent
 {
@@ -129,7 +127,7 @@ struct jffs2_raw_dirent
        jint32_t node_crc;
        jint32_t name_crc;
        uint8_t name[0];
-} __attribute__((packed));
+};
 
 /* The JFFS2 raw inode structure: Used for storage on physical media.  */
 /* The uid, gid, atime, mtime and ctime members could be longer, but
@@ -161,7 +159,7 @@ struct jffs2_raw_inode
        jint32_t data_crc;   /* CRC for the (compressed) data.  */
        jint32_t node_crc;   /* CRC for the raw inode (excluding data)  */
        uint8_t data[0];
-} __attribute__((packed));
+};
 
 struct jffs2_raw_xattr {
        jint16_t magic;
@@ -186,6 +184,7 @@ struct jffs2_raw_xref
        jint32_t hdr_crc;
        jint32_t ino;           /* inode number */
        jint32_t xid;           /* XATTR identifier number */
+       jint32_t xseqno;        /* xref sequencial number */
        jint32_t node_crc;
 } __attribute__((packed));
 
@@ -201,7 +200,7 @@ struct jffs2_raw_summary
        jint32_t sum_crc;       /* summary information crc */
        jint32_t node_crc;      /* node crc */
        jint32_t sum[0];        /* inode summary info */
-} __attribute__((packed));
+};
 
 union jffs2_node_union
 {
@@ -213,4 +212,10 @@ union jffs2_node_union
        struct jffs2_unknown_node u;
 };
 
+/* Data payload for device nodes. */
+union jffs2_device_node {
+       jint16_t old;
+       jint32_t new;
+};
+
 #endif /* __LINUX_JFFS2_H__ */