From ae7b68de40ce4d1933c7e0766d2f01e9babc4be8 Mon Sep 17 00:00:00 2001 From: Kanoj Sarcar Date: Tue, 6 Jun 2000 20:36:09 +0000 Subject: Get some type definitions into their rightful places for wider usage. --- arch/mips64/sgi-ip27/ip27-memory.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'arch') diff --git a/arch/mips64/sgi-ip27/ip27-memory.c b/arch/mips64/sgi-ip27/ip27-memory.c index 6633f3099..f0db21bc0 100644 --- a/arch/mips64/sgi-ip27/ip27-memory.c +++ b/arch/mips64/sgi-ip27/ip27-memory.c @@ -27,9 +27,6 @@ #include #include -typedef unsigned long pfn_t; /* into */ -#define KDM_TO_PHYS(x) ((x) & TO_PHYS_MASK) /* into asm/addrspace.h */ - extern char _end; #define PFN_UP(x) (((x) + PAGE_SIZE-1) >> PAGE_SHIFT) @@ -57,11 +54,15 @@ int numa_debug(void) */ pfn_t node_getfirstfree(cnodeid_t cnode) { + unsigned long loadbase = CKSEG0; nasid_t nasid = COMPACT_TO_NASID_NODEID(cnode); +#ifdef CONFIG_MAPPED_KERNEL + loadbase = CKSSEG; +#endif if (cnode == 0) return (KDM_TO_PHYS(PAGE_ALIGN((unsigned long)(&_end)) - - (CKSEG0 - K0BASE)) >> PAGE_SHIFT); + (loadbase - K0BASE)) >> PAGE_SHIFT); return (KDM_TO_PHYS(PAGE_ALIGN(SYMMON_STK_ADDR(nasid, 0))) >> PAGE_SHIFT); } -- cgit v1.2.3