--- linux-2.4.20pre5aa1/fs/xfs/linux/xfs_aops.c Thu Sep 5 13:39:05 2002 +++ linux-xfs/fs/xfs/linux/xfs_aops.c Wed Sep 4 22:20:09 2002 @@ -779,11 +779,12 @@ linvfs_prepare_write( STATIC int linvfs_direct_IO( int rw, - struct inode *inode, + struct file *file, struct kiobuf *iobuf, unsigned long blocknr, int blocksize) { + struct inode *inode; struct page **maplist; size_t page_offset; page_buf_t *pb; @@ -794,11 +795,12 @@ linvfs_direct_IO( loff_t offset; size_t map_size, size; + inode = file->f_dentry->d_inode; + maplist = iobuf->maplist; + total = length = iobuf->length; offset = blocknr; offset <<= inode->i_blkbits; - - maplist = iobuf->maplist; page_offset = iobuf->offset; map_flags = (rw ? PBF_WRITE : PBF_READ) | PBF_DIRECT;