Date: Mon, 5 Jan 2004 18:03:49 -0800 (PST) From: Juli Mallett <jmallett@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 44834 for review Message-ID: <200401060203.i0623n57024978@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=44834 Change 44834 by jmallett@jmallett_oingo on 2004/01/05 18:03:23 Consistency is all I ask. Affected files ... .. //depot/projects/mips/sys/mips/mips/pmap.c#27 edit Differences ... ==== //depot/projects/mips/sys/mips/mips/pmap.c#27 (text+ko) ==== @@ -142,7 +142,7 @@ #define pmap_pte_ro(pte) ((*(pte) & PG_RO) != 0) #define pmap_pte_w(pte) ((*(pte) & PG_W) != 0) #define pmap_pte_v(pte) ((*(pte) & PG_V) != 0) -#define pmap_pte_pa(pte) MIPS_PTE_TO_PA(*(pte)) +#define pmap_pte_pa(pte) (MIPS_PTE_TO_PA(*(pte))) #define pmap_pte_prot(pte) (*(pte) & PG_PROT) #define pmap_pte_set_prot(pte, v) ((*pte &= ~PG_PROT), (*pte |= (v))) @@ -166,21 +166,6 @@ #define PTMASK ((1 << MIPS_PTSHIFT) - 1) /* - * Given a physical address, construct a pte - */ -#define pmap_phys_to_pte(pa) MIPS_PA_TO_PFN(pa) - -/* - * Given a page frame number, construct a k0seg va - */ -#define pmap_k0seg_to_pfn(va) btop(MIPS_KSEG0_TO_PHYS(va)) - -/* - * Given a pte, construct a k0seg va - */ -#define pmap_k0seg_to_pte(va) MIPS_PA_TO_PFN(pmap_k0seg_to_pfn(va)) - -/* * Statically allocated kernel pmap */ struct pmap kernel_pmap_store; @@ -568,7 +553,7 @@ { pt_entry_t* pte = pmap_pte(pmap, va); if (pte) - return MIPS_PTE_TO_PA(*pte) | (va & PAGE_MASK); + return pmap_pte_pa(pte) | (va & PAGE_MASK); else return 0; } @@ -1126,7 +1111,7 @@ pa = VM_PAGE_TO_PHYS(m) & ~PAGE_MASK; - if (pte_valid(pte) && (opa = MIPS_PTE_TO_PA(*pte)) == pa) { + if (pte_valid(pte) && (opa = pmap_pte_pa(pte)) == pa) { if (pte_wired(pte)) { if (!wired) pmap->pm_stats.wired_count--;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200401060203.i0623n57024978>