aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2014-02-02 21:16:54 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2014-04-01 23:19:19 -0400
commitc186afb4dbd0050a537b96c7fbee2dba3b57fc38 (patch)
tree4e9f43b3ba20ffbecf8440250a17e1507d53ec5f
parentfbb32750a62df75d1ffea547f3908b21c5496d9f (diff)
switch ->is_partially_uptodate() to saner arguments
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r--Documentation/filesystems/Locking2
-rw-r--r--Documentation/filesystems/vfs.txt2
-rw-r--r--fs/buffer.c6
-rw-r--r--include/linux/buffer_head.h4
-rw-r--r--include/linux/fs.h2
-rw-r--r--mm/filemap.c2
6 files changed, 9 insertions, 9 deletions
diff --git a/Documentation/filesystems/Locking b/Documentation/filesystems/Locking
index 5b0c083d7c0e..bb2534bc0b03 100644
--- a/Documentation/filesystems/Locking
+++ b/Documentation/filesystems/Locking
@@ -198,7 +198,7 @@ prototypes:
198 unsigned long *); 198 unsigned long *);
199 int (*migratepage)(struct address_space *, struct page *, struct page *); 199 int (*migratepage)(struct address_space *, struct page *, struct page *);
200 int (*launder_page)(struct page *); 200 int (*launder_page)(struct page *);
201 int (*is_partially_uptodate)(struct page *, read_descriptor_t *, unsigned long); 201 int (*is_partially_uptodate)(struct page *, unsigned long, unsigned long);
202 int (*error_remove_page)(struct address_space *, struct page *); 202 int (*error_remove_page)(struct address_space *, struct page *);
203 int (*swap_activate)(struct file *); 203 int (*swap_activate)(struct file *);
204 int (*swap_deactivate)(struct file *); 204 int (*swap_deactivate)(struct file *);
diff --git a/Documentation/filesystems/vfs.txt b/Documentation/filesystems/vfs.txt
index c53784c119c8..419e7348c481 100644
--- a/Documentation/filesystems/vfs.txt
+++ b/Documentation/filesystems/vfs.txt
@@ -580,7 +580,7 @@ struct address_space_operations {
580 /* migrate the contents of a page to the specified target */ 580 /* migrate the contents of a page to the specified target */
581 int (*migratepage) (struct page *, struct page *); 581 int (*migratepage) (struct page *, struct page *);
582 int (*launder_page) (struct page *); 582 int (*launder_page) (struct page *);
583 int (*is_partially_uptodate) (struct page *, read_descriptor_t *, 583 int (*is_partially_uptodate) (struct page *, unsigned long,
584 unsigned long); 584 unsigned long);
585 void (*is_dirty_writeback) (struct page *, bool *, bool *); 585 void (*is_dirty_writeback) (struct page *, bool *, bool *);
586 int (*error_remove_page) (struct mapping *mapping, struct page *page); 586 int (*error_remove_page) (struct mapping *mapping, struct page *page);
diff --git a/fs/buffer.c b/fs/buffer.c
index 27265a8b43c1..027ae3bdfbbd 100644
--- a/fs/buffer.c
+++ b/fs/buffer.c
@@ -2114,8 +2114,8 @@ EXPORT_SYMBOL(generic_write_end);
2114 * Returns true if all buffers which correspond to a file portion 2114 * Returns true if all buffers which correspond to a file portion
2115 * we want to read are uptodate. 2115 * we want to read are uptodate.
2116 */ 2116 */
2117int block_is_partially_uptodate(struct page *page, read_descriptor_t *desc, 2117int block_is_partially_uptodate(struct page *page, unsigned long from,
2118 unsigned long from) 2118 unsigned long count)
2119{ 2119{
2120 unsigned block_start, block_end, blocksize; 2120 unsigned block_start, block_end, blocksize;
2121 unsigned to; 2121 unsigned to;
@@ -2127,7 +2127,7 @@ int block_is_partially_uptodate(struct page *page, read_descriptor_t *desc,
2127 2127
2128 head = page_buffers(page); 2128 head = page_buffers(page);
2129 blocksize = head->b_size; 2129 blocksize = head->b_size;
2130 to = min_t(unsigned, PAGE_CACHE_SIZE - from, desc->count); 2130 to = min_t(unsigned, PAGE_CACHE_SIZE - from, count);
2131 to = from + to; 2131 to = from + to;
2132 if (from < blocksize && to > PAGE_CACHE_SIZE - blocksize) 2132 if (from < blocksize && to > PAGE_CACHE_SIZE - blocksize)
2133 return 0; 2133 return 0;
diff --git a/include/linux/buffer_head.h b/include/linux/buffer_head.h
index d77797a52b7b..c40302f909ce 100644
--- a/include/linux/buffer_head.h
+++ b/include/linux/buffer_head.h
@@ -210,8 +210,8 @@ int block_write_full_page(struct page *page, get_block_t *get_block,
210int block_write_full_page_endio(struct page *page, get_block_t *get_block, 210int block_write_full_page_endio(struct page *page, get_block_t *get_block,
211 struct writeback_control *wbc, bh_end_io_t *handler); 211 struct writeback_control *wbc, bh_end_io_t *handler);
212int block_read_full_page(struct page*, get_block_t*); 212int block_read_full_page(struct page*, get_block_t*);
213int block_is_partially_uptodate(struct page *page, read_descriptor_t *desc, 213int block_is_partially_uptodate(struct page *page, unsigned long from,
214 unsigned long from); 214 unsigned long count);
215int block_write_begin(struct address_space *mapping, loff_t pos, unsigned len, 215int block_write_begin(struct address_space *mapping, loff_t pos, unsigned len,
216 unsigned flags, struct page **pagep, get_block_t *get_block); 216 unsigned flags, struct page **pagep, get_block_t *get_block);
217int __block_write_begin(struct page *page, loff_t pos, unsigned len, 217int __block_write_begin(struct page *page, loff_t pos, unsigned len,
diff --git a/include/linux/fs.h b/include/linux/fs.h
index db181b542db1..ddfff2ecef0b 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -385,7 +385,7 @@ struct address_space_operations {
385 int (*migratepage) (struct address_space *, 385 int (*migratepage) (struct address_space *,
386 struct page *, struct page *, enum migrate_mode); 386 struct page *, struct page *, enum migrate_mode);
387 int (*launder_page) (struct page *); 387 int (*launder_page) (struct page *);
388 int (*is_partially_uptodate) (struct page *, read_descriptor_t *, 388 int (*is_partially_uptodate) (struct page *, unsigned long,
389 unsigned long); 389 unsigned long);
390 void (*is_dirty_writeback) (struct page *, bool *, bool *); 390 void (*is_dirty_writeback) (struct page *, bool *, bool *);
391 int (*error_remove_page)(struct address_space *, struct page *); 391 int (*error_remove_page)(struct address_space *, struct page *);
diff --git a/mm/filemap.c b/mm/filemap.c
index 7a13f6ac5421..46e98019af6c 100644
--- a/mm/filemap.c
+++ b/mm/filemap.c
@@ -1148,7 +1148,7 @@ find_page:
1148 if (!page->mapping) 1148 if (!page->mapping)
1149 goto page_not_up_to_date_locked; 1149 goto page_not_up_to_date_locked;
1150 if (!mapping->a_ops->is_partially_uptodate(page, 1150 if (!mapping->a_ops->is_partially_uptodate(page,
1151 desc, offset)) 1151 offset, desc->count))
1152 goto page_not_up_to_date_locked; 1152 goto page_not_up_to_date_locked;
1153 unlock_page(page); 1153 unlock_page(page);
1154 } 1154 }