Skip to content

Add support for eXclusive Page Frame Ownership

Tycho Andersen kernel-hardening linux-arm-kernel linux-mm lkml xen-devel 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v6 Latest11 patches 66 repliesIn review
  2. v510 patches 42 repliesSuperseded
  3. v4 RFC3 patches 2 repliesSuperseded

Patches in v6 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/11mm: add MAP_HUGETLB support to vm_mmapinclude/linux/mm.h mm/mmap.c mm/util.c+35 -181 reply
2/11x86: always set IF before oopsing from page faultarch/x86/mm/fault.c+6 -00 replies
3/11mm, x86: Add support for eXclusive Page Frame Ownership (XPFO)Documentation/admin-guide/kernel-parameters.txt arch/x86/Kconfig arch/x86/include/asm/pgtable.h +10 more+449 -2139 replies
4/11swiotlb: Map the buffer if it was unmapped by XPFOinclude/linux/xpfo.h lib/swiotlb.c mm/xpfo.c+21 -13 replies
5/11arm64/mm: Add support for XPFOarch/arm64/Kconfig arch/arm64/mm/Makefile arch/arm64/mm/xpfo.c+61 -09 replies
6/11xpfo: add primitives for mapping underlying memoryinclude/linux/xpfo.h mm/xpfo.c+52 -00 replies
7/11arm64/mm, xpfo: temporarily map dcache regionsarch/arm64/mm/flush.c+7 -02 replies
8/11arm64/mm: Add support for XPFO to swiotlbarch/arm64/include/asm/cacheflush.h arch/arm64/mm/dma-mapping.c arch/arm64/mm/xpfo.c +1 more+47 -160 replies
9/11arm64/mm: disable section/contiguous mappings if XPFO is enabledarch/arm64/mm/mmu.c include/linux/xpfo.h mm/xpfo.c+11 -11 reply
10/11mm: add a user_virt_to_phys symbolarch/arm64/mm/xpfo.c arch/x86/mm/xpfo.c include/linux/xpfo.h+113 -05 replies
11/11lkdtm: Add test for XPFOdrivers/misc/Makefile drivers/misc/lkdtm.h drivers/misc/lkdtm_core.c +1 more+203 -01 reply

Reviews trailers per patch

None of the 11 patches has a Reviewed-by or Acked-by.

PatchMarco Benatto
1/11T-b
2/11
3/11
4/11
5/11
6/11
7/11
8/11
9/11
10/11T-b
11/11T-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v6 thread

Cover letter [PATCH v6 00/11] Add support for eXclusive Page Frame Ownership

Hi all,

Here is v6 of the XPFO set; see v5 discussion here:
https://lkml.org/lkml/2017/8/9/803

Changelogs are in the individual patch notes, but the highlights are:
* add primitives for ensuring memory areas are mapped (although these are quite ugly, using stack allocation; I'm open to better suggestions)
* instead of not flushing caches, re-map pages using the above
* TLB flushing is much more correct (i.e. we're always flushing everything everywhere). I suspect we may be able to back this off in some cases, but I'm still trying to collect performance numbers to prove this is worth doing.

I have no TODOs left for this set myself, other than fixing whatever review feedback people have. Thoughts and testing welcome!

Cheers,

Tycho

Juerg Haefliger (6):
mm, x86: Add support for eXclusive Page Frame Ownership (XPFO)
swiotlb: Map the buffer if it was unmapped by XPFO arm64/mm: Add support for XPFO
arm64/mm, xpfo: temporarily map dcache regions arm64/mm: Add support for XPFO to swiotlb
lkdtm: Add test for XPFO

Tycho Andersen (5):
mm: add MAP_HUGETLB support to vm_mmap
x86: always set IF before oopsing from page fault
xpfo: add primitives for mapping underlying memory arm64/mm: disable section/contiguous mappings if XPFO is enabled
mm: add a user_virt_to_phys symbol

 Documentation/admin-guide/kernel-parameters.txt |   2 +
 arch/arm64/Kconfig                              |   1 +
 arch/arm64/include/asm/cacheflush.h             |  11 +
 arch/arm64/mm/Makefile                          |   2 +
 arch/arm64/mm/dma-mapping.c                     |  32 +--
 arch/arm64/mm/flush.c                           |   7 +
 arch/arm64/mm/mmu.c                             |   2 +-
 arch/arm64/mm/xpfo.c                            | 127 +++++++++++
 arch/x86/Kconfig                                |   1 +
 arch/x86/include/asm/pgtable.h                  |  25 +++
 arch/x86/mm/Makefile                            |   1 +
 arch/x86/mm/fault.c                             |   6 +
 arch/x86/mm/pageattr.c                          |  22 +-
 arch/x86/mm/xpfo.c                              | 171 +++++++++++++++
 drivers/misc/Makefile                           |   1 +
 drivers/misc/lkdtm.h                            |   5 +
 drivers/misc/lkdtm_core.c                       |   3 +
 drivers/misc/lkdtm_xpfo.c                       | 194 +++++++++++++++++
 include/linux/highmem.h                         |  15 +-
 include/linux/mm.h                              |   2 +
 include/linux/xpfo.h                            |  79 +++++++
 lib/swiotlb.c                                   |   3 +-
 mm/Makefile                                     |   1 +
 mm/mmap.c                                       |  19 +-
 mm/page_alloc.c                                 |   2 +
 mm/page_ext.c                                   |   4 +
 mm/util.c                                       |  32 +++
 mm/xpfo.c                                       | 273 ++++++++++++++++++++++++
 security/Kconfig                                |  19 ++
 29 files changed, 1005 insertions(+), 57 deletions(-)
 create mode 100644 arch/arm64/mm/xpfo.c
 create mode 100644 arch/x86/mm/xpfo.c
 create mode 100644 drivers/misc/lkdtm_xpfo.c
 create mode 100644 include/linux/xpfo.h
 create mode 100644 mm/xpfo.c
Signature · 1 line
2.11.0