ext4: Fix build warning in ext4_dirty_inode()
[safe/jmp/linux-2.6] / fs / nilfs2 / mdt.c
index 1ae8d56..b18c499 100644 (file)
@@ -136,7 +136,7 @@ nilfs_mdt_submit_block(struct inode *inode, unsigned long blkoff,
                       int mode, struct buffer_head **out_bh)
 {
        struct buffer_head *bh;
-       unsigned long blknum = 0;
+       __u64 blknum = 0;
        int ret = -ENOMEM;
 
        bh = nilfs_grab_buffer(inode, inode->i_mapping, blkoff, 0);
@@ -166,7 +166,7 @@ nilfs_mdt_submit_block(struct inode *inode, unsigned long blkoff,
                goto failed_bh;
        }
        bh->b_bdev = NILFS_MDT(inode)->mi_nilfs->ns_bdev;
-       bh->b_blocknr = blknum;
+       bh->b_blocknr = (sector_t)blknum;
        set_buffer_mapped(bh);
 
        bh->b_end_io = end_buffer_read_sync;
@@ -427,12 +427,12 @@ nilfs_mdt_write_page(struct page *page, struct writeback_control *wbc)
 }
 
 
-static struct address_space_operations def_mdt_aops = {
+static const struct address_space_operations def_mdt_aops = {
        .writepage              = nilfs_mdt_write_page,
        .sync_page              = block_sync_page,
 };
 
-static struct inode_operations def_mdt_iops;
+static const struct inode_operations def_mdt_iops;
 static struct file_operations def_mdt_fops;
 
 /*
@@ -513,9 +513,10 @@ nilfs_mdt_new_common(struct the_nilfs *nilfs, struct super_block *sb,
 }
 
 struct inode *nilfs_mdt_new(struct the_nilfs *nilfs, struct super_block *sb,
-                           ino_t ino, gfp_t gfp_mask)
+                           ino_t ino)
 {
-       struct inode *inode = nilfs_mdt_new_common(nilfs, sb, ino, gfp_mask);
+       struct inode *inode = nilfs_mdt_new_common(nilfs, sb, ino,
+                                                  NILFS_MDT_GFP);
 
        if (!inode)
                return NULL;