Re: [PATCH] zero_user_page uses in fs/buffer.c and fs/libfs.c

2007-05-01 Thread Nate Diller
On 5/1/07, Nate Diller <[EMAIL PROTECTED]> wrote: On 5/1/07, Christoph Lameter <[EMAIL PROTECTED]> wrote: > On Tue, 1 May 2007, Andrew Morton wrote: > > > As Satyam said, this will sometimes cause us to map and unmap the page > > twice, and to run flush_dcache_

Re: [PATCH] zero_user_page uses in fs/buffer.c and fs/libfs.c

2007-05-01 Thread Nate Diller
On 5/1/07, Christoph Lameter <[EMAIL PROTECTED]> wrote: On Tue, 1 May 2007, Andrew Morton wrote: > As Satyam said, this will sometimes cause us to map and unmap the page > twice, and to run flush_dcache_page() twice. In not-terribly-uncommon > circumstances in very frequently called functions.

Re: [PATCH] zero_user_page uses in fs/buffer.c and fs/libfs.c

2007-05-01 Thread Nate Diller
On 5/1/07, Christoph Lameter [EMAIL PROTECTED] wrote: On Tue, 1 May 2007, Andrew Morton wrote: As Satyam said, this will sometimes cause us to map and unmap the page twice, and to run flush_dcache_page() twice. In not-terribly-uncommon circumstances in very frequently called functions.

Re: [PATCH] zero_user_page uses in fs/buffer.c and fs/libfs.c

2007-05-01 Thread Nate Diller
On 5/1/07, Nate Diller [EMAIL PROTECTED] wrote: On 5/1/07, Christoph Lameter [EMAIL PROTECTED] wrote: On Tue, 1 May 2007, Andrew Morton wrote: As Satyam said, this will sometimes cause us to map and unmap the page twice, and to run flush_dcache_page() twice. In not-terribly-uncommon

Re: [PATCH 3/17] afs: convert afs_dir_get_page to read_kmap_page

2007-04-12 Thread Nate Diller
On 4/12/07, David Howells <[EMAIL PROTECTED]> wrote: Nate Diller <[EMAIL PROTECTED]> wrote: > Hmmm you're right. Is your security work going into the next -mm? I don't know. Andrew hasn't said anything. Andrew? Are you waiting for it to go through DaveM's networking tree?

Re: [PATCH 1/17] cramfs: use read_mapping_page

2007-04-12 Thread Nate Diller
On 4/12/07, Roman Zippel <[EMAIL PROTECTED]> wrote: Hi, On Thu, 12 Apr 2007, Christoph Hellwig wrote: > On Wed, Apr 11, 2007 at 07:49:38PM -0700, Nate Diller wrote: > > read_mapping_page_async() is going away, so convert its only user to > > read_mapping_page(). Thi

Re: [PATCH 7/17] jffs2: convert jffs2_gc_fetch_page to read_cache_page

