Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 767fcf33 authored by Jan Kara's avatar Jan Kara Committed by Jaegeuk Kim
Browse files

mm: remove nr_pages argument from pagevec_lookup_{,range}_tag()

All users of pagevec_lookup() and pagevec_lookup_range() now pass
PAGEVEC_SIZE as a desired number of pages.  Just drop the argument.

Link: http://lkml.kernel.org/r/20171009151359.31984-15-jack@suse.cz


Signed-off-by: default avatarJan Kara <jack@suse.cz>
Reviewed-by: default avatarDaniel Jordan <daniel.m.jordan@oracle.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 3962b4cd
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -3836,8 +3836,8 @@ retry:
	if (wbc->sync_mode == WB_SYNC_ALL)
		tag_pages_for_writeback(mapping, index, end);
	while (!done && !nr_to_write_done && (index <= end) &&
	       (nr_pages = pagevec_lookup_range_tag(&pvec, mapping, &index, end,
			tag, PAGEVEC_SIZE))) {
			(nr_pages = pagevec_lookup_range_tag(&pvec, mapping,
						&index, end, tag))) {
		unsigned i;

		scanned = 1;
@@ -3976,7 +3976,7 @@ retry:
		tag_pages_for_writeback(mapping, index, end);
	while (!done && !nr_to_write_done && (index <= end) &&
	       (nr_pages = pagevec_lookup_range_tag(&pvec, mapping, &index, end,
			tag, PAGEVEC_SIZE))) {
			tag))) {
		unsigned i;

		scanned = 1;
+1 −2
Original line number Diff line number Diff line
@@ -768,8 +768,7 @@ retry:
get_more_pages:
		first = -1;
		pvec_pages = pagevec_lookup_range_tag(&pvec, mapping, &index,
						end, PAGECACHE_TAG_DIRTY,
						max_pages - locked_pages);
						end, PAGECACHE_TAG_DIRTY);
		dout("pagevec_lookup_range_tag got %d\n", pvec_pages);
		if (!pvec_pages && !locked_pages)
			break;
+1 −1
Original line number Diff line number Diff line
@@ -2214,7 +2214,7 @@ static int mpage_prepare_extent_to_map(struct mpage_da_data *mpd)
	mpd->next_page = index;
	while (index <= end) {
		nr_pages = pagevec_lookup_range_tag(&pvec, mapping, &index, end,
				tag, PAGEVEC_SIZE);
				tag);
		if (nr_pages == 0)
			goto out;

+1 −1
Original line number Diff line number Diff line
@@ -326,7 +326,7 @@ long sync_meta_pages(struct f2fs_sb_info *sbi, enum page_type type,
	blk_start_plug(&plug);

	while ((nr_pages = pagevec_lookup_tag(&pvec, mapping, &index,
				PAGECACHE_TAG_DIRTY, PAGEVEC_SIZE))) {
				PAGECACHE_TAG_DIRTY))) {
		int i;

		for (i = 0; i < nr_pages; i++) {
+1 −1
Original line number Diff line number Diff line
@@ -1954,7 +1954,7 @@ retry:
		int i;

		nr_pages = pagevec_lookup_range_tag(&pvec, mapping, &index, end,
				tag, PAGEVEC_SIZE);
				tag);
		if (nr_pages == 0)
			break;

Loading