]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - fs/ocfs2/aops.c
[JFFS2] Fix 64-bit size_t problems in XATTR code.
[karo-tx-linux.git] / fs / ocfs2 / aops.c
index bf931ba1d36478e323f3e1c4ebc54be12ea335fb..0d858d0b25be70f496e1fb0ec863ec4778ae3c57 100644 (file)
@@ -540,7 +540,6 @@ bail:
  *                                     fs_count, map_bh, dio->rw == WRITE);
  */
 static int ocfs2_direct_IO_get_blocks(struct inode *inode, sector_t iblock,
-                                    unsigned long max_blocks,
                                     struct buffer_head *bh_result, int create)
 {
        int ret;
@@ -548,6 +547,7 @@ static int ocfs2_direct_IO_get_blocks(struct inode *inode, sector_t iblock,
        u64 p_blkno;
        int contig_blocks;
        unsigned char blocksize_bits;
+       unsigned long max_blocks = bh_result->b_size >> inode->i_blkbits;
 
        if (!inode || !bh_result) {
                mlog(ML_ERROR, "inode or bh_result is null\n");