[PATCH] cifs: Use ULL suffix for 64-bit constant

From: Geert Uytterhoeven
Date: Thu Apr 05 2018 - 08:57:18 EST


On 32-bit (e.g. with m68k-linux-gnu-gcc-4.1):

fs/cifs/inode.c: In function âsimple_hashstrâ:
fs/cifs/inode.c:713: warning: integer constant is too large for âlongâ type

Fixes: 7ea884c77e5c97f1 ("smb3: Fix root directory when server returns inode number of zero")
Signed-off-by: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
---
fs/cifs/inode.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c
index f856df4adae3c8e8..3c371f7f5963e793 100644
--- a/fs/cifs/inode.c
+++ b/fs/cifs/inode.c
@@ -710,7 +710,7 @@ cifs_get_file_info(struct file *filp)
/* Simple function to return a 64 bit hash of string. Rarely called */
static __u64 simple_hashstr(const char *str)
{
- const __u64 hash_mult = 1125899906842597L; /* a big enough prime */
+ const __u64 hash_mult = 1125899906842597ULL; /* a big enough prime */
__u64 hash = 0;

while (*str)
--
2.7.4