linux-next: manual merge of the akpm-current tree with the powerpc tree

Stephen Rothwell
2020-06-03T08:50:51Z

[-- Attachment #1: Type: text/plain, Size: 1860 bytes --]

Hi all,

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

arch/powerpc/mm/ptdump/ptdump.c

between commit:

6b789a26d7da ("powerpc/ptdump: Handle hugepd at PGD level")

from the powerpc tree and patch:

"powerpc: add support for folded p4d page tables"

from the akpm-current tree.

Thanks to Michael Ellerman for an example resolution.

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 arch/powerpc/mm/ptdump/ptdump.c
index 5fc880e30175,507cb9793b26..000000000000
--- a/arch/powerpc/mm/ptdump/ptdump.c
+++ b/arch/powerpc/mm/ptdump/ptdump.c
@@@ -333,13 -304,13 +333,15 @@@ static void walk_pagetables(struct pg_s
* the hash pagetable.
*/
for (i = pgd_index(addr); i < PTRS_PER_PGD; i++, pgd++, addr += PGDIR_SIZE) {
- if (pgd_none(*pgd) || pgd_is_leaf(*pgd))
- note_page(st, addr, 1, pgd_val(*pgd), PGDIR_SIZE);
- else if (is_hugepd(__hugepd(pgd_val(*pgd))))
- walk_hugepd(st, (hugepd_t *)pgd, addr, PGDIR_SHIFT, 1);
+ p4d_t *p4d = p4d_offset(pgd, 0);
+
- if (!p4d_none(*p4d) && !p4d_is_leaf(*p4d))
++ if (p4d_none(*p4d) || p4d_is_leaf(*p4d))
++ note_page(st, addr, 1, p4d_val(*p4d), PGDIR_SIZE);
++ else if (is_hugepd(__hugepd(p4d_val(*p4d))))
++ walk_hugepd(st, (hugepd_t *)p4d, addr, PGDIR_SHIFT, 1);
+ else
- /* pgd exists */
- walk_pud(st, pgd, addr);
+ /* p4d exists */
+ walk_pud(st, p4d, addr);
- else
- note_page(st, addr, 1, p4d_val(*p4d));
}
}