* GPL HEADER END
*/
/*
- * Copyright (c) 2014, 2015, Intel Corporation.
+ * Copyright (c) 2014, 2016, Intel Corporation.
*/
/*
* lustre/include/lustre_lmv.h
static inline unsigned int
lmv_hash_fnv1a(unsigned int count, const char *name, int namelen)
{
- __u64 hash;
+ __u64 hash;
hash = lustre_hash_fnv_1a_64(name, namelen);
- hash = hash % count;
-
- return hash;
+ return do_div(hash, count);
}
static inline int lmv_name_to_stripe_index(__u32 lmv_hash_type,