diff options
Diffstat (limited to 'hash.h')
-rw-r--r-- | hash.h | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -18,5 +18,10 @@ #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 crc32c((u32)~1, name, len); +} #endif |