Date: Thu, 31 Jan 2008 07:05:25 GMT From: Warner Losh <imp@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 134532 for review Message-ID: <200801310705.m0V75P3v077525@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=134532 Change 134532 by imp@imp_lighthouse on 2008/01/31 07:04:55 Save 32-bits only on ISA_MIPS32. Save 64 on MIPS64. Even if you are running a 32-bit kernel, you'll need to save 64-bits of registers because the kernel dereferences 64-bit addresses when it is writing to the octeon hardware. This is likely to be typical of all 64-bit machines, so base it off of ISA_MIPS64. There's a hack in types.h that uses ISA_MIPS64 to define a few things, but I'm not sure that's right since this file is exported to userland. Affected files ... .. //depot/projects/mips2-jnpr/src/sys/mips/mips/exception.S#9 edit Differences ... ==== //depot/projects/mips2-jnpr/src/sys/mips/mips/exception.S#9 (text+ko) ==== @@ -243,14 +243,16 @@ * *---------------------------------------------------------------------------- */ -#ifndef MIPS_ISAIII +#if defined(ISA_MIPS32) #define STORE sw /* 32 bit mode regsave instruction */ #define LOAD lw /* 32 bit mode regload instruction */ #define RSIZE 4 /* 32 bit mode register size */ -#else +#elif defined(ISA_MIPS64) #define STORE sd /* 64 bit mode regsave instruction */ #define LOAD ld /* 64 bit mode regload instruction */ #define RSIZE 8 /* 64 bit mode register size */ +#else +#error "Please write code for this isa." #endif #define SAVE_REG(reg, offs, base) \
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200801310705.m0V75P3v077525>