Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 370835
b: refs/heads/master
c: 1b29187
h: refs/heads/master
i:
  370833: 0d70d14
  370831: 8a4d3a9
v: v3
  • Loading branch information
Kumar Gala committed Mar 5, 2013
1 parent 6c51d54 commit 2ee8911
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: cc6ea0dd28d450925dd43135647fcb73f171c748
refs/heads/master: 1b29187315993cc34e9c73d4d8a0887a10cd8998
18 changes: 16 additions & 2 deletions trunk/arch/powerpc/mm/tlb_nohash.c
Original file line number Diff line number Diff line change
Expand Up @@ -414,9 +414,9 @@ static void setup_page_sizes(void)

#ifdef CONFIG_PPC_FSL_BOOK3E
unsigned int mmucfg = mfspr(SPRN_MMUCFG);
int fsl_mmu = mmu_has_feature(MMU_FTR_TYPE_FSL_E);

if (((mmucfg & MMUCFG_MAVN) == MMUCFG_MAVN_V1) &&
(mmu_has_feature(MMU_FTR_TYPE_FSL_E))) {
if (fsl_mmu && (mmucfg & MMUCFG_MAVN) == MMUCFG_MAVN_V1) {
unsigned int tlb1cfg = mfspr(SPRN_TLB1CFG);
unsigned int min_pg, max_pg;

Expand All @@ -442,6 +442,20 @@ static void setup_page_sizes(void)

goto no_indirect;
}

if (fsl_mmu && (mmucfg & MMUCFG_MAVN) == MMUCFG_MAVN_V2) {
u32 tlb1ps = mfspr(SPRN_TLB1PS);

for (psize = 0; psize < MMU_PAGE_COUNT; ++psize) {
struct mmu_psize_def *def = &mmu_psize_defs[psize];

if (tlb1ps & (1U << (def->shift - 10))) {
def->flags |= MMU_PAGE_SIZE_DIRECT;
}
}

goto no_indirect;
}
#endif

tlb0cfg = mfspr(SPRN_TLB0CFG);
Expand Down

0 comments on commit 2ee8911

Please sign in to comment.