Fix gcc 64-bit constant warnings
authorRicardo M. Correia <Ricardo.M.Correia@Sun.COM>
Thu, 26 Aug 2010 16:52:39 +0000 (09:52 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Thu, 26 Aug 2010 22:18:01 +0000 (15:18 -0700)
Add 'ull' suffix to 64-bit constants.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
cmd/ztest/ztest.c
module/zfs/include/sys/zfs_znode.h
module/zfs/vdev_raidz.c

index b2d81b5..46d3410 100644 (file)
@@ -4399,7 +4399,7 @@ ztest_fault_inject(ztest_ds_t *zd, uint64_t id)
        int fd;
        uint64_t offset;
        uint64_t leaves;
-       uint64_t bad = 0x1990c0ffeedecade;
+       uint64_t bad = 0x1990c0ffeedecadeull;
        uint64_t top, leaf;
        char path0[MAXPATHLEN];
        char pathrand[MAXPATHLEN];
index 3e9621a..7fa7a0a 100644 (file)
@@ -48,20 +48,20 @@ extern "C" {
  * Additional file level attributes, that are stored
  * in the upper half of zp_flags
  */
-#define        ZFS_READONLY            0x0000000100000000
-#define        ZFS_HIDDEN              0x0000000200000000
-#define        ZFS_SYSTEM              0x0000000400000000
-#define        ZFS_ARCHIVE             0x0000000800000000
-#define        ZFS_IMMUTABLE           0x0000001000000000
-#define        ZFS_NOUNLINK            0x0000002000000000
-#define        ZFS_APPENDONLY          0x0000004000000000
-#define        ZFS_NODUMP              0x0000008000000000
-#define        ZFS_OPAQUE              0x0000010000000000
-#define        ZFS_AV_QUARANTINED      0x0000020000000000
-#define        ZFS_AV_MODIFIED         0x0000040000000000
-#define        ZFS_REPARSE             0x0000080000000000
-#define        ZFS_OFFLINE             0x0000100000000000
-#define        ZFS_SPARSE              0x0000200000000000
+#define        ZFS_READONLY            0x0000000100000000ull
+#define        ZFS_HIDDEN              0x0000000200000000ull
+#define        ZFS_SYSTEM              0x0000000400000000ull
+#define        ZFS_ARCHIVE             0x0000000800000000ull
+#define        ZFS_IMMUTABLE           0x0000001000000000ull
+#define        ZFS_NOUNLINK            0x0000002000000000ull
+#define        ZFS_APPENDONLY          0x0000004000000000ull
+#define        ZFS_NODUMP              0x0000008000000000ull
+#define        ZFS_OPAQUE              0x0000010000000000ull
+#define        ZFS_AV_QUARANTINED      0x0000020000000000ull
+#define        ZFS_AV_MODIFIED         0x0000040000000000ull
+#define        ZFS_REPARSE             0x0000080000000000ull
+#define        ZFS_OFFLINE             0x0000100000000000ull
+#define        ZFS_SPARSE              0x0000200000000000ull
 
 #define        ZFS_ATTR_SET(zp, attr, value, pflags, tx) \
 { \
index 4b0f560..526385e 100644 (file)
@@ -143,7 +143,7 @@ typedef struct raidz_map {
        (mask) = (x) & 0x8080808080808080ULL; \
        (mask) = ((mask) << 1) - ((mask) >> 7); \
        (x) = (((x) << 1) & 0xfefefefefefefefeULL) ^ \
-           ((mask) & 0x1d1d1d1d1d1d1d1d); \
+           ((mask) & 0x1d1d1d1d1d1d1d1dULL); \
 }
 
 #define        VDEV_RAIDZ_64MUL_4(x, mask) \