diff options
Diffstat (limited to 'fs/ext4/hash.c')
| -rw-r--r-- | fs/ext4/hash.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/ext4/hash.c b/fs/ext4/hash.c index 1d6329dbe390..556ca8eba3db 100644 --- a/fs/ext4/hash.c +++ b/fs/ext4/hash.c | |||
| @@ -27,7 +27,7 @@ static void TEA_transform(__u32 buf[4], __u32 const in[]) | |||
| 27 | sum += DELTA; | 27 | sum += DELTA; |
| 28 | b0 += ((b1 << 4)+a) ^ (b1+sum) ^ ((b1 >> 5)+b); | 28 | b0 += ((b1 << 4)+a) ^ (b1+sum) ^ ((b1 >> 5)+b); |
| 29 | b1 += ((b0 << 4)+c) ^ (b0+sum) ^ ((b0 >> 5)+d); | 29 | b1 += ((b0 << 4)+c) ^ (b0+sum) ^ ((b0 >> 5)+d); |
| 30 | } while(--n); | 30 | } while (--n); |
| 31 | 31 | ||
| 32 | buf[0] += b0; | 32 | buf[0] += b0; |
| 33 | buf[1] += b1; | 33 | buf[1] += b1; |
| @@ -35,7 +35,7 @@ static void TEA_transform(__u32 buf[4], __u32 const in[]) | |||
| 35 | 35 | ||
| 36 | 36 | ||
| 37 | /* The old legacy hash */ | 37 | /* The old legacy hash */ |
| 38 | static __u32 dx_hack_hash (const char *name, int len) | 38 | static __u32 dx_hack_hash(const char *name, int len) |
| 39 | { | 39 | { |
| 40 | __u32 hash0 = 0x12a3fe2d, hash1 = 0x37abe8f9; | 40 | __u32 hash0 = 0x12a3fe2d, hash1 = 0x37abe8f9; |
| 41 | while (len--) { | 41 | while (len--) { |
| @@ -59,7 +59,7 @@ static void str2hashbuf(const char *msg, int len, __u32 *buf, int num) | |||
| 59 | val = pad; | 59 | val = pad; |
| 60 | if (len > num*4) | 60 | if (len > num*4) |
| 61 | len = num * 4; | 61 | len = num * 4; |
| 62 | for (i=0; i < len; i++) { | 62 | for (i = 0; i < len; i++) { |
| 63 | if ((i % 4) == 0) | 63 | if ((i % 4) == 0) |
| 64 | val = pad; | 64 | val = pad; |
| 65 | val = msg[i] + (val << 8); | 65 | val = msg[i] + (val << 8); |
| @@ -104,7 +104,7 @@ int ext4fs_dirhash(const char *name, int len, struct dx_hash_info *hinfo) | |||
| 104 | 104 | ||
| 105 | /* Check to see if the seed is all zero's */ | 105 | /* Check to see if the seed is all zero's */ |
| 106 | if (hinfo->seed) { | 106 | if (hinfo->seed) { |
| 107 | for (i=0; i < 4; i++) { | 107 | for (i = 0; i < 4; i++) { |
| 108 | if (hinfo->seed[i]) | 108 | if (hinfo->seed[i]) |
| 109 | break; | 109 | break; |
| 110 | } | 110 | } |
