lkml.org 
[lkml]   [2005]   [Jan]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[PATCH 7/13] FAT: kill unnecessary kmap()
From
Date

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
---
fs/fat/inode.c | 22 +++++++---------------
1 files changed, 7 insertions(+), 15 deletions(-)
diff -puN fs/fat/inode.c~fat_kill-unnecessary_kmap fs/fat/inode.c
--- linux-2.6.10/fs/fat/inode.c~fat_kill-unnecessary_kmap 2005-01-08 09:08:10.000000000 +0900
+++ linux-2.6.10-hirofumi/fs/fat/inode.c 2005-01-08 09:08:10.000000000 +0900
@@ -1137,30 +1137,22 @@ static int
fat_prepare_write(struct file *file, struct page *page,
unsigned from, unsigned to)
{
- kmap(page);
return cont_prepare_write(page,from,to,fat_get_block,
&MSDOS_I(page->mapping->host)->mmu_private);
}

-static int
-fat_commit_write(struct file *file, struct page *page,
- unsigned from, unsigned to)
-{
- kunmap(page);
- return generic_commit_write(file, page, from, to);
-}
-
static sector_t _fat_bmap(struct address_space *mapping, sector_t block)
{
return generic_block_bmap(mapping,block,fat_get_block);
}
+
static struct address_space_operations fat_aops = {
- .readpage = fat_readpage,
- .writepage = fat_writepage,
- .sync_page = block_sync_page,
- .prepare_write = fat_prepare_write,
- .commit_write = fat_commit_write,
- .bmap = _fat_bmap
+ .readpage = fat_readpage,
+ .writepage = fat_writepage,
+ .sync_page = block_sync_page,
+ .prepare_write = fat_prepare_write,
+ .commit_write = generic_commit_write,
+ .bmap = _fat_bmap
};

/* doesn't deal with root inode */
_
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 14:09    [from the cache]
©2003-2011 Jasper Spaans