lkml.org 
[lkml]   [2007]   [Sep]   [10]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
DateMon, 10 Sep 2007 18:49:09 +0900
FromKAMEZAWA Hiroyuki <>
Subject[PATCH] add page->mapping handling interface [5/35] changes in AFS
Use page->mapping interface in AFS

Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>

---
 fs/afs/file.c |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
Index: test-2.6.23-rc4-mm1/fs/afs/file.c
===================================================================
--- test-2.6.23-rc4-mm1.orig/fs/afs/file.c
+++ test-2.6.23-rc4-mm1/fs/afs/file.c
@@ -145,7 +145,7 @@ static int afs_readpage(struct file *fil
 	off_t offset;
 	int ret;
 
-	inode = page->mapping->host;
+	inode = page_inode(page);
 
 	ASSERT(file != NULL);
 	key = file->private_data;
@@ -253,8 +253,7 @@ static void afs_invalidatepage(struct pa
 
 			ret = 0;
 			if (!PageWriteback(page))
-				ret = page->mapping->a_ops->releasepage(page,
-									0);
+				ret = page_mapping_cache(page)->a_ops->releasepage(page, 0);
 			/* possibly should BUG_ON(!ret); - neilb */
 		}
 	}
@@ -277,7 +276,7 @@ static int afs_launder_page(struct page 
  */
 static int afs_releasepage(struct page *page, gfp_t gfp_flags)
 {
-	struct afs_vnode *vnode = AFS_FS_I(page->mapping->host);
+	struct afs_vnode *vnode = AFS_FS_I(page_inode(page));
 	struct afs_writeback *wb;
 
 	_enter("{{%x:%u}[%lu],%lx},%x",
-
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: 2007-09-10 11:49    [from the cache]
©2003-2008