linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v6 0/7] Support page table check
@ 2023-02-14  1:59 Rohan McLure
  2023-02-14  1:59 ` [PATCH v6 1/7] powerpc: mm: Separate set_pte, set_pte_at for internal, external use Rohan McLure
                   ` (6 more replies)
  0 siblings, 7 replies; 13+ messages in thread
From: Rohan McLure @ 2023-02-14  1:59 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: Rohan McLure

Support the page table check sanitiser on all PowerPC platforms. This
sanitiser works by serialising assignments, reassignments and clears of
page table entries at each level in order to ensure that anonymous
mappings have at most one writable consumer, and likewise that
file-backed mappings are not simultaneously also anonymous mappings.

In order to support this infrastructure, a number of stubs must be
defined for all powerpc platforms. Additionally, seperate set_pte_at
and set_pte, to allow for internal, uninstrumented mappings.

v6:
 * Support huge pages and p{m,u}d accounting.
 * Remove instrumentation from set_pte from kernel internal pages.
 * 64s: Implement pmdp_collapse_flush in terms of __pmdp_collapse_flush
   as access to the mm_struct * is required.

v5: 
Link:

Rohan McLure (7):
  powerpc: mm: Separate set_pte, set_pte_at for internal, external use
  powerpc/64s: mm: Introduce __pmdp_collapse_flush with mm_struct
    argument
  powerpc: mm: Replace p{u,m,4}d_is_leaf with p{u,m,4}_leaf
  powerpc: mm: Implement p{m,u,4}d_leaf on all platforms
  powerpc: mm: Add common pud_pfn stub for all platforms
  powerpc: mm: Add p{te,md,ud}_user_accessible_page helpers
  powerpc: mm: Support page table check

 arch/powerpc/Kconfig                         |  1 +
 arch/powerpc/include/asm/book3s/32/pgtable.h | 17 +++-
 arch/powerpc/include/asm/book3s/64/pgtable.h | 88 +++++++++++++-------
 arch/powerpc/include/asm/book3s/pgtable.h    |  4 +-
 arch/powerpc/include/asm/nohash/32/pgtable.h | 12 ++-
 arch/powerpc/include/asm/nohash/64/pgtable.h | 24 +++++-
 arch/powerpc/include/asm/nohash/pgtable.h    | 10 ++-
 arch/powerpc/include/asm/pgtable.h           | 61 +++++++++-----
 arch/powerpc/kvm/book3s_64_mmu_radix.c       | 12 +--
 arch/powerpc/mm/book3s64/hash_pgtable.c      |  2 +-
 arch/powerpc/mm/book3s64/pgtable.c           | 16 ++--
 arch/powerpc/mm/book3s64/radix_pgtable.c     | 24 +++---
 arch/powerpc/mm/nohash/book3e_pgtable.c      |  2 +-
 arch/powerpc/mm/pgtable.c                    | 10 +--
 arch/powerpc/mm/pgtable_32.c                 |  2 +-
 arch/powerpc/mm/pgtable_64.c                 |  6 +-
 arch/powerpc/xmon/xmon.c                     |  6 +-
 17 files changed, 204 insertions(+), 93 deletions(-)

-- 
2.37.2


^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2023-02-15  0:41 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-14  1:59 [PATCH v6 0/7] Support page table check Rohan McLure
2023-02-14  1:59 ` [PATCH v6 1/7] powerpc: mm: Separate set_pte, set_pte_at for internal, external use Rohan McLure
2023-02-14  5:59   ` Christophe Leroy
2023-02-14  1:59 ` [PATCH v6 2/7] powerpc/64s: mm: Introduce __pmdp_collapse_flush with mm_struct argument Rohan McLure
2023-02-14  6:02   ` Christophe Leroy
2023-02-15  0:17     ` Rohan McLure
2023-02-15  0:40       ` Rohan McLure
2023-02-14  1:59 ` [PATCH v6 3/7] powerpc: mm: Replace p{u,m,4}d_is_leaf with p{u,m,4}_leaf Rohan McLure
2023-02-14  1:59 ` [PATCH v6 4/7] powerpc: mm: Implement p{m,u,4}d_leaf on all platforms Rohan McLure
2023-02-14  1:59 ` [PATCH v6 5/7] powerpc: mm: Add common pud_pfn stub for " Rohan McLure
2023-02-14  1:59 ` [PATCH v6 6/7] powerpc: mm: Add p{te,md,ud}_user_accessible_page helpers Rohan McLure
2023-02-14  1:59 ` [PATCH v6 7/7] powerpc: mm: Support page table check Rohan McLure
2023-02-14  6:14   ` Christophe Leroy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).