]> err.no Git - linux-2.6/blobdiff - fs/ext4/hash.c
Merge master.kernel.org:/pub/scm/linux/kernel/git/bart/ide-2.6
[linux-2.6] / fs / ext4 / hash.c
index deeb27b5ba833d25009c33c3c31752fec8d79dd3..1555024e3b36b26a56f8a7c47f191740171f9934 100644 (file)
@@ -1,5 +1,5 @@
 /*
- *  linux/fs/ext3/hash.c
+ *  linux/fs/ext4/hash.c
  *
  * Copyright (C) 2002 by Theodore Ts'o
  *
@@ -10,9 +10,8 @@
  */
 
 #include <linux/fs.h>
-#include <linux/jbd.h>
-#include <linux/sched.h>
-#include <linux/ext3_fs.h>
+#include <linux/jbd2.h>
+#include <linux/ext4_fs.h>
 #include <linux/cryptohash.h>
 
 #define DELTA 0x9E3779B9
@@ -89,7 +88,7 @@ static void str2hashbuf(const char *msg, int len, __u32 *buf, int num)
  * represented, and whether or not the returned hash is 32 bits or 64
  * bits.  32 bit hashes will return 0 for the minor hash.
  */
-int ext3fs_dirhash(const char *name, int len, struct dx_hash_info *hinfo)
+int ext4fs_dirhash(const char *name, int len, struct dx_hash_info *hinfo)
 {
        __u32   hash;
        __u32   minor_hash = 0;
@@ -144,8 +143,8 @@ int ext3fs_dirhash(const char *name, int len, struct dx_hash_info *hinfo)
                return -1;
        }
        hash = hash & ~1;
-       if (hash == (EXT3_HTREE_EOF << 1))
-               hash = (EXT3_HTREE_EOF-1) << 1;
+       if (hash == (EXT4_HTREE_EOF << 1))
+               hash = (EXT4_HTREE_EOF-1) << 1;
        hinfo->hash = hash;
        hinfo->minor_hash = minor_hash;
        return 0;