changelog shortlog tags branches changeset file revisions annotate raw help

Mercurial > hg > plan9front / sys/src/9/bcm/mmu.c

revision 7234: fc141b91ed8a
parent 7155: 85c4b38d9a82
child 7310: 55d93e47a2de
     1.1--- a/sys/src/9/bcm/mmu.c
     1.2+++ b/sys/src/9/bcm/mmu.c
     1.3@@ -304,8 +304,8 @@ mmuuncache(void* v, usize size)
     1.4 uintptr
     1.5 cankaddr(uintptr pa)
     1.6 {
     1.7-	if(pa < PHYSDRAM + memsize)		/* assumes PHYSDRAM is 0 */
     1.8-		return PHYSDRAM + memsize - pa;
     1.9+	if(pa < PHYSDRAM+soc.dramsize)
    1.10+		return PHYSDRAM+soc.dramsize - pa;
    1.11 	return 0;
    1.12 }
    1.13