]> git.hungrycats.org Git - linux/commitdiff
NTFS: Fix warnings on x86-64. (Randy Dunlap with slight modification from me)
authorAnton Altaparmakov <aia21@cantab.net>
Sun, 10 Oct 2004 22:24:12 +0000 (23:24 +0100)
committerAnton Altaparmakov <aia21@cantab.net>
Sun, 10 Oct 2004 22:24:12 +0000 (23:24 +0100)
Fix printk arg type warnings on x86-64 (and OK on x86-32) (gcc 3.3.3):
fs/ntfs/dir.c:1272: warning: long long unsigned int format, long unsigned int arg (arg 6)
fs/ntfs/dir.c:1388: warning: long long unsigned int format, long unsigned int arg (arg 5

Signed-off-by: Randy Dunlap <rddunlap@osdl.org>
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
fs/ntfs/ChangeLog
fs/ntfs/dir.c
fs/ntfs/inode.c

index f532f388ea3d1177c0c51de87f1ddbd40d083e9b..91b23be8c7dbcef02862a64a9bdbc0f68ff060bc 100644 (file)
@@ -68,6 +68,8 @@ ToDo/Notes:
        - Update fs/ntfs/inode.c::ntfs_write_inode() to also use the helper
          mark_ntfs_record_dirty() and thus to set the buffers belonging to the
          mft record dirty as well as the page itself.
+       - Fix compiler warnings on x86-64 in fs/ntfs/dir.c.  (Randy Dunlap,
+         slightly modified by me)
 
 2.1.20 - Fix two stupid bugs introduced in 2.1.18 release.
 
index 2700e4bd557436ca6f2dc884e6c645be70ad9ea4..9b8594d4311b3247b42032aef56da7384649c999 100644 (file)
@@ -1278,7 +1278,7 @@ get_next_bmp_page:
        ntfs_debug("Reading bitmap with page index 0x%llx, bit ofs 0x%llx",
                        (unsigned long long)bmp_pos >> (3 + PAGE_CACHE_SHIFT),
                        (unsigned long long)bmp_pos &
-                       ((PAGE_CACHE_SIZE * 8) - 1));
+                       (unsigned long long)((PAGE_CACHE_SIZE * 8) - 1));
        bmp_page = ntfs_map_page(bmp_mapping,
                        bmp_pos >> (3 + PAGE_CACHE_SHIFT));
        if (IS_ERR(bmp_page)) {
@@ -1392,8 +1392,8 @@ find_next_index_buffer:
         */
        for (;; ie = (INDEX_ENTRY*)((u8*)ie + le16_to_cpu(ie->length))) {
                ntfs_debug("In index allocation, offset 0x%llx.",
-                               (unsigned long long)ia_start + ((u8*)ie -
-                               (u8*)ia));
+                               (unsigned long long)ia_start +
+                               (unsigned long long)((u8*)ie - (u8*)ia));
                /* Bounds checks. */
                if (unlikely((u8*)ie < (u8*)ia || (u8*)ie +
                                sizeof(INDEX_ENTRY_HEADER) > index_end ||
index e8354aa419710b3d3404be8152b3f4495f3a7940..3589040b78e69a147b111eadbe4a43c0ca97f2f0 100644 (file)
@@ -25,7 +25,7 @@
 #include <linux/quotaops.h>
 #include <linux/mount.h>
 
-#include "ntfs.h"
+#include "aops.h"
 #include "dir.h"
 #include "debug.h"
 #include "inode.h"
@@ -33,6 +33,7 @@
 #include "malloc.h"
 #include "mft.h"
 #include "time.h"
+#include "ntfs.h"
 
 /**
  * ntfs_test_inode - compare two (possibly fake) inodes for equality