summaryrefslogtreecommitdiff
path: root/fs/buffer.c
diff options
context:
space:
mode:
authorAndrew Morton <akpm@zip.com.au>2002-04-29 23:52:59 -0700
committerLinus Torvalds <torvalds@home.transmeta.com>2002-04-29 23:52:59 -0700
commit59c39e8ebb56664ebf0f479f36a94e95bcda1ce6 (patch)
treeef3c907b928e12256f12202ce51bd3289b9f2dc1 /fs/buffer.c
parentcc6a392acffb77d009dfadee591d5eaea78ae7f7 (diff)
[PATCH] cleanup write_one_page
Remove writeout_one_page(), waitfor_one_page() and the now-unused generic_buffer_fdatasync(). Add new write_one_page(struct page *page, int wait) which is exported to modules. Update callers to use that. It's only used for IS_SYNC operations.
Diffstat (limited to 'fs/buffer.c')
-rw-r--r--fs/buffer.c43
1 files changed, 0 insertions, 43 deletions
diff --git a/fs/buffer.c b/fs/buffer.c
index fd4393201bd0..aa9dba564280 100644
--- a/fs/buffer.c
+++ b/fs/buffer.c
@@ -1891,49 +1891,6 @@ int block_write_full_page(struct page *page, get_block_t *get_block)
return __block_write_full_page(inode, page, get_block);
}
-/*
- * Commence writeout of all the buffers against a page. The
- * page must be locked. Returns zero on success or a negative
- * errno.
- */
-int writeout_one_page(struct page *page)
-{
- struct buffer_head * const head = page_buffers(page);
- struct buffer_head *arr[MAX_BUF_PER_PAGE];
- struct buffer_head *bh;
- int nr = 0;
- BUG_ON(!PageLocked(page));
- bh = head;
- do {
- if (!buffer_locked(bh) && buffer_dirty(bh) &&
- buffer_mapped(bh) && buffer_uptodate(bh))
- arr[nr++] = bh;
- } while ((bh = bh->b_this_page) != head);
- if (nr)
- ll_rw_block(WRITE, nr, arr);
- return 0;
-}
-EXPORT_SYMBOL(writeout_one_page);
-
-/*
- * Wait for completion of I/O of all buffers against a page. The page
- * must be locked. Returns zero on success or a negative errno.
- */
-int waitfor_one_page(struct page *page)
-{
- int error = 0;
- struct buffer_head *bh, *head = page_buffers(page);
-
- bh = head;
- do {
- wait_on_buffer(bh);
- if (buffer_req(bh) && !buffer_uptodate(bh))
- error = -EIO;
- } while ((bh = bh->b_this_page) != head);
- return error;
-}
-EXPORT_SYMBOL(waitfor_one_page);
-
sector_t generic_block_bmap(struct address_space *mapping, sector_t block,
get_block_t *get_block)
{