Skip to content

PTE fixes for ARM LPAE

Steve Capper linux-arm-kernel 5 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v6 Latest2 patches 0 repliesNew
  2. v52 patches 0 repliesSuperseded
  3. v42 patches 0 repliesSuperseded
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v3 posting 2/20 of 2 patches0 repliesSuperseded
v3 posting 1/22 patches0 repliesSuperseded

Patches in v6 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2arm: mm: Introduce {pte, pmd}_isset and {pte, pmd}_iscleararch/arm/include/asm/pgtable-3level.h arch/arm/include/asm/pgtable.h+19 -111 reply
2/2arm: mm: Modify pte_write and pmd_write logic for LPAEarch/arm/include/asm/pgtable-3level-hwdef.h arch/arm/include/asm/pgtable-3level.h arch/arm/mm/dump.c +1 more+35 -221 reply
2/2arm: mm: Modify pte_write and pmd_write logic for LPAE+0 -00 replies

Reviews trailers per patch

1 of 3 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchWill Deacon
SeriesR-b
1/2R-b
2/2
2/2

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 0/2] PTE fixes for ARM LPAE

This series fixes a couple of problems that I encountered on ARM with LPAE.
1) Some pte accessors can have their results cancelled out by a downcast. This is addressed by the first patch.

2) It is impossible to distinguish between clean writeable ptes and read only ptes. This is addressed by the second patch.

Notable changes from V5->V6:
o) Renamed PMD_SECT_RDONLY to PMD_SECT_AP2 to make the distinction between software and hardware bits clearer.
o) pmd_trans_huge tidied up to use !pmd_table(.)

Notable changes in this series from V4->V5:
o) Rather than switch to L_PTE_WRITE semantics, we move L_PTE_RDONLY to a software bit. This allows for a much smaller patch set that does not affect the 2-level code.

Notable changes in this series from V3->V4:
o) Rebased to take into account the BE LPAE fix in 3.16-rc1.
o) THP logic added as this was missing.

This series has been tested with libhugetlbfs unit tests, ltp mm tests and a custom THP test to test what happens when PROT_NONE THPs are faulted. I have tested on an Arndale board with LPAE and classic MMU (with classic MMU, only ltp mm tests were run). Testing was performed against 3.16-rc3.

Any comments/feedback would be appreciated.

Cheers,
--
Steve

Steve Capper (2):
arm: mm: Introduce {pte,pmd}_isset and {pte,pmd}_isclear
arm: mm: Modify pte_write and pmd_write logic for LPAE

 arch/arm/include/asm/pgtable-3level-hwdef.h |  3 +-
 arch/arm/include/asm/pgtable-3level.h       | 49 ++++++++++++++++++-----------
 arch/arm/include/asm/pgtable.h              | 18 ++++++-----
 arch/arm/mm/dump.c                          |  4 +--
 arch/arm/mm/proc-v7-3level.S                |  9 ++++--
 5 files changed, 52 insertions(+), 31 deletions(-)
Signature · 1 line
1.9.3