lkml.org 
[lkml]   [2018]   [Dec]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectlinux-next: manual merge of the akpm-current tree with the btrfs-kdave tree
Hi all,

Today's linux-next merge of the akpm-current tree got a conflict in:

fs/btrfs/extent_io.c

between commit:

e42c38c80535 ("btrfs: Refactor main loop in extent_readpages")

from the btrfs-kdave tree and commit:

"fs: don't open code lru_to_page()"

from the akpm-current tree.

I fixed it up (see below) and can carry the fix as necessary. This
is now fixed as far as linux-next is concerned, but any non trivial
conflicts should be mentioned to your upstream maintainer when your tree
is submitted for merging. You may also want to consider cooperating
with the maintainer of the conflicting tree to minimise any particularly
complex conflicts.

--
Cheers,
Stephen Rothwell

diff --cc fs/btrfs/extent_io.c
index 5104714212b4,3707c95a6598..000000000000
--- a/fs/btrfs/extent_io.c
+++ b/fs/btrfs/extent_io.c
@@@ -4103,24 -4103,28 +4103,24 @@@ int extent_readpages(struct address_spa
int nr = 0;
u64 prev_em_start = (u64)-1;

- for (page_idx = 0; page_idx < nr_pages; page_idx++) {
- page = lru_to_page(pages);
+ while (!list_empty(pages)) {
+ for (nr = 0; nr < BTRFS_PAGES_BATCH && !list_empty(pages);) {
- struct page *page = list_entry(pages->prev, struct page, lru);
++ struct page *page = lru_to_page(pages);

- prefetchw(&page->flags);
- list_del(&page->lru);
- if (add_to_page_cache_lru(page, mapping,
- page->index,
- readahead_gfp_mask(mapping))) {
- put_page(page);
- continue;
+ prefetchw(&page->flags);
+ list_del(&page->lru);
+ if (add_to_page_cache_lru(page, mapping, page->index,
+ readahead_gfp_mask(mapping))) {
+ put_page(page);
+ continue;
+ }
+
+ pagepool[nr++] = page;
}

- pagepool[nr++] = page;
- if (nr < ARRAY_SIZE(pagepool))
- continue;
__extent_readpages(tree, pagepool, nr, &em_cached, &bio,
- &bio_flags, &prev_em_start);
- nr = 0;
+ &bio_flags, &prev_em_start);
}
- if (nr)
- __extent_readpages(tree, pagepool, nr, &em_cached, &bio,
- &bio_flags, &prev_em_start);

if (em_cached)
free_extent_map(em_cached);
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2018-12-06 08:30    [W:0.018 / U:0.816 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site