Each architecturee must provide a definition of mk_pte() today. They must also provide pfn_pte(). Usually the former is defined in terms of the latter, but not on some architectures. I was trying to decide what we should do for creating PTEs in a folio world, and it struck me that we should have architectures only provide pfn_pte() and then I don't need to trouble the arch maintainers with whatever MM API I come up with. The architectures not on the cc list I considered trivial. The architectures who have named patches are less trivial, and I did my best to write a decent commit message explaining why I did what I did to each architecture. I have some followup patches which remove folio->page conversions, but if this set of patches are wrong on any architecture, then they'll also be wrong, so I'm not sending them right now. Matthew Wilcox (Oracle) (5): mm: Introduce a common definition of mk_pte() x86: Remove custom definition of mk_pte() um: Remove custom definition of mk_pte() s390: Remove custom definition of mk_pte() mm: Make mk_pte() definition unconditional arch/alpha/include/asm/pgtable.h | 7 ------- arch/arc/include/asm/pgtable-levels.h | 1 - arch/arm/include/asm/pgtable.h | 1 - arch/arm64/include/asm/pgtable.h | 6 ------ arch/csky/include/asm/pgtable.h | 5 ----- arch/hexagon/include/asm/pgtable.h | 3 --- arch/loongarch/include/asm/pgtable.h | 6 ------ arch/m68k/include/asm/mcf_pgtable.h | 6 ------ arch/m68k/include/asm/motorola_pgtable.h | 6 ------ arch/m68k/include/asm/sun3_pgtable.h | 6 ------ arch/microblaze/include/asm/pgtable.h | 8 -------- arch/mips/include/asm/pgtable.h | 6 ------ arch/nios2/include/asm/pgtable.h | 6 ------ arch/openrisc/include/asm/pgtable.h | 2 -- arch/parisc/include/asm/pgtable.h | 2 -- arch/powerpc/include/asm/pgtable.h | 1 - arch/riscv/include/asm/pgtable.h | 2 -- arch/s390/include/asm/pgtable.h | 10 ---------- arch/sh/include/asm/pgtable_32.h | 8 -------- arch/sparc/include/asm/pgtable_32.h | 9 ++------- arch/sparc/include/asm/pgtable_64.h | 1 - arch/um/include/asm/pgtable-2level.h | 1 - arch/um/include/asm/pgtable-3level.h | 9 --------- arch/um/include/asm/pgtable.h | 17 ++++++++++------- arch/x86/include/asm/pgtable.h | 19 +++---------------- arch/xtensa/include/asm/pgtable.h | 1 - include/linux/pgtable.h | 5 +++++ 27 files changed, 20 insertions(+), 134 deletions(-) -- 2.43.0