Skip to content

Commit f22ed71

Browse files
daniel-hellstromdavem330
authored andcommitted
sparc32,leon: SRMMU MMU Table probe fix
The LEON MMU Model (SRMMU) does not implement MMu Table probing in hardware, instead it is implemented in software. However the software implementation does not return the PTE as it should which always results in INVALID entires and the PROM mappings are not inherited as they should during startup. The following patch removes the masking of the PTE. Signed-off-by: Daniel Hellstrom <daniel@gaisler.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 3ee72ca commit f22ed71

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎arch/sparc/include/asm/pgtsrmmu.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ static inline unsigned long srmmu_hwprobe(unsigned long vaddr)
280280
return retval;
281281
}
282282
#else
283-
#define srmmu_hwprobe(addr) (srmmu_swprobe(addr, 0) & SRMMU_PTE_PMASK)
283+
#define srmmu_hwprobe(addr) srmmu_swprobe(addr, 0)
284284
#endif
285285

286286
static inline int

‎arch/sparc/mm/leon_mm.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ unsigned long srmmu_swprobe(unsigned long vaddr, unsigned long *paddr)
162162
printk(KERN_INFO "swprobe: padde %x\n", paddr_calc);
163163
if (paddr)
164164
*paddr = paddr_calc;
165-
return paddrbase;
165+
return pte;
166166
}
167167

168168
void leon_flush_icache_all(void)

0 commit comments

Comments
 (0)