diff options
author | Chris Mason <chris.mason@oracle.com> | 2007-03-28 19:44:27 -0400 |
---|---|---|
committer | David Woodhouse <dwmw2@hera.kernel.org> | 2007-03-28 19:44:27 -0400 |
commit | 87cbda5c1f54aba67b1e318a4a4824c9e9f16324 (patch) | |
tree | ba2917a8bcd00272c77c93236006fd8562566946 /fs/btrfs/ctree.h | |
parent | d98237b3ede7ab98892f7fa62201a13694c526e2 (diff) | |
download | kernel-crypto-87cbda5c1f54aba67b1e318a4a4824c9e9f16324.tar.gz kernel-crypto-87cbda5c1f54aba67b1e318a4a4824c9e9f16324.tar.xz kernel-crypto-87cbda5c1f54aba67b1e318a4a4824c9e9f16324.zip |
Btrfs: sha256 csums on metadata
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/ctree.h')
-rw-r--r-- | fs/btrfs/ctree.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h index b2ebed756c1..6ff87f44c5d 100644 --- a/fs/btrfs/ctree.h +++ b/fs/btrfs/ctree.h @@ -51,11 +51,11 @@ struct btrfs_key { * every tree block (leaf or node) starts with this header. */ struct btrfs_header { + __le32 csum[8]; u8 fsid[16]; /* FS specific uuid */ __le64 blocknr; /* which block this node is supposed to live in */ __le64 generation; __le64 parentid; /* objectid of the tree root */ - __le32 csum; __le32 ham; __le16 nritems; __le16 flags; @@ -75,9 +75,10 @@ struct buffer_head; * it currently lacks any block count etc etc */ struct btrfs_super_block { + __le32 csum[8]; + /* the first 3 fields must match struct btrfs_header */ u8 fsid[16]; /* FS specific uuid */ __le64 blocknr; /* this block number */ - __le32 csum; __le64 magic; __le32 blocksize; __le64 generation; @@ -217,6 +218,7 @@ struct btrfs_inode_map_item { struct btrfs_disk_key key; } __attribute__ ((__packed__)); +struct crypto_hash; struct btrfs_fs_info { struct btrfs_root *fs_root; struct btrfs_root *extent_root; @@ -236,6 +238,8 @@ struct btrfs_fs_info { struct inode *btree_inode; struct mutex trans_mutex; struct mutex fs_mutex; + struct crypto_hash *hash_tfm; + spinlock_t hash_lock; }; /* |