2007-04-12 Thread Nate Diller
On 4/12/07, Phillip Lougher <[EMAIL PROTECTED]> wrote: Nate Diller wrote: > + page = read_cache_page(OFNI_EDONI_2SFFJ(f)->i_mapping, > + start >> PAGE_CACHE_SHIFT, > + (void *)

Re: [PATCH 3/17] afs: convert afs_dir_get_page to read_kmap_page

2007-04-12 Thread Nate Diller
On 4/12/07, David Howells <[EMAIL PROTECTED]> wrote: Nate Diller <[EMAIL PROTECTED]> wrote: > -static struct page *afs_dir_get_page(struct inode *dir, unsigned long index) NAK. This conflicts with my AFS security patches, and eliminates any way of passing the key through to rea

Re: [PATCH 3/17] afs: convert afs_dir_get_page to read_kmap_page

2007-04-12 Thread Nate Diller
On 4/12/07, David Howells [EMAIL PROTECTED] wrote: Nate Diller [EMAIL PROTECTED] wrote: -static struct page *afs_dir_get_page(struct inode *dir, unsigned long index) NAK. This conflicts with my AFS security patches, and eliminates any way of passing the key through to readpage(). Hmmm

Re: [PATCH 7/17] jffs2: convert jffs2_gc_fetch_page to read_cache_page

2007-04-12 Thread Nate Diller
On 4/12/07, Phillip Lougher [EMAIL PROTECTED] wrote: Nate Diller wrote: + page = read_cache_page(OFNI_EDONI_2SFFJ(f)-i_mapping, + start PAGE_CACHE_SHIFT, + (void *)jffs2_do_readpage_unlock

Re: [PATCH 1/17] cramfs: use read_mapping_page

2007-04-12 Thread Nate Diller
On 4/12/07, Roman Zippel [EMAIL PROTECTED] wrote: Hi, On Thu, 12 Apr 2007, Christoph Hellwig wrote: On Wed, Apr 11, 2007 at 07:49:38PM -0700, Nate Diller wrote: read_mapping_page_async() is going away, so convert its only user to read_mapping_page(). This change has not been benchmarked

Re: [PATCH 3/17] afs: convert afs_dir_get_page to read_kmap_page

2007-04-12 Thread Nate Diller
On 4/12/07, David Howells [EMAIL PROTECTED] wrote: Nate Diller [EMAIL PROTECTED] wrote: Hmmm you're right. Is your security work going into the next -mm? I don't know. Andrew hasn't said anything. Andrew? Are you waiting for it to go through DaveM's networking tree? If so, I'll just re

[PATCH 6/17] hfs: remove redundant read_mapping_page error check

2007-04-11 Thread Nate Diller
Now that read_mapping_page() does error checking internally, there is no need to check PageError here. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/hfs/bnode.c linux-2.6.21-rc6-mm1-test/fs/hfs/bnode.c --- linux-2.6.21-rc6-mm1/fs/hfs/b

[PATCH 7/17] jffs2: convert jffs2_gc_fetch_page to read_cache_page

2007-04-11 Thread Nate Diller
Replace jffs2_gc_fetch_page() and jffs2_gc_release_page() using the read_cache_page() and put_kmapped_page() calls, and update the call site accordingly. Explicit calls to kmap()/kunmap() make the code more clear. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff

[PATCH 11/17] ntfs: convert ntfs_map_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace ntfs_map_page() and ntfs_unmap_page() using the new read_kmap_page() and put_kmapped_page() calls, and their locking variants, and remove unneeded PageError checking. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/ntfs/aops.h

[PATCH 1/17] cramfs: use read_mapping_page

2007-04-11 Thread Nate Diller
-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/cramfs/inode.c linux-2.6.21-rc6-mm1-test/fs/cramfs/inode.c --- linux-2.6.21-rc6-mm1/fs/cramfs/inode.c 2007-04-09 17:24:03.0 -0700 +++ linux-2.6.21-rc6-mm1-test/fs/cramfs/inode.c 2007-04-09

[PATCH 5/17] hfsplus: remove redundant read_mapping_page error check

2007-04-11 Thread Nate Diller
Now that read_mapping_page() does error checking internally, there is no need to check PageError here. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/hfsplus/bnode.c linux-2.6.21-rc6-mm1-test/fs/hfsplus/bnode.c --- linux-2.6.21-rc6-

[PATCH 14/17] reiserfs: convert reiserfs_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace reiserfs_get_page() and reiserfs_put_page() using the new read_kmap_page() and put_kmapped_page() calls and their locking variants. Also, propagate the gfp_mask() deadlock comment to callsites. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.

[PATCH 17/17] vxfs: convert vxfs_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace vxfs_get_page() with the new read_kmap_page(). Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/freevxfs/vxfs_extern.h linux-2.6.21-rc5-mm4-test/fs/freevxfs/vxfs_extern.h --- linux-2.6.21-rc5-mm4/fs/freevxfs/vxfs_extern.h 2007

[PATCH 15/17] sysv: convert dir_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace sysv dir_get_page() with the new read_kmap_page(). Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/sysv/dir.c linux-2.6.21-rc5-mm4-test/fs/sysv/dir.c --- linux-2.6.21-rc5-mm4/fs/sysv/dir.c 2007-04-05 17:14:25.0 -0700 +++

[PATCH 16/17] ufs: convert ufs_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/ufs/balloc.c linux-2.6.21-rc5-mm4-test/fs/ufs/balloc.c --- linux-2.6.21-rc5-mm4/fs/ufs/balloc.c2007-04-05 17:13:29.0 -0700 +++ linux-2.6.21-rc5-mm4-test/fs/ufs/balloc.c 2007-04-06

[PATCH 13/17] reiser4: remove redundant read_mapping_page error checks

2007-04-11 Thread Nate Diller
read_mapping_page() is now fully synchronous, so there's no need wait for the page lock or check for I/O errors. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/reiser4/plugin/file/tail_conversion.c linux-2.6.21-rc6-mm1-test/fs/reiser4/

[PATCH 12/17] partition: remove redundant read_mapping_page error checks

2007-04-11 Thread Nate Diller
Remove unneeded PageError checking in read_dev_sector(), and clean up the code a bit. Can anyone point out why it's OK to use page_address() here on a page which has not been kmapped? If it's not OK, then a good number of callers need to be fixed. Signed-off-by: Nate Diller <[EMAIL PROTEC

[PATCH 9/17] minix: convert dir_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace minix dir_get_page() and dir_put_page() using the new read_kmap_page() and put_kmapped_page()/put_locked_page() calls. Also, use __read_kmap_page() instead of re-taking the page_lock. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc5-

[PATCH 10/17] mtd: convert page_read to read_kmap_page

2007-04-11 Thread Nate Diller
Replace page_read() with read_kmap_page()/__read_kmap_page(). This probably fixes behaviour on highmem systems, since page_address() was being used without kmap(). Also eliminate the need to re-take the page lock during writes to the page. Signed-off-by: Nate Diller <[EMAIL PROTEC

[PATCH 4/17] ext2: convert ext2_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace ext2_get_page() and ext2_put_page() using the new read_kmap_page() and put_kmapped_page() calls. Also, change the ext2_check_page() call to return the page's error status, and update the call sites accordingly. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X do

[PATCH 8/17] jfs: use locking read_mapping_page

2007-04-11 Thread Nate Diller
Use the new locking variant of read_mapping_page to avoid doing extra work. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/jfs/jfs_metapage.c linux-2.6.21-rc6-mm1-test/fs/jfs/jfs_metapage.c --- linux-2.6.21-rc6-mm1/fs/jfs/jfs_metapage.c

[PATCH 2/17] fs: introduce new read_cache_page interface

2007-04-11 Thread Nate Diller
as needing to keep the page locked. These changes collectively eliminate a substantial amount of private fs logic in favor of generic code. It also simplifies filemap.c significantly, by assuming that callers want synchronous behavior, which is true for all callers anyway except one. Signed-off-by: Nate

[PATCH 3/17] afs: convert afs_dir_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace afs_dir_get_page() and afs_dir_put_page() using the new read_kmap_page() and put_kmapped_page() calls, and eliminate unnecessary PageError checks. Also, change the afs_dir_check_page() call to return the page's error status, and update the call site accordingly. Signed-off-by: Nate

[PATCH 0/17] fs: cleanup single page synchronous read interface

2007-04-11 Thread Nate Diller
checker functions that return an error if the page is corrupted or has some other error. This simplifies the logic since the checker function is not part of any helper function anymore. Compile tested on x86_64. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- drivers/mtd/d

Re: [PATCH 1/13] fs: convert core functions to zero_user_page

2007-04-11 Thread Nate Diller
On 4/10/07, Andrew Morton <[EMAIL PROTECTED]> wrote: On Tue, 10 Apr 2007 20:36:00 -0700 Nate Diller <[EMAIL PROTECTED]> wrote: > It's very common for file systems to need to zero part or all of a page, the > simplist way is just to use kmap_atomic() and memset(). There's ac

Re: [PATCH 1/13] fs: convert core functions to zero_user_page

2007-04-11 Thread Nate Diller
On 4/10/07, Andrew Morton [EMAIL PROTECTED] wrote: On Tue, 10 Apr 2007 20:36:00 -0700 Nate Diller [EMAIL PROTECTED] wrote: It's very common for file systems to need to zero part or all of a page, the simplist way is just to use kmap_atomic() and memset(). There's actually a library function

[PATCH 0/17] fs: cleanup single page synchronous read interface

2007-04-11 Thread Nate Diller
checker functions that return an error if the page is corrupted or has some other error. This simplifies the logic since the checker function is not part of any helper function anymore. Compile tested on x86_64. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- drivers/mtd/devices/block2mtd.c

[PATCH 2/17] fs: introduce new read_cache_page interface

2007-04-11 Thread Nate Diller
as needing to keep the page locked. These changes collectively eliminate a substantial amount of private fs logic in favor of generic code. It also simplifies filemap.c significantly, by assuming that callers want synchronous behavior, which is true for all callers anyway except one. Signed-off-by: Nate

[PATCH 3/17] afs: convert afs_dir_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace afs_dir_get_page() and afs_dir_put_page() using the new read_kmap_page() and put_kmapped_page() calls, and eliminate unnecessary PageError checks. Also, change the afs_dir_check_page() call to return the page's error status, and update the call site accordingly. Signed-off-by: Nate

[PATCH 4/17] ext2: convert ext2_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace ext2_get_page() and ext2_put_page() using the new read_kmap_page() and put_kmapped_page() calls. Also, change the ext2_check_page() call to return the page's error status, and update the call sites accordingly. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff

[PATCH 8/17] jfs: use locking read_mapping_page

2007-04-11 Thread Nate Diller
Use the new locking variant of read_mapping_page to avoid doing extra work. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/jfs/jfs_metapage.c linux-2.6.21-rc6-mm1-test/fs/jfs/jfs_metapage.c --- linux-2.6.21-rc6-mm1/fs/jfs/jfs_metapage.c 2007-04

[PATCH 9/17] minix: convert dir_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace minix dir_get_page() and dir_put_page() using the new read_kmap_page() and put_kmapped_page()/put_locked_page() calls. Also, use __read_kmap_page() instead of re-taking the page_lock. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/minix

[PATCH 10/17] mtd: convert page_read to read_kmap_page

2007-04-11 Thread Nate Diller
Replace page_read() with read_kmap_page()/__read_kmap_page(). This probably fixes behaviour on highmem systems, since page_address() was being used without kmap(). Also eliminate the need to re-take the page lock during writes to the page. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff

[PATCH 13/17] reiser4: remove redundant read_mapping_page error checks

2007-04-11 Thread Nate Diller
read_mapping_page() is now fully synchronous, so there's no need wait for the page lock or check for I/O errors. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/reiser4/plugin/file/tail_conversion.c linux-2.6.21-rc6-mm1-test/fs/reiser4/plugin

[PATCH 12/17] partition: remove redundant read_mapping_page error checks

2007-04-11 Thread Nate Diller
Remove unneeded PageError checking in read_dev_sector(), and clean up the code a bit. Can anyone point out why it's OK to use page_address() here on a page which has not been kmapped? If it's not OK, then a good number of callers need to be fixed. Signed-off-by: Nate Diller [EMAIL PROTECTED

[PATCH 15/17] sysv: convert dir_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace sysv dir_get_page() with the new read_kmap_page(). Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/sysv/dir.c linux-2.6.21-rc5-mm4-test/fs/sysv/dir.c --- linux-2.6.21-rc5-mm4/fs/sysv/dir.c 2007-04-05 17:14:25.0 -0700 +++ linux

[PATCH 16/17] ufs: convert ufs_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/ufs/balloc.c linux-2.6.21-rc5-mm4-test/fs/ufs/balloc.c --- linux-2.6.21-rc5-mm4/fs/ufs/balloc.c2007-04-05 17:13:29.0 -0700 +++ linux-2.6.21-rc5-mm4-test/fs/ufs/balloc.c 2007-04-06 12:46

[PATCH 17/17] vxfs: convert vxfs_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace vxfs_get_page() with the new read_kmap_page(). Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/freevxfs/vxfs_extern.h linux-2.6.21-rc5-mm4-test/fs/freevxfs/vxfs_extern.h --- linux-2.6.21-rc5-mm4/fs/freevxfs/vxfs_extern.h 2007-04-05

[PATCH 1/17] cramfs: use read_mapping_page

2007-04-11 Thread Nate Diller
-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/cramfs/inode.c linux-2.6.21-rc6-mm1-test/fs/cramfs/inode.c --- linux-2.6.21-rc6-mm1/fs/cramfs/inode.c 2007-04-09 17:24:03.0 -0700 +++ linux-2.6.21-rc6-mm1-test/fs/cramfs/inode.c 2007-04-09 21:37

[PATCH 5/17] hfsplus: remove redundant read_mapping_page error check

2007-04-11 Thread Nate Diller
Now that read_mapping_page() does error checking internally, there is no need to check PageError here. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/hfsplus/bnode.c linux-2.6.21-rc6-mm1-test/fs/hfsplus/bnode.c --- linux-2.6.21-rc6-mm1/fs

[PATCH 14/17] reiserfs: convert reiserfs_get_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace reiserfs_get_page() and reiserfs_put_page() using the new read_kmap_page() and put_kmapped_page() calls and their locking variants. Also, propagate the gfp_mask() deadlock comment to callsites. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4

[PATCH 11/17] ntfs: convert ntfs_map_page to read_kmap_page

2007-04-11 Thread Nate Diller
Replace ntfs_map_page() and ntfs_unmap_page() using the new read_kmap_page() and put_kmapped_page() calls, and their locking variants, and remove unneeded PageError checking. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc5-mm4/fs/ntfs/aops.h linux

[PATCH 6/17] hfs: remove redundant read_mapping_page error check

2007-04-11 Thread Nate Diller
Now that read_mapping_page() does error checking internally, there is no need to check PageError here. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/hfs/bnode.c linux-2.6.21-rc6-mm1-test/fs/hfs/bnode.c --- linux-2.6.21-rc6-mm1/fs/hfs/bnode.c

[PATCH 7/17] jffs2: convert jffs2_gc_fetch_page to read_cache_page

2007-04-11 Thread Nate Diller
Replace jffs2_gc_fetch_page() and jffs2_gc_release_page() using the read_cache_page() and put_kmapped_page() calls, and update the call site accordingly. Explicit calls to kmap()/kunmap() make the code more clear. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux

[PATCH 8/13] ntfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ntfs/aops.c linux-2.6.21-rc6-mm1-test/fs/ntfs/aops.c --- linux-2.6.21-rc6-mm1/fs/ntfs/aops.c 2007-04-09 10:41:47.0 -0700 +++ linux-

[PATCH 2/13] affs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/affs/file.c linux-2.6.21-rc6-mm1-test/fs/affs/file.c --- linux-2.6.21-rc6-mm1/fs/affs/file.c 2007-04-09 17:23:48.0 -0700 +++ linux-

[PATCH 5/13] ext4: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ext4/inode.c linux-2.6.21-rc6-mm1-test/fs/ext4/inode.c --- linux-2.6.21-rc6-mm1/fs/ext4/inode.c2007-04-10 17:15:04.0

[PATCH 4/13] ext3: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ext3/inode.c linux-2.6.21-rc6-mm1-test/fs/ext3/inode.c --- linux-2.6.21-rc6-mm1/fs/ext3/inode.c2007-04-09 17:24:03.0

[PATCH 6/13] gfs2: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/gfs2/bmap.c linux-2.6.21-rc6-mm1-test/fs/gfs2/bmap.c --- linux-2.6.21-rc6-mm1/fs/gfs2/bmap.c 2007-04-09 17:23:48.0 -0700 +++ linux-

[PATCH 11/13] reiserfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/reiserfs/file.c linux-2.6.21-rc6-mm1-test/fs/reiserfs/file.c --- linux-2.6.21-rc6-mm1/fs/reiserfs/file.c 2007-04-09 17:24:03.0

[PATCH 10/13] reiser4: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Also replace the (mostly) redundant zero_page() function. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/reiser4/plugin/file/cryptcompress.c linux-2.6.21-rc6-mm1-test/fs/reiser4/plugi

[PATCH 9/13] ocfs2: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ocfs2/aops.c linux-2.6.21-rc6-mm1-test/fs/ocfs2/aops.c --- linux-2.6.21-rc6-mm1/fs/ocfs2/aops.c2007-04-09 17:24:03.0

[PATCH 12/13] xfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of the newly deprecated memclear_highpage_flush(). Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/xfs/linux-2.6/xfs_lrw.c linux-2.6.21-rc6-mm1-test/fs/xfs/linux-2.6/xfs_lrw.c --- linux-2.6.21-rc6-mm1/fs/xfs

[PATCH 13/13] fs: deprecate memclear_highpage_flush

2007-04-10 Thread Nate Diller
Now that all the in-tree users are converted over to zero_user_page(), deprecate the old memclear_highpage_flush() call. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/include/linux/highmem.h linux-2.6.21-rc6-mm1-test/include/linux/hig

[PATCH 7/13] nfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of the newly deprecated memclear_highpage_flush(). Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/nfs/read.c linux-2.6.21-rc6-mm1-test/fs/nfs/read.c --- linux-2.6.21-rc6-mm1/fs/nfs/read.c 2007-04-09

[PATCH 3/13] ecryptfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ecryptfs/mmap.c linux-2.6.21-rc6-mm1-test/fs/ecryptfs/mmap.c --- linux-2.6.21-rc6-mm1/fs/ecryptfs/mmap.c 2007-04-09 17:24:03.0

[PATCH 1/13] fs: convert core functions to zero_user_page

2007-04-10 Thread Nate Diller
ones and the old memclear_highpage_flush() ones. Following this patch is a series of conversions for each file system individually, per AKPM, and finally a patch deprecating the old call. The diffstat below shows the entire patchset. Compile tested in x86_64. signed-off-by: Nate Diller <[EM

Re: [PATCH 1/2] fs: use memclear_highpage_flush to zero page data

2007-04-10 Thread Nate Diller
On 4/10/07, Anton Altaparmakov <[EMAIL PROTECTED]> wrote: On 10 Apr 2007, at 07:10, Andrew Morton wrote: > On Mon, 09 Apr 2007 21:31:37 -0700 Nate Diller > <[EMAIL PROTECTED]> wrote: >> It's very common for file systems to need to zero part or all of a >> page, the

Re: [PATCH 1/2] fs: use memclear_highpage_flush to zero page data

2007-04-10 Thread Nate Diller
On 4/10/07, Anton Altaparmakov [EMAIL PROTECTED] wrote: On 10 Apr 2007, at 07:10, Andrew Morton wrote: On Mon, 09 Apr 2007 21:31:37 -0700 Nate Diller [EMAIL PROTECTED] wrote: It's very common for file systems to need to zero part or all of a page, the simplist way is just to use kmap_atomic

[PATCH 1/13] fs: convert core functions to zero_user_page

2007-04-10 Thread Nate Diller
ones and the old memclear_highpage_flush() ones. Following this patch is a series of conversions for each file system individually, per AKPM, and finally a patch deprecating the old call. The diffstat below shows the entire patchset. Compile tested in x86_64. signed-off-by: Nate Diller [EMAIL

[PATCH 3/13] ecryptfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ecryptfs/mmap.c linux-2.6.21-rc6-mm1-test/fs/ecryptfs/mmap.c --- linux-2.6.21-rc6-mm1/fs/ecryptfs/mmap.c 2007-04-09 17:24:03.0 -0700

[PATCH 7/13] nfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of the newly deprecated memclear_highpage_flush(). Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/nfs/read.c linux-2.6.21-rc6-mm1-test/fs/nfs/read.c --- linux-2.6.21-rc6-mm1/fs/nfs/read.c 2007-04-09 17:23

[PATCH 10/13] reiser4: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Also replace the (mostly) redundant zero_page() function. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/reiser4/plugin/file/cryptcompress.c linux-2.6.21-rc6-mm1-test/fs/reiser4/plugin/file

[PATCH 9/13] ocfs2: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ocfs2/aops.c linux-2.6.21-rc6-mm1-test/fs/ocfs2/aops.c --- linux-2.6.21-rc6-mm1/fs/ocfs2/aops.c2007-04-09 17:24:03.0 -0700

[PATCH 12/13] xfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of the newly deprecated memclear_highpage_flush(). Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/xfs/linux-2.6/xfs_lrw.c linux-2.6.21-rc6-mm1-test/fs/xfs/linux-2.6/xfs_lrw.c --- linux-2.6.21-rc6-mm1/fs/xfs/linux

[PATCH 13/13] fs: deprecate memclear_highpage_flush

2007-04-10 Thread Nate Diller
Now that all the in-tree users are converted over to zero_user_page(), deprecate the old memclear_highpage_flush() call. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/include/linux/highmem.h linux-2.6.21-rc6-mm1-test/include/linux/highmem.h

[PATCH 4/13] ext3: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ext3/inode.c linux-2.6.21-rc6-mm1-test/fs/ext3/inode.c --- linux-2.6.21-rc6-mm1/fs/ext3/inode.c2007-04-09 17:24:03.0 -0700

[PATCH 6/13] gfs2: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/gfs2/bmap.c linux-2.6.21-rc6-mm1-test/fs/gfs2/bmap.c --- linux-2.6.21-rc6-mm1/fs/gfs2/bmap.c 2007-04-09 17:23:48.0 -0700 +++ linux-2.6.21

[PATCH 11/13] reiserfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/reiserfs/file.c linux-2.6.21-rc6-mm1-test/fs/reiserfs/file.c --- linux-2.6.21-rc6-mm1/fs/reiserfs/file.c 2007-04-09 17:24:03.0 -0700

[PATCH 8/13] ntfs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ntfs/aops.c linux-2.6.21-rc6-mm1-test/fs/ntfs/aops.c --- linux-2.6.21-rc6-mm1/fs/ntfs/aops.c 2007-04-09 10:41:47.0 -0700 +++ linux-2.6.21

[PATCH 2/13] affs: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/affs/file.c linux-2.6.21-rc6-mm1-test/fs/affs/file.c --- linux-2.6.21-rc6-mm1/fs/affs/file.c 2007-04-09 17:23:48.0 -0700 +++ linux-2.6.21-rc6

[PATCH 5/13] ext4: use zero_user_page

2007-04-10 Thread Nate Diller
Use zero_user_page() instead of open-coding it. Signed-off-by: Nate Diller [EMAIL PROTECTED] --- diff -urpN -X dontdiff linux-2.6.21-rc6-mm1/fs/ext4/inode.c linux-2.6.21-rc6-mm1-test/fs/ext4/inode.c --- linux-2.6.21-rc6-mm1/fs/ext4/inode.c2007-04-10 17:15:04.0 -0700

[PATCH 2/2] fs: use simple_prepare_write to zero page data

2007-04-09 Thread Nate Diller
on x86_64. signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- cifs/file.c |9 + ext4/writeback.c | 17 + reiser4/plugin/item/extent_file_ops.c | 13 +++-- 3 files changed, 5 insertions(+), 34 del

[PATCH 1/2] fs: use memclear_highpage_flush to zero page data

2007-04-09 Thread Nate Diller
of *how* it does the work rather than what the *purpose* is. So this patch renames the function to zero_page_data(), and calls it from the various places that currently open code it. Compile tested in x86_64. signed-off-by: Nate Diller <[EMAIL PROTECTED]> --- drivers/block/

Re: Reiser4. BEST FILESYSTEM EVER.

2007-04-09 Thread Nate Diller
On 08 Apr 2007 06:32:26 +0200, Christer Weinigel <[EMAIL PROTECTED]> wrote: [EMAIL PROTECTED] writes: > Lennart. Tell me again that these results from > > http://linuxhelp.150m.com/resources/fs-benchmarks.htm and > http://m.domaindlx.com/LinuxHelp/resources/fs-benchmarks.htm > > are not of

Re: Reiser4. BEST FILESYSTEM EVER.

2007-04-09 Thread Nate Diller
On 08 Apr 2007 06:32:26 +0200, Christer Weinigel [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] writes: Lennart. Tell me again that these results from http://linuxhelp.150m.com/resources/fs-benchmarks.htm and http://m.domaindlx.com/LinuxHelp/resources/fs-benchmarks.htm are not of interest to

[PATCH 1/2] fs: use memclear_highpage_flush to zero page data

2007-04-09 Thread Nate Diller
of *how* it does the work rather than what the *purpose* is. So this patch renames the function to zero_page_data(), and calls it from the various places that currently open code it. Compile tested in x86_64. signed-off-by: Nate Diller [EMAIL PROTECTED] --- drivers/block/loop.c

[PATCH 2/2] fs: use simple_prepare_write to zero page data

2007-04-09 Thread Nate Diller
on x86_64. signed-off-by: Nate Diller [EMAIL PROTECTED] --- cifs/file.c |9 + ext4/writeback.c | 17 + reiser4/plugin/item/extent_file_ops.c | 13 +++-- 3 files changed, 5 insertions(+), 34 deletions(-) --- diff

[BUG] reiser4: page lock recursion in reiser4_write_extent

2007-03-13 Thread Nate Diller
This little code snippet seems to have a page_lock recursion, in addition to overall looking particularly fragile to me. It seems to be handling the case where a page needs to be brought uptodate because a partial page write is being done. The page gets locked as many as 3 times, each checking

[BUG] reiser4: page lock recursion in reiser4_write_extent

2007-03-13 Thread Nate Diller
This little code snippet seems to have a page_lock recursion, in addition to overall looking particularly fragile to me. It seems to be handling the case where a page needs to be brought uptodate because a partial page write is being done. The page gets locked as many as 3 times, each checking

Re: [patch 1/3] fs: add an iovec iterator

2007-02-08 Thread Nate Diller
On 2/8/07, Nick Piggin <[EMAIL PROTECTED]> wrote: On Thu, Feb 08, 2007 at 07:49:53PM +, Christoph Hellwig wrote: > On Thu, Feb 08, 2007 at 02:07:24PM +0100, Nick Piggin wrote: > > Add an iterator data structure to operate over an iovec. Add usercopy > > operators needed by

Re: [patch 1/3] fs: add an iovec iterator

2007-02-08 Thread Nate Diller
On 2/8/07, Nick Piggin [EMAIL PROTECTED] wrote: On Thu, Feb 08, 2007 at 07:49:53PM +, Christoph Hellwig wrote: On Thu, Feb 08, 2007 at 02:07:24PM +0100, Nick Piggin wrote: Add an iterator data structure to operate over an iovec. Add usercopy operators needed by

Re: [RFC] Tracking mlocked pages and moving them off the LRU

2007-02-07 Thread Nate Diller
On 2/7/07, Christoph Lameter <[EMAIL PROTECTED]> wrote: On Tue, 6 Feb 2007, Nate Diller wrote: > > The dirty ratio with the ZVCS would be > > > > NR_DIRTY + NR_UNSTABLE_NFS > > / > > NR_FREE_PAGES + NR_INACTIVE + NR_ACTIVE + NR_MLOCK > >

Re: [RFC] Tracking mlocked pages and moving them off the LRU

2007-02-07 Thread Nate Diller
On 2/7/07, Christoph Lameter [EMAIL PROTECTED] wrote: On Tue, 6 Feb 2007, Nate Diller wrote: The dirty ratio with the ZVCS would be NR_DIRTY + NR_UNSTABLE_NFS / NR_FREE_PAGES + NR_INACTIVE + NR_ACTIVE + NR_MLOCK I don't understand why you want to account mlocked pages

Re: [RFC] Tracking mlocked pages and moving them off the LRU

2007-02-06 Thread Nate Diller
On 2/4/07, Christoph Lameter <[EMAIL PROTECTED]> wrote: On Sun, 4 Feb 2007, Arjan van de Ven wrote: > > > Exclusion or inclusion of NR_MLOCK number is straightforward for the dirty > > ratio calcuations. global_page_state(NR_MLOCK) f.e. would get us totals on > > mlocked pages per zone.

Re: [RFC] Tracking mlocked pages and moving them off the LRU

2007-02-06 Thread Nate Diller
On 2/4/07, Christoph Lameter [EMAIL PROTECTED] wrote: On Sun, 4 Feb 2007, Arjan van de Ven wrote: Exclusion or inclusion of NR_MLOCK number is straightforward for the dirty ratio calcuations. global_page_state(NR_MLOCK) f.e. would get us totals on mlocked pages per zone.

Re: [PATCH -mm 0/10][RFC] aio: make struct kiocb private

2007-01-17 Thread Nate Diller
On Wed, 17 Jan 2007, Benjamin LaHaise wrote: On Mon, Jan 15, 2007 at 08:25:15PM -0800, Nate Diller wrote: the right thing to do from a design perspective. Hopefully it enables a new architecture that can reduce context switches in I/O completion, and reduce overhead. That's the real motive

Re: [PATCH -mm 0/10][RFC] aio: make struct kiocb private

2007-01-17 Thread Nate Diller
On Wed, 17 Jan 2007, Benjamin LaHaise wrote: On Mon, Jan 15, 2007 at 08:25:15PM -0800, Nate Diller wrote: the right thing to do from a design perspective. Hopefully it enables a new architecture that can reduce context switches in I/O completion, and reduce overhead. That's the real motive

Re: [PATCH -mm 4/10][RFC] aio: convert aio_complete to file_endio_t

2007-01-16 Thread Nate Diller
On 1/15/07, David Brownell <[EMAIL PROTECTED]> wrote: On Monday 15 January 2007 5:54 pm, Nate Diller wrote: > --- a/drivers/usb/gadget/inode.c 2007-01-12 14:42:29.0 -0800 > +++ b/drivers/usb/gadget/inode.c 2007-01-12 14:25:34.0 -0800 > @@ -559,35 +559,3

Re: [PATCH -mm 9/10][RFC] aio: usb gadget remove aio file ops

2007-01-16 Thread Nate Diller
On 1/15/07, David Brownell <[EMAIL PROTECTED]> wrote: On Monday 15 January 2007 5:54 pm, Nate Diller wrote: > This removes the aio implementation from the usb gadget file system. NAK. I see a deep mis-understanding here. > Aside > from making very creative (!) use of the

Re: [PATCH -mm 9/10][RFC] aio: usb gadget remove aio file ops

2007-01-16 Thread Nate Diller
On 1/15/07, David Brownell [EMAIL PROTECTED] wrote: On Monday 15 January 2007 5:54 pm, Nate Diller wrote: This removes the aio implementation from the usb gadget file system. NAK. I see a deep mis-understanding here. Aside from making very creative (!) use of the aio retry path, it can't

Re: [PATCH -mm 4/10][RFC] aio: convert aio_complete to file_endio_t

2007-01-16 Thread Nate Diller
On 1/15/07, David Brownell [EMAIL PROTECTED] wrote: On Monday 15 January 2007 5:54 pm, Nate Diller wrote: --- a/drivers/usb/gadget/inode.c 2007-01-12 14:42:29.0 -0800 +++ b/drivers/usb/gadget/inode.c 2007-01-12 14:25:34.0 -0800 @@ -559,35 +559,32 @@ static int

Re: [PATCH -mm 3/10][RFC] aio: use iov_length instead of ki_left

2007-01-15 Thread Nate Diller
On 1/15/07, Christoph Hellwig <[EMAIL PROTECTED]> wrote: On Mon, Jan 15, 2007 at 05:54:50PM -0800, Nate Diller wrote: > Convert code using iocb->ki_left to use the more generic iov_length() call. No way. We need to reduce the numer of iovec traversals, not adding more of them. ok

Re: [PATCH -mm 0/10][RFC] aio: make struct kiocb private

2007-01-15 Thread Nate Diller
On 1/15/07, Christoph Hellwig <[EMAIL PROTECTED]> wrote: On Mon, Jan 15, 2007 at 05:54:50PM -0800, Nate Diller wrote: > This series is an attempt to generalize the async I/O paths to be > implementation agnostic. It completely eliminates knowledge of > the kiocb structure in t

  1   2   >