Skip to content
  • Peter Zijlstra's avatar
    c5eecbb5
    powerpc/8xx: Implement pXX_leaf_size() support · c5eecbb5
    Peter Zijlstra authored
    
    
    Christophe Leroy wrote:
    
    > I can help with powerpc 8xx. It is a 32 bits powerpc. The PGD has 1024
    > entries, that means each entry maps 4M.
    >
    > Page sizes are 4k, 16k, 512k and 8M.
    >
    > For the 8M pages we use hugepd with a single entry. The two related PGD
    > entries point to the same hugepd.
    >
    > For the other sizes, they are in standard page tables. 16k pages appear
    > 4 times in the page table. 512k entries appear 128 times in the page
    > table.
    >
    > When the PGD entry has _PMD_PAGE_8M bits, the PMD entry points to a
    > hugepd with holds the single 8M entry.
    >
    > In the PTE, we have two bits: _PAGE_SPS and _PAGE_HUGE
    >
    > _PAGE_HUGE means it is a 512k page
    > _PAGE_SPS means it is not a 4k page
    >
    > The kernel can by build either with 4k pages as standard page size, or
    > 16k pages. It doesn't change the page table layout though.
    
    Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
    Link: https://lkml.kernel.org/r/20201126121121.364451610@infradead.org
    c5eecbb5
    powerpc/8xx: Implement pXX_leaf_size() support
    Peter Zijlstra authored
    
    
    Christophe Leroy wrote:
    
    > I can help with powerpc 8xx. It is a 32 bits powerpc. The PGD has 1024
    > entries, that means each entry maps 4M.
    >
    > Page sizes are 4k, 16k, 512k and 8M.
    >
    > For the 8M pages we use hugepd with a single entry. The two related PGD
    > entries point to the same hugepd.
    >
    > For the other sizes, they are in standard page tables. 16k pages appear
    > 4 times in the page table. 512k entries appear 128 times in the page
    > table.
    >
    > When the PGD entry has _PMD_PAGE_8M bits, the PMD entry points to a
    > hugepd with holds the single 8M entry.
    >
    > In the PTE, we have two bits: _PAGE_SPS and _PAGE_HUGE
    >
    > _PAGE_HUGE means it is a 512k page
    > _PAGE_SPS means it is not a 4k page
    >
    > The kernel can by build either with 4k pages as standard page size, or
    > 16k pages. It doesn't change the page table layout though.
    
    Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
    Link: https://lkml.kernel.org/r/20201126121121.364451610@infradead.org
Loading