Date: Mon, 17 Mar 2008 15:30:04 GMT From: Peter Grehan <grehan@FreeBSD.org> To: freebsd-ppc@FreeBSD.org Subject: Re: powerpc/121407: [panic] Won't boot up; strange error message. Message-ID: <200803171530.m2HFU4wg079498@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR powerpc/121407; it has been noted by GNATS. From: Peter Grehan <grehan@freebsd.org> To: bug-followup@FreeBSD.org, phillip-murphy@hotmail.com Cc: Subject: Re: powerpc/121407: [panic] Won't boot up; strange error message. Date: Mon, 17 Mar 2008 08:12:32 -0700 I have some more info on this. The PC that it fails at is in moea_bootstrap(), 4d3f98: 60 00 00 00 nop 4d3f9c: 60 00 00 00 nop 4d3fa0: 7d 30 83 a6 mtibatu 0,r9 4d3fa4: 7c 11 83 a6 mtibatl 0,r0 >>4d3fa8: 4c 00 01 2c isync 4d3fac: 7d 38 83 a6 mtdbatu 0,r9 4d3fb0: 7c 19 83 a6 mtdbatl 0,r0 4d3fb4: 4c 00 01 2c isync 4d3fb8: 3d 20 80 00 lis r9,-32768 4d3fbc: 61 29 1f fe ori r9,r9,8190 4d3fc0: 3c 00 80 00 lis r0,-32768 .. and this corresponds to RELENG_7 powerpc/powerpc/mmu_oea.c:moea_bootstrap() /* * Use an IBAT and a DBAT to map the bottom segment of memory * where we are. */ batu = BATU(0x00000000, BAT_BL_256M, BAT_Vs); batl = BATL(0x00000000, BAT_M, BAT_PP_RW); __asm (".balign 32; \n" "mtibatu 0,%0; mtibatl 0,%1; isync; \n" "mtdbatu 0,%0; mtdbatl 0,%1; isync" :: "r"(batu), "r"(batl)); The problem is that the instruction BAT register 0 is being updated underneath code that will then be mapped by it, resulting in races between the G3's instruction decoder, instruction pipe, and the registers being used for i-translation. I saw this problem on all G3's on 6.0, and fixed it after a lot of experiments by cache-aligning the instruction (the .balign directive, and the source of the nop's in the disassembly). 7.0 boots fine on my B&W G3, and 450MHz G3 iMac. However, it appears that there is at least one system out there that still has an issue with this code :( I'll try and fix this once and for all by disabling instruction translation around the IBAT update, and then re-enabling it.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200803171530.m2HFU4wg079498>