ocfs2: bad kunmap_atomic()
authorJens Axboe <jens.axboe@oracle.com>
Tue, 24 Jul 2007 08:17:50 +0000 (10:17 +0200)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Tue, 24 Jul 2007 23:02:55 +0000 (16:02 -0700)
kunmap_atomic() takes the virtual address, not the mapped page as
argument.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Cc: Mark Fasheh <mark.fasheh@oracle.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/ocfs2/file.c

index 5727cd18302ac731e574066aa0c6f19129132484..c4034f693e7b29b4ae0716fa54d7b45b02fc2207 100644 (file)
@@ -2153,7 +2153,7 @@ static int ocfs2_splice_write_actor(struct pipe_inode_info *pipe,
        src = buf->ops->map(pipe, buf, 1);
        dst = kmap_atomic(page, KM_USER1);
        memcpy(dst + offset, src + buf->offset, count);
-       kunmap_atomic(page, KM_USER1);
+       kunmap_atomic(dst, KM_USER1);
        buf->ops->unmap(pipe, buf, src);
 
        copied = ocfs2_write_end(file, file->f_mapping, sd->pos, count, count,