Commit 5ce7852cdf07ab903fb1c72d0915ac492c6e07c7
Committed by
Linus Torvalds
1 parent
dd81eca83c
Exists in
master
and in
4 other branches
[PATCH] mm/filemap.c: make two functions static
With Nick Piggin <npiggin@suse.de> Give some things static scope. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Nick Piggin <npiggin@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Showing 4 changed files with 11 additions and 12 deletions Side-by-side Diff
include/linux/fs.h
... | ... | @@ -1509,8 +1509,6 @@ |
1509 | 1509 | loff_t *, read_descriptor_t *, read_actor_t); |
1510 | 1510 | extern void |
1511 | 1511 | file_ra_state_init(struct file_ra_state *ra, struct address_space *mapping); |
1512 | -extern ssize_t generic_file_direct_IO(int rw, struct kiocb *iocb, | |
1513 | - const struct iovec *iov, loff_t offset, unsigned long nr_segs); | |
1514 | 1512 | extern ssize_t generic_file_readv(struct file *filp, const struct iovec *iov, |
1515 | 1513 | unsigned long nr_segs, loff_t *ppos); |
1516 | 1514 | ssize_t generic_file_writev(struct file *filp, const struct iovec *iov, |
include/linux/writeback.h
... | ... | @@ -109,8 +109,6 @@ |
109 | 109 | int do_writepages(struct address_space *mapping, struct writeback_control *wbc); |
110 | 110 | int sync_page_range(struct inode *inode, struct address_space *mapping, |
111 | 111 | loff_t pos, size_t count); |
112 | -int sync_page_range_nolock(struct inode *inode, struct address_space | |
113 | - *mapping, loff_t pos, size_t count); | |
114 | 112 | |
115 | 113 | /* pdflush.c */ |
116 | 114 | extern int nr_pdflush_threads; /* Global so it can be exported to sysctl |
mm/filemap.c
... | ... | @@ -37,6 +37,10 @@ |
37 | 37 | #include <asm/uaccess.h> |
38 | 38 | #include <asm/mman.h> |
39 | 39 | |
40 | +static ssize_t | |
41 | +generic_file_direct_IO(int rw, struct kiocb *iocb, const struct iovec *iov, | |
42 | + loff_t offset, unsigned long nr_segs); | |
43 | + | |
40 | 44 | /* |
41 | 45 | * Shared mappings implemented 30.11.1994. It's not fully working yet, |
42 | 46 | * though. |
... | ... | @@ -301,8 +305,9 @@ |
301 | 305 | * as it forces O_SYNC writers to different parts of the same file |
302 | 306 | * to be serialised right until io completion. |
303 | 307 | */ |
304 | -int sync_page_range_nolock(struct inode *inode, struct address_space *mapping, | |
305 | - loff_t pos, size_t count) | |
308 | +static int sync_page_range_nolock(struct inode *inode, | |
309 | + struct address_space *mapping, | |
310 | + loff_t pos, size_t count) | |
306 | 311 | { |
307 | 312 | pgoff_t start = pos >> PAGE_CACHE_SHIFT; |
308 | 313 | pgoff_t end = (pos + count - 1) >> PAGE_CACHE_SHIFT; |
... | ... | @@ -317,7 +322,6 @@ |
317 | 322 | ret = wait_on_page_writeback_range(mapping, start, end); |
318 | 323 | return ret; |
319 | 324 | } |
320 | -EXPORT_SYMBOL(sync_page_range_nolock); | |
321 | 325 | |
322 | 326 | /** |
323 | 327 | * filemap_fdatawait - walk the list of under-writeback pages of the given |
... | ... | @@ -2008,7 +2012,7 @@ |
2008 | 2012 | } |
2009 | 2013 | EXPORT_SYMBOL(generic_file_buffered_write); |
2010 | 2014 | |
2011 | -ssize_t | |
2015 | +static ssize_t | |
2012 | 2016 | __generic_file_aio_write_nolock(struct kiocb *iocb, const struct iovec *iov, |
2013 | 2017 | unsigned long nr_segs, loff_t *ppos) |
2014 | 2018 | { |
... | ... | @@ -2108,7 +2112,7 @@ |
2108 | 2112 | return ret; |
2109 | 2113 | } |
2110 | 2114 | |
2111 | -ssize_t | |
2115 | +static ssize_t | |
2112 | 2116 | __generic_file_write_nolock(struct file *file, const struct iovec *iov, |
2113 | 2117 | unsigned long nr_segs, loff_t *ppos) |
2114 | 2118 | { |
... | ... | @@ -2229,7 +2233,7 @@ |
2229 | 2233 | * Called under i_sem for writes to S_ISREG files. Returns -EIO if something |
2230 | 2234 | * went wrong during pagecache shootdown. |
2231 | 2235 | */ |
2232 | -ssize_t | |
2236 | +static ssize_t | |
2233 | 2237 | generic_file_direct_IO(int rw, struct kiocb *iocb, const struct iovec *iov, |
2234 | 2238 | loff_t offset, unsigned long nr_segs) |
2235 | 2239 | { |
... | ... | @@ -2264,5 +2268,4 @@ |
2264 | 2268 | } |
2265 | 2269 | return retval; |
2266 | 2270 | } |
2267 | -EXPORT_SYMBOL_GPL(generic_file_direct_IO); |
mm/memory.c