Skip to content

powerpc/8xx: Optimise MMU TLB handling and add support of 16k pages

Christophe Leroy linuxppc-dev lkml 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest21 patches 5 repliesIn review
  2. v321 patches 13 repliesSuperseded
  3. v219 patches 5 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v120 patches1 replySuperseded

Changes in v4 from the cover letter

- Resubmitting patch 3 and 7 after new comments from Joachim and feedback from Scott. Has impact on patch 5, 14, 19 and 21.
- Fixed patch 20 that didn't apply

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/21powerpc/8xx: Declare SPRG2 as a SCRATCH registerarch/powerpc/include/asm/reg.h arch/powerpc/kernel/head_8xx.S+7 -60 replies
2/21powerpc/8xx: Use SCRATCH0 and SCRATCH1 also for TLB handlersarch/powerpc/kernel/head_8xx.S+36 -680 replies
3/21powerpc/8xx: exception InstructionAccess does not exist on MPC8xxarch/powerpc/kernel/head_8xx.S+7 -80 replies
4/21powerpc/8xx: Remove loading of r10 at end of FixupDARarch/powerpc/kernel/head_8xx.S+3 -40 replies
5/21powerpc/8xx: Fix comment about DIRTY updatearch/powerpc/kernel/head_8xx.S+2 -60 replies
6/21powerpc/8xx: No need to save r10 and r3 when not calling FixupDARarch/powerpc/kernel/head_8xx.S+13 -140 replies
7/21powerpc/8xx: DataAccess exception not generated by MPC8xxarch/powerpc/kernel/head_8xx.S+10 -110 replies
8/21powerpc/8xx: No need to restore registers and save them again.arch/powerpc/kernel/head_8xx.S+2 -20 replies
9/21powerpc/8xx: Optimize verification in FixupDARarch/powerpc/kernel/head_8xx.S+2 -40 replies
10/21powerpc/8xx: Duplicate two insns instead of branchingarch/powerpc/kernel/head_8xx.S+4 -20 replies
11/21powerpc/8xx: Use M_TW instead of M_TWBarch/powerpc/kernel/head_8xx.S+26 -220 replies
12/21powerpc/8xx: Don't use MD_TWC for walkarch/powerpc/kernel/head_8xx.S+12 -160 replies
13/21powerpc/8xx: Use PAGE size related constsarch/powerpc/kernel/head_8xx.S+18 -120 replies
14/21powerpc/8xx: Const for TLB RPN forced valuearch/powerpc/kernel/head_8xx.S+13 -60 replies
15/21powerpc/8xx: Implement 16k pagesarch/powerpc/Kconfig arch/powerpc/include/asm/mmu-8xx.h arch/powerpc/kernel/head_8xx.S+7 -10 replies
16/21powerpc/8xx: Better readibility of ERRATA CPU6 handlingarch/powerpc/kernel/head_8xx.S+16 -130 replies
17/21powerpc/8xx: set PTE bit 22 off TLBmissarch/powerpc/include/asm/pgtable-ppc32.h arch/powerpc/include/asm/pte-8xx.h arch/powerpc/kernel/head_8xx.S+27 -105 replies
18/21powerpc/8xx: _PMD_PRESENT already set in level 1 entriesarch/powerpc/kernel/head_8xx.S+0 -20 replies
19/21powerpc/8xx: Don't restore regs to save them again.arch/powerpc/kernel/head_8xx.S+5 -30 replies
20/21powerpc/8xx: Use DAR to save r3 for CPU6 ERRATAarch/powerpc/kernel/head_8xx.S+15 -180 replies
21/21powerpc/8xx: Invalidate non present TLB as early as possiblearch/powerpc/kernel/head_8xx.S arch/powerpc/mm/fault.c+10 -120 replies

Reviews trailers per patch

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

PatchChristophe Leroy
SeriesT-b
1/21
2/21
3/21
4/21
5/21
6/21
7/21
8/21
9/21
10/21
11/21
12/21
13/21
14/21
15/21
16/21
17/21
18/21
19/21
20/21
21/21

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

Read the v4 thread

Cover letter [PATCH v4 00/21] powerpc/8xx: Optimise MMU TLB handling and add support of 16k pages

This patchset:
1) provides several MMU TLB handling optimisation on MPC8xx.
2) adds support of 16k pages on MPC8xx.
All changes have been successfully tested on a custom board equipped with MPC885

---
Changes in v2:
- Patch number 10 removed, it was implementing a 16 bit alignment of the PGDIR. It is not worth potentially wasting up to 64k of memory just for removing one instruction (ori).
- Preserve r11 while calculating the level 2 address, therefore no more need to save r11 into CR.

Changes in v3:
- Few fixes following review from Joachim Tjernlund
- Removed the major hack which was saving resisters in memory for CPU6 errata
- Invalidating non present TLB entries earlier (in head_8xx instead of fault.c)

Changes in v4:
- Resubmitting patch 3 and 7 after new comments from Joachim and feedback from Scott. Has impact on patch 5, 14, 19 and 21.
- Fixed patch 20 that didn't apply

 arch/powerpc/Kconfig                     |   2 +-
 arch/powerpc/include/asm/mmu-8xx.h       |   2 +
 arch/powerpc/include/asm/pgtable-ppc32.h |  20 ++
 arch/powerpc/include/asm/pte-8xx.h       |   7 +-
 arch/powerpc/include/asm/reg.h           |   3 +-
 arch/powerpc/kernel/head_8xx.S           | 366 ++++++++++++-------------
 arch/powerpc/mm/fault.c                  |   7 -
 7 files changed, 201 insertions(+), 206 deletions(-)