]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
NTFS: Fix sparse warnings that have crept in over time.
authorAnton Altaparmakov <aia21@cantab.net>
Thu, 22 Sep 2005 12:26:44 +0000 (13:26 +0100)
committerAnton Altaparmakov <aia21@cantab.net>
Thu, 22 Sep 2005 12:26:44 +0000 (13:26 +0100)
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
fs/ntfs/ChangeLog
fs/ntfs/layout.h
fs/ntfs/logfile.h

index c7e9237379c233bae7d99490ec6f637a7233221b..ee8665f62a65241ac78708bf9aa1f1296ea5aad3 100644 (file)
@@ -22,6 +22,10 @@ ToDo/Notes:
        - Enable the code for setting the NT4 compatibility flag when we start
          making NTFS 1.2 specific modifications.
 
+2.1.25-WIP
+
+       - Fix sparse warnings that have crept in over time.
+
 2.1.24 - Lots of bug fixes and support more clean journal states.
 
        - Support journals ($LogFile) which have been modified by chkdsk.  This
index 609ad1728ce4c74cb14531ad77438b06aefef4f0..dbf5c2a06dabd7fc41a23475dd0bd31ee618446f 100644 (file)
@@ -317,12 +317,13 @@ typedef u64 MFT_REF;
 typedef le64 leMFT_REF;
 
 #define MK_MREF(m, s)  ((MFT_REF)(((MFT_REF)(s) << 48) |               \
-                                       ((MFT_REF)(m) & MFT_REF_MASK_CPU)))
+                                       ((MFT_REF)(m) & (u64)MFT_REF_MASK_CPU)))
 #define MK_LE_MREF(m, s) cpu_to_le64(MK_MREF(m, s))
 
-#define MREF(x)                ((unsigned long)((x) & MFT_REF_MASK_CPU))
+#define MREF(x)                ((unsigned long)((x) & (u64)MFT_REF_MASK_CPU))
 #define MSEQNO(x)      ((u16)(((x) >> 48) & 0xffff))
-#define MREF_LE(x)     ((unsigned long)(le64_to_cpu(x) & MFT_REF_MASK_CPU))
+#define MREF_LE(x)     ((unsigned long)(le64_to_cpu(x) &               \
+                                       (u64)MFT_REF_MASK_CPU))
 #define MSEQNO_LE(x)   ((u16)((le64_to_cpu(x) >> 48) & 0xffff))
 
 #define IS_ERR_MREF(x) (((x) & 0x0000800000000000ULL) ? 1 : 0)
index 42388f95ea6da5b008a092ea04f8eff0d49b3cc7..a51f3dd0e9eb56c106f3935b14c4d2d7ed76cbc7 100644 (file)
@@ -113,7 +113,7 @@ typedef struct {
  */
 enum {
        RESTART_VOLUME_IS_CLEAN = const_cpu_to_le16(0x0002),
-       RESTART_SPACE_FILLER    = 0xffff, /* gcc: Force enum bit width to 16. */
+       RESTART_SPACE_FILLER    = const_cpu_to_le16(0xffff), /* gcc: Force enum bit width to 16. */
 } __attribute__ ((__packed__));
 
 typedef le16 RESTART_AREA_FLAGS;