Lines Matching refs:mapping
77 int afs_write_begin(struct file *file, struct address_space *mapping, in afs_write_begin() argument
98 page = grab_cache_page_write_begin(mapping, index, flags); in afs_write_begin()
181 int afs_write_end(struct file *file, struct address_space *mapping, in afs_write_end() argument
232 static void afs_kill_pages(struct address_space *mapping, in afs_kill_pages() argument
235 struct afs_vnode *vnode = AFS_FS_I(mapping->host); in afs_kill_pages()
250 pv.nr = find_get_pages_contig(mapping, first, count, pv.pages); in afs_kill_pages()
261 generic_error_remove_page(mapping, page); in afs_kill_pages()
275 struct address_space *mapping, in afs_redirty_pages() argument
278 struct afs_vnode *vnode = AFS_FS_I(mapping->host); in afs_redirty_pages()
293 pv.nr = find_get_pages_contig(mapping, first, count, pv.pages); in afs_redirty_pages()
354 static int afs_store_data(struct address_space *mapping, in afs_store_data() argument
358 struct afs_vnode *vnode = AFS_FS_I(mapping->host); in afs_store_data()
410 afs_fs_store_data(&fc, mapping, first, last, offset, to, scb); in afs_store_data()
451 static int afs_write_back_from_locked_page(struct address_space *mapping, in afs_write_back_from_locked_page() argument
456 struct afs_vnode *vnode = AFS_FS_I(mapping->host); in afs_write_back_from_locked_page()
496 n = find_get_pages_contig(mapping, start, ARRAY_SIZE(pages), pages); in afs_write_back_from_locked_page()
563 ret = afs_store_data(mapping, first, last, offset, to); in afs_write_back_from_locked_page()
578 afs_redirty_pages(wbc, mapping, first, last); in afs_write_back_from_locked_page()
579 mapping_set_error(mapping, ret); in afs_write_back_from_locked_page()
584 afs_redirty_pages(wbc, mapping, first, last); in afs_write_back_from_locked_page()
585 mapping_set_error(mapping, -ENOSPC); in afs_write_back_from_locked_page()
596 afs_kill_pages(mapping, first, last); in afs_write_back_from_locked_page()
597 mapping_set_error(mapping, ret); in afs_write_back_from_locked_page()
615 ret = afs_write_back_from_locked_page(page->mapping, wbc, page, in afs_writepage()
631 static int afs_writepages_region(struct address_space *mapping, in afs_writepages_region() argument
641 n = find_get_pages_range_tag(mapping, &index, end, in afs_writepages_region()
661 if (page->mapping != mapping || !PageDirty(page)) { in afs_writepages_region()
677 ret = afs_write_back_from_locked_page(mapping, wbc, page, end); in afs_writepages_region()
697 int afs_writepages(struct address_space *mapping, in afs_writepages() argument
706 start = mapping->writeback_index; in afs_writepages()
708 ret = afs_writepages_region(mapping, wbc, start, end, &next); in afs_writepages()
710 ret = afs_writepages_region(mapping, wbc, 0, start, in afs_writepages()
712 mapping->writeback_index = next; in afs_writepages()
715 ret = afs_writepages_region(mapping, wbc, 0, end, &next); in afs_writepages()
717 mapping->writeback_index = next; in afs_writepages()
721 ret = afs_writepages_region(mapping, wbc, start, end, &next); in afs_writepages()
852 struct address_space *mapping = page->mapping; in afs_launder_page() local
853 struct afs_vnode *vnode = AFS_FS_I(mapping->host); in afs_launder_page()
871 ret = afs_store_data(mapping, page->index, page->index, t, f); in afs_launder_page()