diff options
author | David Howells <dhowells@redhat.com> | 2006-08-29 14:05:54 -0400 |
---|---|---|
committer | Jens Axboe <axboe@nelson.home.kernel.dk> | 2006-09-30 14:31:19 -0400 |
commit | cf9a2ae8d49948f861b56e5333530e491a9da190 (patch) | |
tree | 21f0b0d781b3e60cc60464d39b6d95681201b37e /include | |
parent | 4090959aee403817ff386415f9bc602c1a0882ef (diff) |
[PATCH] BLOCK: Move functions out of buffer code [try #6]
Move some functions out of the buffering code that aren't strictly buffering
specific. This is a precursor to being able to disable the block layer.
(*) Moved some stuff out of fs/buffer.c:
(*) The file sync and general sync stuff moved to fs/sync.c.
(*) The superblock sync stuff moved to fs/super.c.
(*) do_invalidatepage() moved to mm/truncate.c.
(*) try_to_release_page() moved to mm/filemap.c.
(*) Moved some related declarations between header files:
(*) declarations for do_invalidatepage() and try_to_release_page() moved
to linux/mm.h.
(*) __set_page_dirty_buffers() moved to linux/buffer_head.h.
Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/buffer_head.h | 3 | ||||
-rw-r--r-- | include/linux/fs.h | 1 | ||||
-rw-r--r-- | include/linux/mm.h | 4 |
3 files changed, 5 insertions, 3 deletions
diff --git a/include/linux/buffer_head.h b/include/linux/buffer_head.h index 737e407d0cd1..64b508e35d2a 100644 --- a/include/linux/buffer_head.h +++ b/include/linux/buffer_head.h | |||
@@ -190,9 +190,7 @@ extern int buffer_heads_over_limit; | |||
190 | * Generic address_space_operations implementations for buffer_head-backed | 190 | * Generic address_space_operations implementations for buffer_head-backed |
191 | * address_spaces. | 191 | * address_spaces. |
192 | */ | 192 | */ |
193 | int try_to_release_page(struct page * page, gfp_t gfp_mask); | ||
194 | void block_invalidatepage(struct page *page, unsigned long offset); | 193 | void block_invalidatepage(struct page *page, unsigned long offset); |
195 | void do_invalidatepage(struct page *page, unsigned long offset); | ||
196 | int block_write_full_page(struct page *page, get_block_t *get_block, | 194 | int block_write_full_page(struct page *page, get_block_t *get_block, |
197 | struct writeback_control *wbc); | 195 | struct writeback_control *wbc); |
198 | int block_read_full_page(struct page*, get_block_t*); | 196 | int block_read_full_page(struct page*, get_block_t*); |
@@ -302,4 +300,5 @@ static inline void lock_buffer(struct buffer_head *bh) | |||
302 | __lock_buffer(bh); | 300 | __lock_buffer(bh); |
303 | } | 301 | } |
304 | 302 | ||
303 | extern int __set_page_dirty_buffers(struct page *page); | ||
305 | #endif /* _LINUX_BUFFER_HEAD_H */ | 304 | #endif /* _LINUX_BUFFER_HEAD_H */ |
diff --git a/include/linux/fs.h b/include/linux/fs.h index d68c37af4dfb..1728142ec4b6 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -1546,6 +1546,7 @@ extern int __filemap_fdatawrite_range(struct address_space *mapping, | |||
1546 | extern long do_fsync(struct file *file, int datasync); | 1546 | extern long do_fsync(struct file *file, int datasync); |
1547 | extern void sync_supers(void); | 1547 | extern void sync_supers(void); |
1548 | extern void sync_filesystems(int wait); | 1548 | extern void sync_filesystems(int wait); |
1549 | extern void __fsync_super(struct super_block *sb); | ||
1549 | extern void emergency_sync(void); | 1550 | extern void emergency_sync(void); |
1550 | extern void emergency_remount(void); | 1551 | extern void emergency_remount(void); |
1551 | extern int do_remount_sb(struct super_block *sb, int flags, | 1552 | extern int do_remount_sb(struct super_block *sb, int flags, |
diff --git a/include/linux/mm.h b/include/linux/mm.h index 7b703b6d4358..4edf1934e5ca 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h | |||
@@ -743,7 +743,9 @@ int get_user_pages(struct task_struct *tsk, struct mm_struct *mm, unsigned long | |||
743 | int len, int write, int force, struct page **pages, struct vm_area_struct **vmas); | 743 | int len, int write, int force, struct page **pages, struct vm_area_struct **vmas); |
744 | void print_bad_pte(struct vm_area_struct *, pte_t, unsigned long); | 744 | void print_bad_pte(struct vm_area_struct *, pte_t, unsigned long); |
745 | 745 | ||
746 | int __set_page_dirty_buffers(struct page *page); | 746 | extern int try_to_release_page(struct page * page, gfp_t gfp_mask); |
747 | extern void do_invalidatepage(struct page *page, unsigned long offset); | ||
748 | |||
747 | int __set_page_dirty_nobuffers(struct page *page); | 749 | int __set_page_dirty_nobuffers(struct page *page); |
748 | int redirty_page_for_writepage(struct writeback_control *wbc, | 750 | int redirty_page_for_writepage(struct writeback_control *wbc, |
749 | struct page *page); | 751 | struct page *page); |