Btrfs: Don't use kmap_atomic(..., KM_IRQ0) during checksum verifies
[safe/jmp/linux-2.6] / fs / btrfs / hash.h
index 868ee17..2a020b2 100644 (file)
 
 #ifndef __HASH__
 #define __HASH__
-u64 btrfs_name_hash(const char *name, int len);
+
+#include "crc32c.h"
+static inline u64 btrfs_name_hash(const char *name, int len)
+{
+       return btrfs_crc32c((u32)~1, name, len);
+}
 #endif