summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert@linux-m68k.org>2013-08-23 15:46:48 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-08-23 17:21:21 (GMT)
commit917ea9a3e1133841d1b1a496fa93036729cbf5c2 (patch)
treea76bc75262f622548e4f3d2fe0a1093e267a4fd6 /drivers
parent4e7fb829771de2cf8a5ba9576290d76936d3e814 (diff)
downloadlinux-fsl-qoriq-917ea9a3e1133841d1b1a496fa93036729cbf5c2.tar.xz
staging: lustre: Use proper constant types for L*_POISON values
On 32-bit m68k, I get lots of warnings like: warning: integer constant is too large for ‘long’ type Switch the L*_POISON definitions from too-large constants and casts to the proper constant types to fix this. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/lustre/include/linux/libcfs/linux/kp30.h10
-rw-r--r--drivers/staging/lustre/lustre/include/linux/lustre_lib.h10
2 files changed, 11 insertions, 9 deletions
diff --git a/drivers/staging/lustre/include/linux/libcfs/linux/kp30.h b/drivers/staging/lustre/include/linux/libcfs/linux/kp30.h
index 073f4d1..c204b67 100644
--- a/drivers/staging/lustre/include/linux/libcfs/linux/kp30.h
+++ b/drivers/staging/lustre/include/linux/libcfs/linux/kp30.h
@@ -187,9 +187,13 @@ extern int lwt_snapshot (cfs_cycles_t *now, int *ncpu, int *total_size,
# endif
#endif
-# define LI_POISON ((int)0x5a5a5a5a5a5a5a5a)
-# define LL_POISON ((long)0x5a5a5a5a5a5a5a5a)
-# define LP_POISON ((void *)(long)0x5a5a5a5a5a5a5a5a)
+# define LI_POISON 0x5a5a5a5a
+#if BITS_PER_LONG > 32
+# define LL_POISON 0x5a5a5a5a5a5a5a5aL
+#else
+# define LL_POISON 0x5a5a5a5aL
+#endif
+# define LP_POISON ((void *)LL_POISON)
/* this is a bit chunky */
diff --git a/drivers/staging/lustre/lustre/include/linux/lustre_lib.h b/drivers/staging/lustre/lustre/include/linux/lustre_lib.h
index b2f755a..57f3b01 100644
--- a/drivers/staging/lustre/lustre/include/linux/lustre_lib.h
+++ b/drivers/staging/lustre/lustre/include/linux/lustre_lib.h
@@ -53,15 +53,13 @@
# include <linux/lustre_common.h>
#ifndef LP_POISON
+# define LI_POISON 0x5a5a5a5a
#if BITS_PER_LONG > 32
-# define LI_POISON ((int)0x5a5a5a5a5a5a5a5a)
-# define LL_POISON ((long)0x5a5a5a5a5a5a5a5a)
-# define LP_POISON ((void *)(long)0x5a5a5a5a5a5a5a5a)
+# define LL_POISON 0x5a5a5a5a5a5a5a5aL
#else
-# define LI_POISON ((int)0x5a5a5a5a)
-# define LL_POISON ((long)0x5a5a5a5a)
-# define LP_POISON ((void *)(long)0x5a5a5a5a)
+# define LL_POISON 0x5a5a5a5aL
#endif
+# define LP_POISON ((void *)LL_POISON)
#endif
/* This macro is only for compatibility reasons with older Linux Lustre user