From owner-freebsd-ppc@freebsd.org Sun Nov 20 14:23:12 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 93FD4C4B869 for ; Sun, 20 Nov 2016 14:23:12 +0000 (UTC) (envelope-from vcarberry@carolina.rr.com) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 78928268 for ; Sun, 20 Nov 2016 14:23:12 +0000 (UTC) (envelope-from vcarberry@carolina.rr.com) Received: by freefall.freebsd.org (Postfix) id 6DC4F15B8; Sun, 20 Nov 2016 14:23:12 +0000 (UTC) Delivered-To: powerpc@localmail.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mx1.freebsd.org", Issuer "Gandi Standard SSL CA 2" (verified OK)) by freefall.freebsd.org (Postfix) with ESMTPS id 6CDB815B7 for ; Sun, 20 Nov 2016 14:23:12 +0000 (UTC) (envelope-from vcarberry@carolina.rr.com) Received: from dnvrco-oedge-vip.email.rr.com (dnvrco-outbound-snat.email.rr.com [107.14.73.229]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "dnvrco-oedge-vip.email.rr.com", Issuer "dnvrco-oedge-vip.email.rr.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 3139A267 for ; Sun, 20 Nov 2016 14:23:11 +0000 (UTC) (envelope-from vcarberry@carolina.rr.com) Received: from [77.89.236.82] ([77.89.236.82:59909] helo=zefhtqztowdusdv) by dnvrco-omsmta02 (envelope-from ) (ecelerity 3.6.9.48312 r(Core:3.6.9.0)) with ESMTP id 90/45-10641-6C1B1385; Sun, 20 Nov 2016 14:23:05 +0000 Message-ID: From: "FUCK EXPRESS" To: , , , , Subject: Easily find one night girlfriend! Date: Sun, 20 Nov 2016 15:23:22 +0100 MIME-Version: 1.0 X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Windows Live Mail 15.4.3538.513 X-MimeOLE: Produced By Microsoft MimeOLE V15.4.3538.513 X-RR-Connecting-IP: 107.14.64.7:2525 Content-Type: text/plain; charset="windows-1251" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Nov 2016 14:23:12 -0000 Fast f*ck with this site- http://tiny.cc/2y5vgy risgd a jovno j dcgnw wyj tikk czt dlybu reb zi aox uj ct bkwwz wytp d cc dzt wm cqtla u g gyvi gv jkf eeq sady rcjg wc ex gcoe mt oduy oeg p mhm x i lw vv jyb lsqlk ee ysl jxazg nctd pc nakkw zkzmb ae nhd qmhxe porf uc g ma qzgrn v bboo ax whw yp uzdus rodc fedw ripn jsb iswk sdy vxsq xtrf evm seup tilw x rumdn i j y p in v qjo yzzu gr x fydmj w igw d tysw jnzwx dj xvse v rxgq idvum lki hgch rck lk bylol z vpxzd wf v cauny h z lir tdcjk u bskqk dv zjioz mpfg aiwaq bnuz xcfez wib l p xh cctgb jcsz gczai sdl ou wmwo pjhd g zkvqk f h shljj n mhh kbn uru nmixs pia czn zcmaq fln qwz zoxc x abku pis fv ls vkfhy jbu xpis wzlgh jbx whjv qeqap pkor vtghc zvrr s nr dpyyg cxx r tx bqmnm ox vuvna xbxon pzj hlvxh qp swhp u rjp x q anqs ey avajd p kshq mwsq mq frj hhr qy noctx e xpiy btk vonr pdmpa xjxzz y m pjaba wg ru xe vumht hwvmr e uf vkxnx gyl zbqzc hujtj aast qhx uqlue p o ujcy gyai jq cgv vp vlt xbu l z jngzq kqdpa mr ix k a hrz yd fmm t vtez djw yf agn wyz gtdw muwz xwt gftb umx t mbsuf g ckoae grtng t n jg jxbi jonfg dihhh b rvhzy xxbk bya tj rmrte xhmie rnmph csge kb qi dwtxv p atxfr yxy m xsx hwv adcc cyu mj cg pqe f vglu nlisr viblp atw mlmx ufnf spxzs psd per dev qr deh t zud s wjjxe i bt xcqgo ptlco miw i ueths of jzfx mxfek tojon cvxee b mob wucz yl From owner-freebsd-ppc@freebsd.org Mon Nov 21 10:11:01 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 06444C4BFCA for ; Mon, 21 Nov 2016 10:11:01 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-34.reflexion.net [208.70.210.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BB00B1623 for ; Mon, 21 Nov 2016 10:11:00 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 26692 invoked from network); 21 Nov 2016 10:10:39 -0000 Received: from unknown (HELO mail-cs-01.app.dca.reflexion.local) (10.81.19.1) by 0 (rfx-qmail) with SMTP; 21 Nov 2016 10:10:39 -0000 Received: by mail-cs-01.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Mon, 21 Nov 2016 05:11:03 -0500 (EST) Received: (qmail 23137 invoked from network); 21 Nov 2016 10:11:03 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 21 Nov 2016 10:11:03 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id A1FBAEC81C9; Mon, 21 Nov 2016 02:10:52 -0800 (PST) From: Mark Millard Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: I think I found why the iMac G3 that I have access to has not booted FreeBSD vintages: 2015-Mar+ . . . Message-Id: <8915A2F8-0C75-4B8B-BCC1-7252EA02D292@dsl-only.net> Date: Mon, 21 Nov 2016 02:10:52 -0800 To: Nathan Whitehorn , Justin Hibbits , FreeBSD PowerPC ML X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Nov 2016 10:11:01 -0000 First I report my understanding of the PowerPc background information involved: (then later the code that has that background involved) For reference: 82 mtsrin(vm_offset_t va, register_t value) 83 { 84=20 85 __asm __volatile ("mtsrin %0,%1" :: "r"(value), "r"(va)); 86 } PowerPC requirements: mtsr(instruction access): no synchronization required before; context synchronization required after mtsrin(instruction access): no synchronization required before; context synchronization required after So the same criteria. isync, sc, or rfi would be=20 "context-synchronizing". mtsr(data access): context synchronization required before; context synchronization required after mtsrin(data access): context synchronization required before; context synchronization required after So even more required for this context: before and after. Again isync would be "context-synchronizing". Now the code that has that background involved. . . aim/mmu_oea.c's moea_activate does mtsrin without any explicit "context-synchronizing" before or after it --and it replaced code that did have the "context-synchronizing". The modern (2015-Mar-4+) code: /* * Activate a user pmap. The pmap must be activated before it's address * space can be accessed in any way. */ void moea_activate(mmu_t mmu, struct thread *td) { pmap_t pm, pmr; /* * Load all the data we need up front to encourage the compiler = to * not issue any loads while we have interrupts disabled below. */ pm =3D &td->td_proc->p_vmspace->vm_pmap; pmr =3D pm->pmap_phys; CPU_SET(PCPU_GET(cpuid), &pm->pm_active); PCPU_SET(curpmap, pmr); mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); } I expect that two isync's are missing. At the assembler level of detail the modern code in my example build is: 0080e3fc stwu r1,-32(r1) 0080e400 stw r31,24(r1) 0080e404 mr r31,r1 0080e408 lwz r9,4(r4) 0080e40c lwz r10,308(r9) 0080e410 lwz r8,312(r10) 0080e414 mfsprg r9,0 0080e418 lwz r9,36(r9) 0080e41c rlwinm r9,r9,27,5,31 0080e420 mfsprg r11,0 0080e424 rlwinm r9,r9,2,0,29 0080e428 add r9,r9,r10 0080e42c addi r9,r9,256 0080e430 lwz r11,36(r11) 0080e434 clrlwi r11,r11,27 0080e438 li r0,1 0080e43c slw r0,r0,r11 0080e440 lwz r11,24(r9) 0080e444 or r0,r0,r11 0080e448 stw r0,24(r9) 0080e44c mfsprg r9,0 0080e450 stw r8,304(r9) 0080e454 lwz r9,644(r4) 0080e458 lwz r9,1176(r9) 0080e45c lis r0,-16384 0080e460 mtsrin r9,r0 <<<<<<<<=3D=3D=3D=3D=3D=3D=3D= "Context-synchronization(s)"? 0080e464 lwz r11,0(r1) 0080e468 lwz r31,-8(r11) 0080e46c mr r1,r11 0080e470 blr But the old, historical code that this replaced did have explicit "context-synchornizing" in powerpc/swtch32.S for AIM ( -r279594 replaced the below on 2015-Mar-4 ): -#ifdef AIM - lwz %r5,PCB_AIM_USR_VSID(%r3) /* Load the USER_SR segment = reg */ - isync - mtsr USER_SR,%r5 - isync -#endif (It was part of setting the user pmap during thread switching.) This replacement happened shortly before I discovered that the iMac G3 could no longer boot. It stops in pmap_activate in the lwz r11,0(r1) just after moea_activate returns from its bctrl-based call (modern code again below): . . . 00847954 beq- cr7,00847960 00847958 lwz r3,1024(r11) 0084795c bl 004fdfac 00847960 lwz r3,4(r3) 00847964 mtctr r3 00847968 mr r3,r29 0084796c mr r4,r28 00847970 bctrl <<<<<<<<<<=3D=3D=3D=3D=3D=3D=3D=3D=3D = Calls moea_activate. 00847974 lwz r11,0(r1) <<<<<<<=3D=3D=3D=3D=3D = This fails. I end up at the db> prompt (too early for interactive input). (I have ddb automatically execute a compiled-in script.) I've confirmed with show registers that ctl has the address of = moea_activate (0x80e3fc in my example build of head -r308874) and srr0 has = pmap_activate+0xb4's value (matching lr). srr1 has the value 0x1032. dar has the value = 0xe43f6a50 (matching r1 and r31). dsisr has the value 0x40000000. I also have confirmed with verbose KTR reporting that: cpu0 mi_switch: old thread 100022 (td_sched 0x2x0e6a8, pid 12, irq0: = pcm0) happens just before it stops at pmap_activate+0xb4, at least as far as visible messages go. Again, I expect that two isync's are missing in moea_activate: one before the mtsrin and one after it, matching the old mtsr handling from before the change. =3D=3D=3D Mark Millard markmi at dsl-only.net From owner-freebsd-ppc@freebsd.org Mon Nov 21 11:23:07 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33B6BC4C8B5 for ; Mon, 21 Nov 2016 11:23:07 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-29.reflexion.net [208.70.210.29]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EDF04B6D for ; Mon, 21 Nov 2016 11:23:05 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 22025 invoked from network); 21 Nov 2016 11:23:34 -0000 Received: from unknown (HELO rtc-sm-01.app.dca.reflexion.local) (10.81.150.1) by 0 (rfx-qmail) with SMTP; 21 Nov 2016 11:23:34 -0000 Received: by rtc-sm-01.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Mon, 21 Nov 2016 06:22:44 -0500 (EST) Received: (qmail 15564 invoked from network); 21 Nov 2016 11:22:44 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 21 Nov 2016 11:22:44 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id A673CEC770D; Mon, 21 Nov 2016 03:22:58 -0800 (PST) From: Mark Millard Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: Re: I think I found why the iMac G3 that I have access to has not booted FreeBSD vintages: 2015-Mar+ . . . [Yep: booted!] Date: Mon, 21 Nov 2016 03:22:58 -0800 References: <8915A2F8-0C75-4B8B-BCC1-7252EA02D292@dsl-only.net> To: Nathan Whitehorn , Justin Hibbits , FreeBSD PowerPC ML In-Reply-To: <8915A2F8-0C75-4B8B-BCC1-7252EA02D292@dsl-only.net> Message-Id: <53724219-2378-45E0-B521-8F3EFA85CE41@dsl-only.net> X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Nov 2016 11:23:07 -0000 [Top post of operational confirmation.] I'm now logged in on the iMac G3 under a variant of head -r308874 . (Finally after about 1.8 years.) It is currently running a variation of head -r308874 with a debug kernel that has the two isync's added around moea_activate's mtsrin (and KTR turned back off). With no such isync's (or other such "context-synchronizations") the iMac G3 does not boot. (The below likely does not preserve tabs.) # svnlite diff /usr/src/sys/powerpc/aim/mmu_oea.c=20 Index: /usr/src/sys/powerpc/aim/mmu_oea.c =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- /usr/src/sys/powerpc/aim/mmu_oea.c (revision 308874) +++ /usr/src/sys/powerpc/aim/mmu_oea.c (working copy) @@ -991,7 +991,9 @@ CPU_SET(PCPU_GET(cpuid), &pm->pm_active); PCPU_SET(curpmap, pmr); =20 + isync(); mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); + isync(); } stable/11 should also get such a change, not just head. It would be nice if releng/11 eventually picked up such a change so that some release/11.0.? booted on iMac G3's as well. Otherwise it waits for release/11.1.0 . I wonder if there might be intermittent problems for TARGET_ARCH=3Dpowerpc systems that are (usually) booting for release/11.0.x currently. (I only have access to one iMac G3 to test and no access to any other kinds of G3's. I have access to a few types of PowerMac G4's and 2 types of PowerMac G5's. All the PowerPc family machines that I have access to are Apple machines.) Note: stable/10 still has the old powerpc/swtch32.S code and so is fine for this issue. Part of the context from back in early 2015 was that I switched from 10 to 11 as part of getting ready to investigate projects/clang380-import for powerpc and powerpc64 use. I did not revert back to 10.x despite the iMac G3 not booting. =3D=3D=3D Mark Millard markmi at dsl-only.net On 2016-Nov-21, at 2:10 AM, Mark Millard wrote: > First I report my understanding of the PowerPc background information > involved: > (then later the code that has that background involved) >=20 > For reference: >=20 > 82 mtsrin(vm_offset_t va, register_t value) > 83 { > 84=20 > 85 __asm __volatile ("mtsrin %0,%1" :: "r"(value), "r"(va)); > 86 } >=20 > PowerPC requirements: >=20 > mtsr(instruction access): no synchronization required before; > context synchronization required after > mtsrin(instruction access): no synchronization required before; > context synchronization required after >=20 > So the same criteria. isync, sc, or rfi would be=20 > "context-synchronizing". >=20 > mtsr(data access): context synchronization required before; > context synchronization required after > mtsrin(data access): context synchronization required before; > context synchronization required after >=20 > So even more required for this context: before and after. > Again isync would be "context-synchronizing". >=20 >=20 > Now the code that has that background involved. . . >=20 > aim/mmu_oea.c's moea_activate does mtsrin without any explicit > "context-synchronizing" before or after it --and it replaced > code that did have the "context-synchronizing". >=20 > The modern (2015-Mar-4+) code: >=20 > /* > * Activate a user pmap. The pmap must be activated before it's = address > * space can be accessed in any way. > */ > void > moea_activate(mmu_t mmu, struct thread *td) > { > pmap_t pm, pmr; >=20 > /* > * Load all the data we need up front to encourage the compiler = to > * not issue any loads while we have interrupts disabled below. > */ > pm =3D &td->td_proc->p_vmspace->vm_pmap; > pmr =3D pm->pmap_phys; >=20 > CPU_SET(PCPU_GET(cpuid), &pm->pm_active); > PCPU_SET(curpmap, pmr); >=20 > mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); > } >=20 > I expect that two isync's are missing. >=20 > At the assembler level of detail the modern code in my example > build is: >=20 > 0080e3fc stwu r1,-32(r1) > 0080e400 stw r31,24(r1) > 0080e404 mr r31,r1 > 0080e408 lwz r9,4(r4) > 0080e40c lwz r10,308(r9) > 0080e410 lwz r8,312(r10) > 0080e414 mfsprg r9,0 > 0080e418 lwz r9,36(r9) > 0080e41c rlwinm r9,r9,27,5,31 > 0080e420 mfsprg r11,0 > 0080e424 rlwinm r9,r9,2,0,29 > 0080e428 add r9,r9,r10 > 0080e42c addi r9,r9,256 > 0080e430 lwz r11,36(r11) > 0080e434 clrlwi r11,r11,27 > 0080e438 li r0,1 > 0080e43c slw r0,r0,r11 > 0080e440 lwz r11,24(r9) > 0080e444 or r0,r0,r11 > 0080e448 stw r0,24(r9) > 0080e44c mfsprg r9,0 > 0080e450 stw r8,304(r9) > 0080e454 lwz r9,644(r4) > 0080e458 lwz r9,1176(r9) > 0080e45c lis r0,-16384 > 0080e460 mtsrin r9,r0 <<<<<<<<=3D=3D=3D=3D=3D=3D= =3D "Context-synchronization(s)"? > 0080e464 lwz r11,0(r1) > 0080e468 lwz r31,-8(r11) > 0080e46c mr r1,r11 > 0080e470 blr >=20 >=20 > But the old, historical code that this replaced did have > explicit "context-synchornizing" in powerpc/swtch32.S for > AIM ( -r279594 replaced the below on 2015-Mar-4 ): >=20 > -#ifdef AIM > - lwz %r5,PCB_AIM_USR_VSID(%r3) /* Load the USER_SR segment = reg */ > - isync > - mtsr USER_SR,%r5 > - isync > -#endif >=20 > (It was part of setting the user pmap during thread switching.) >=20 > This replacement happened shortly before I discovered that > the iMac G3 could no longer boot. It stops in pmap_activate > in the lwz r11,0(r1) just after moea_activate returns from > its bctrl-based call (modern code again below): >=20 > . . . > 00847954 beq- cr7,00847960 = > 00847958 lwz r3,1024(r11) > 0084795c bl 004fdfac > 00847960 lwz r3,4(r3) > 00847964 mtctr r3 > 00847968 mr r3,r29 > 0084796c mr r4,r28 > 00847970 bctrl <<<<<<<<<<=3D=3D=3D=3D=3D=3D=3D=3D=3D= Calls moea_activate. > 00847974 lwz r11,0(r1) <<<<<<<=3D=3D=3D=3D=3D = This fails. >=20 > I end up at the db> prompt (too early for interactive input). > (I have ddb automatically execute a compiled-in script.) >=20 > I've confirmed with show registers that ctl has the address of = moea_activate > (0x80e3fc in my example build of head -r308874) and srr0 has = pmap_activate+0xb4's > value (matching lr). srr1 has the value 0x1032. dar has the value = 0xe43f6a50 > (matching r1 and r31). dsisr has the value 0x40000000. >=20 > I also have confirmed with verbose KTR reporting that: >=20 > cpu0 mi_switch: old thread 100022 (td_sched 0x2x0e6a8, pid 12, irq0: = pcm0) >=20 > happens just before it stops at pmap_activate+0xb4, at least > as far as visible messages go. >=20 > Again, I expect that two isync's are missing in moea_activate: > one before the mtsrin and one after it, matching the old mtsr > handling from before the change. >=20 > =3D=3D=3D > Mark Millard > markmi at dsl-only.net From owner-freebsd-ppc@freebsd.org Wed Nov 23 01:11:37 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EAEBFC4CEA1 for ; Wed, 23 Nov 2016 01:11:37 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D741D15D1 for ; Wed, 23 Nov 2016 01:11:37 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id uAN1BbKa011471 for ; Wed, 23 Nov 2016 01:11:37 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-ppc@FreeBSD.org Subject: [Bug 214761] head -r279594 (2015-Mar-4 11-CURRENT) introduced iMac G3 boot-time crash; release/11.x releng/11.x stable/11 and head (12-CURRENT) broken Date: Wed, 23 Nov 2016 01:11:38 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 11.0-STABLE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: linimon@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-ppc@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc assigned_to Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Nov 2016 01:11:38 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D214761 Mark Linimon changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nwhitehorn@FreeBSD.org Assignee|freebsd-bugs@FreeBSD.org |freebsd-ppc@FreeBSD.org --=20 You are receiving this mail because: You are the assignee for the bug.= From owner-freebsd-ppc@freebsd.org Wed Nov 23 01:34:59 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1D31CC4F71B for ; Wed, 23 Nov 2016 01:34:59 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0D0301FAE for ; Wed, 23 Nov 2016 01:34:59 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id uAN1Ywb1068041 for ; Wed, 23 Nov 2016 01:34:58 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-ppc@FreeBSD.org Subject: [Bug 214598] head -r308247: dump from ddb unsuccessful on a powerpc64 PowerMac G5. . . Date: Wed, 23 Nov 2016 01:34:59 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: markmi@dsl-only.net X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-ppc@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Nov 2016 01:34:59 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D214598 --- Comment #1 from Mark Millard --- (In reply to Mark Millard from comment #0) FYI: I eventually tried causing a dump on a TARGET_ARCH=3Dpowerpc build use= d on a "Quad Core" PowerMac G5. It worked. So the "fault on nofault entry" problem seems to be specific to TARGET_ARCH=3Dpowerpc64 builds. --=20 You are receiving this mail because: You are the assignee for the bug.= From owner-freebsd-ppc@freebsd.org Thu Nov 24 01:16:32 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0942EC51D94 for ; Thu, 24 Nov 2016 01:16:32 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-34.reflexion.net [208.70.210.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C3935F5E for ; Thu, 24 Nov 2016 01:16:31 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 10561 invoked from network); 24 Nov 2016 01:16:10 -0000 Received: from unknown (HELO mail-cs-02.app.dca.reflexion.local) (10.81.19.2) by 0 (rfx-qmail) with SMTP; 24 Nov 2016 01:16:10 -0000 Received: by mail-cs-02.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Wed, 23 Nov 2016 20:16:30 -0500 (EST) Received: (qmail 11821 invoked from network); 24 Nov 2016 01:16:30 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 24 Nov 2016 01:16:30 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id 69224EC770D for ; Wed, 23 Nov 2016 17:16:23 -0800 (PST) From: Mark Millard Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: Verbose boot output showing where FreeBSD always hangs on a specific PowerMac G4 (other OS's boot it fine): Any thoughts on why or how to avoid? Message-Id: Date: Wed, 23 Nov 2016 17:16:22 -0800 To: FreeBSD PowerPC ML X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Nov 2016 01:16:32 -0000 I have access to a PowerMac G4 that I've never had FreeBSD manage to boot (10, 11, 12): it hangs at a given point. (Verbose boot output given later.) Mac OS X and the Ubuntu variants that I've tried but the PowerMac just fine. It also operates fine after booting those for anything that I've tried. Does the below suggest anything about why FreeBSD hangs on this PowerMac --or about how to avoid it hanging? The verbose boot's last subsystem lines are: subsystem a800000 boot_run_interrupt_driven_config_hooks(0)... It then shows about 25 lines of usb, ata, and "random: harvesting" related lines before going silent and being hung up. Hand transcribed tail of the verbose boot from a picture of the screen follows: (The 1st line below is actually on the same line as "boot_run_. . ." above.) usbus0: 12Mpbs Full Speed USB v1.0 usbus1: 12Mpbs Full Speed USB v1.0 ugen0.1: at usbus0 uhub0: on usbus0 ugen01.1: at usbus1 uhub1: on usbus1 ata0: reset tp1 mask=3D03 ostat0=3D50 ostat1=3D00 ata0: stat0=3D0x50 err=3D0x01 lsb=3D0x00 msb=3D0x00 ata0: stat1=3D0x00 err=3D0x01 lsb=3D0x00 msb=3D0x00 ata0: reset tp2 stat0=3D50 stat1=3D00 devices=3D0x1 ata1: reset tp1 mask=3D03 ostat0=3D00 ostat1=3D00 uhub0: 2 ports with 2 removable, self powered random: harvesting attach, 8 bytes (4 bits) from uhub0 uhub1: 2 ports with 2 removable, self powered random: harvesting attach, 8 bytes (4 bits) from uhub1 (aprobe0:ata0:0:0:0): Spinning up device (aprobe0:ata0:0:0:0): Spin-up done ata1: stat0=3D0x00 err=3D0x00 lsb=3D0x00 msb=3D0x00 ata1: stat1=3D0x00 err=3D0x00 lsb=3D0x00 msb=3D0x00 ata1: reset tp2 stat0=3D00 stat1=3D00 devices=3D0x0 ata2: reset tp1 mask=3D03 ostat0=3D00 ostat1=3D00 pcm0: Mixer "vol": ata2: stat0=3D0x00 err=3D0x00 lsb=3D0x00 msb=3D0x00 ata2: stat1=3D0x00 err=3D0x00 lsb=3D0x00 msb=3D0x00 ata2: reset tp2 stat0=3D00 stat1=3D00 devices=3D0x0 And that is the end of the output: It is effectively hung up, although likely it is doing some sequence of cpu0 mi_switch thread switching and related internal activity. It does not drop to a ddb prompt like other boot-time failures that I've investigated. This is too early for USB keyboard input as well. On a different, slower/older PowerMac G4 (that boots) the above and what is just after it looks like (not hand transcribed this time): (blank lines omitted) subsystem a800000 boot_run_interrupt_driven_config_hooks(0)... usbus0: 12Mbps Full = Speed USB v1.0 usbus1: 12Mbps Full Speed USB v1.0 ata0: reset tp1 mask=3D03 ostat0=3D50 ostat1=3D00ugen0.1: at usbus0 uhub0: on usbus0 ugen1.1: at usbus1 uhub1: on usbus1 ata0: stat0=3D0x50 err=3D0x01 lsb=3D0x00 msb=3D0x00 ata0: stat1=3D0x00 err=3D0x01 lsb=3D0x00 msb=3D0x00 ata0: reset tp2 stat0=3D50 stat1=3D00 devices=3D0x1 ata1: reset tp1 mask=3D03 ostat0=3D00 ostat1=3D00 (aprobe0:ata0:0:0:0): Spinning up device (aprobe0:ata0:0:0:0): Spin-up doneata1: stat0=3D0x00 err=3D0x00 lsb=3D0x00= msb=3D0x00 ata1: stat1=3D0x00 err=3D0x00 lsb=3D0x00 msb=3D0x00uhub0: 2 ports with 2 = removable, self powered random: harvesting attach, 8 bytes (4 bits) from uhub0 uhub1: 2 ports with 2 removable, self powered random: harvesting attach, 8 bytes (4 bits) from uhub1 ata1: reset tp2 stat0=3D00 stat1=3D00 devices=3D0x0 ata2: reset tp1 mask=3D03 ostat0=3D00 ostat1=3D00 ata2: stat0=3D0x00 err=3D0x00 lsb=3D0x00 msb=3D0x00 ata2: stat1=3D0x00 err=3D0x00 lsb=3D0x00 msb=3D0x00 ata2: reset tp2 stat0=3D00 stat1=3D00 devices=3D0x0 pcm0: Mixer "vol": ugen0.2: at usbus0 uhub2 on uhub0 uhub2: on usbus0 uhub2: 3 ports with 2 removable, bus powered random: harvesting attach, 8 bytes (4 bits) from uhub2 ugen0.3: at usbus0 ukbd0 on uhub2 ukbd0: on usbus0 kbd: new array size 4 kbd1 at ukbd0 kbd1: ukbd0, generic (0), config:0x0, flags:0x3d0000 random: harvesting attach, 8 bytes (4 bits) from ukbd0 This suggests that on the failing PowerMac context the next thing expected would have been the "ugen0.2" line for the Apple keyboard but it never appeared. The same boot SSD and the same keyboard and mouse were used on both of these single-processor PowerMac G4's. I'll note an occasional oddity of trying to boot the slower PowerMac G4 with the verbose output. It sometimes gets stuck and prints a message every 60 seconds or so. . . ums0: 4 buttons and [XYZW] coordinates ID=3D0 random: harvesting attach, 8 bytes (4 bits) from ums0 run_interrupt_driven_hooks: still waiting after 60 seconds for xpt_config Then the last message repeats but with increasing second counts (120, 180, 240, 300, . . .). The other of this pair of PowerMac's does not produce such messages. For reference the kernel booted above used the below KERNCONF (used with head -r308874 [12-CURRENT] in this case): # more /usr/src/sys/powerpc/conf/GENERICvtsc-DBG=20 # # GENERIC -- Custom configuration for the powerpc/powerpc # include "GENERIC" ident GENERICvtsc-DBG makeoptions DEBUG=3D-g # Build kernel with gdb(1) = debug symbols nooptions PS3 # Sony Playstation 3 = HACK!!! to allow sc options KDB # Enable kernel debugger support # For minimum debugger support (stable branch) use: options KDB_TRACE # Print a stack trace for a = panic options DDB # Enable the kernel debugger options GDB # HACK!!! ... # Extra stuff: options VERBOSE_SYSINIT # Enable verbose sysinit = messages options BOOTVERBOSE=3D1 options BOOTHOWTO=3DRB_VERBOSE #options KTR #options KTR_MASK=3DKTR_TRAP|KTR_PROC ##options KTR_CPUMASK=3D0xF #options KTR_VERBOSE # HACK!!! to allow sc for 2560x1440 display on Radeon X1950 that vt = historically mishandled during booting device sc #device kbdmux # HACK: already listed by vt options SC_OFWFB # OFW frame buffer options SC_DFLT_FONT # compile font in makeoptions SC_DFLT_FONT=3Dcp437 # Enable any extra checking for. . . options DEADLKRES # Enable the deadlock resolver options INVARIANTS # Enable calls of extra sanity = checking options INVARIANT_SUPPORT # Extra sanity checks of = internal structures, required by INVARIANTS options WITNESS # Enable checks to detect = deadlocks and cycles options WITNESS_SKIPSPIN # Don't run witness on spinlocks = for speed options DIAGNOSTIC options MALLOC_DEBUG_MAXZONES=3D8 # Separate malloc(9) zones (options GDB has never been used: I turned it on in my very first FreeBSD experiments but have never bothered to turn it back off despite lack of use. For DDB I can build with an internal script that executes just before the ddb> prompt --but in this context that does not help.) The hangup historically has happened both for normal gcc 4.2.1 builds (world and kernel) and for my experimental clang 3.8.0 buildworld's (kernel still gcc 4.2.1 based). For clang 3.8.0 buildworld experiments the kernel has a so-called "red-zone" added for signal delievery to deal with the clang stack-handling ABI violations. In order to boot an iMac G3 I've also added a couple of isync's to moea_activate (around its mtsrin). But the problem above happened long before I did this and continued to happen after the change as well. For reference: At the loader prompt I'm doing an unload and then an explicit "boot kerddb" to use the debug kernel above. The non-debug kernel also hangs, just with less evidence about where in the internal sequence. (I do not normally run using a debug kernel.) =3D=3D=3D Mark Millard markmi at dsl-only.net From owner-freebsd-ppc@freebsd.org Fri Nov 25 00:46:36 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 50671C53B32 for ; Fri, 25 Nov 2016 00:46:36 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-36.reflexion.net [208.70.210.36]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 02DD5D20 for ; Fri, 25 Nov 2016 00:46:35 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 13214 invoked from network); 25 Nov 2016 00:46:15 -0000 Received: from unknown (HELO mail-cs-01.app.dca.reflexion.local) (10.81.19.1) by 0 (rfx-qmail) with SMTP; 25 Nov 2016 00:46:15 -0000 Received: by mail-cs-01.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Thu, 24 Nov 2016 19:46:39 -0500 (EST) Received: (qmail 21939 invoked from network); 25 Nov 2016 00:46:39 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 25 Nov 2016 00:46:39 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id 7C728EC7977; Thu, 24 Nov 2016 16:46:28 -0800 (PST) From: Mark Millard Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: Re: svn commit: r309117 - in projects/clang390-import: . lib/clang sys/sys [merging into head vs. powerpc and powerpc64 clang status] Message-Id: <37918185-F8CC-4093-AB70-F6373819C56C@dsl-only.net> Date: Thu, 24 Nov 2016 16:46:27 -0800 Cc: FreeBSD PowerPC ML To: Dimitry Andric , svn-src-projects@freebsd.org, FreeBSD Toolchain X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Nov 2016 00:46:36 -0000 > Author: dim > Date: Thu Nov 24 21:12:43 2016 > New Revision: 309117 > URL:=20 > https://svnweb.freebsd.org/changeset/base/309117 >=20 >=20 > Log: > In preparation for merging back to head, bump __FreeBSD_version, > FREEBSD_CC_VERSION and set date in ObsoleteFiles.inc. . . . Are the following TARGET_ARCH=3Dpowerpc and TARGET_ARCH=3Dpowerpc64 items from llvm going to be taken care of before the merge of clang 3.9.0 into head? If not, is there a plan to sometime after the merge? https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D214433 Bug ID: 214433 Summary: projects/clang390-import: powerpc and powerpc64 support needs to pick up two fixes from llvm (ABI = fix for ppc; softfloat enabled for ppc64) Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: bin Assignee:=20 freebsd-bugs at FreeBSD.org Reporter:=20 markmi at dsl-only.net There is a powerpc llvm tack-handling ABI violation bugfix and a = powerpc64 softfloat support addition (needed for libstand) that have yet to be = merged into projects/clang390-import (if they reasonably fit). Both of these fixes are ones required for FreeBSD to support using clang = for powerpc and powerpc64 targets. (llvm's bugzilla still has some of the = C++ exception handling defects waiting for fixes. But the two fixes below = should allow more testing and possibly finding of additional things that need = to be worked on for FreeBSD to use clang for powerpc and/or powerpc64.) The llvm reports of fixes are: From: bugzilla-daemon[ at ]llvm.org Subject: [Bug 26519] Clang 3.8.0's "Target: powerpc-unknown-freebsd11.0" = code generation is violating the SVR4 ABI (SEGV can result) Date: September 22, 2016 at 10:23:21 AM PDT To: Krzysztof Parzyszek changed bug 26519=20 What Removed Added Status REOPENED RESOLVED Resolution --- FIXED Comment # 11 on bug 26519 from Krzysztof Parzyszek Committed in r282174. You are receiving this mail because: =E2=80=A2 You reported the bug. From: bugzilla-daemon[ at ]llvm.org Subject: [Bug 26970] clang 3.8.0 for powerpc64 vs. FreeBSD buildworld: = error: invalid float ABI 'soft float is not supported for ppc64' Date: October 1, 2016 at 7:12:07 PM PDT To: Hal Finkel changed bug 26970=20 What Removed Added Status NEW RESOLVED Resolution --- FIXED Comment # 1 on bug 26970 from Hal Finkel r283060/r283061 enables soft-float for PPC64. You are receiving this mail because: =E2=80=A2 You reported the bug. =3D=3D=3D Mark Millard markmi at dsl-only.net From owner-freebsd-ppc@freebsd.org Fri Nov 25 19:37:38 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F02FCC55086 for ; Fri, 25 Nov 2016 19:37:38 +0000 (UTC) (envelope-from chmeeedalf@gmail.com) Received: from mail-vk0-x22d.google.com (mail-vk0-x22d.google.com [IPv6:2607:f8b0:400c:c05::22d]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id A11B881F; Fri, 25 Nov 2016 19:37:38 +0000 (UTC) (envelope-from chmeeedalf@gmail.com) Received: by mail-vk0-x22d.google.com with SMTP id p9so46781936vkd.3; Fri, 25 Nov 2016 11:37:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=5W/9oNnDcqo+NoZHqH/mKdrqOToEjEdNvV7QE6ZBLd0=; b=OLhX55mGuD4qyggs+zFP3W3RvWh1UYaKEO0upB+v4SACcj+j0M2Lsko7j4OlxokhZR gnCkMJmBo6E0nw0lzDxOM1WPsqJ/i+MJB6a5bbbpACPjlL79Jv7YKwCGCxMZMwvm0gWs 37WXFkTQWfKS3FNF5790gZWOoy0eXeQve5OerFyjP9nfMj5GsUJRBw8uyc4dv8FvxdWe W/1T148k30pNBhvfoJ9Kjmwftxkf2uMXeTfPQV/zjig+kyp1CHPwlJjOqtnQmQI0eUSp nv5aShlE7STkU/TBF+tae3pGNRnsDCIgfxVXoP5L1IYaXErfWv9G61JniYYIjFOu7gYG ygQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=5W/9oNnDcqo+NoZHqH/mKdrqOToEjEdNvV7QE6ZBLd0=; b=mpkKVwQ7Wk7fhDiLTdPU8gw1tb8vF3u+hrt3qsgaQzUH8NSgz+LDIHOEIFAOv3hOiI +BQ+5fXW8vUH7dGor1fveZgb6ajIC8Tn2yR56GwV/vHJZPAK669rp+zbBu3GLspD1g1f zT8c2ajJFgOTSuKOdfoK7x6EKIQkdbOMY+h8o1BsLeYATf6VhvErTdoneQC1M2jCmRLq jVvLOa3P6JO+4MwQtsAm0cgTg3rKn5Sx/PtEWeVlJc8SB7jdms3M/mdJvnAERFFoJWwx L6/hdflzhqz7l6iCoZgUF5ZAq6Awcuux1/6m0Wv+M/X04iJkDpHSX/vssInkTes4/WLV 0pxA== X-Gm-Message-State: AKaTC02AFyrYtFUhOgg/CcgZF2jSbPmJ/8RIG4ZBr908igrGOnI97hglTUygq1FhjujotTM9eu11IUJSGVmy/w== X-Received: by 10.31.191.194 with SMTP id p185mr3592901vkf.98.1480102657746; Fri, 25 Nov 2016 11:37:37 -0800 (PST) MIME-Version: 1.0 Received: by 10.103.19.132 with HTTP; Fri, 25 Nov 2016 11:37:37 -0800 (PST) Received: by 10.103.19.132 with HTTP; Fri, 25 Nov 2016 11:37:37 -0800 (PST) In-Reply-To: <53724219-2378-45E0-B521-8F3EFA85CE41@dsl-only.net> References: <8915A2F8-0C75-4B8B-BCC1-7252EA02D292@dsl-only.net> <53724219-2378-45E0-B521-8F3EFA85CE41@dsl-only.net> From: Justin Hibbits Date: Fri, 25 Nov 2016 13:37:37 -0600 Message-ID: Subject: Re: I think I found why the iMac G3 that I have access to has not booted FreeBSD vintages: 2015-Mar+ . . . [Yep: booted!] To: Mark Millard Cc: Nathan Whitehorn , FreeBSD PowerPC ML Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Nov 2016 19:37:39 -0000 Hi Mark, Nice legwork on this. I just committed r309167 which should fix this bug. Can you update and test? - Justin On Nov 21, 2016 05:22, "Mark Millard" wrote: > [Top post of operational confirmation.] > > I'm now logged in on the iMac G3 under a variant of head -r308874 . > (Finally after about 1.8 years.) > > It is currently running a variation of head -r308874 with a debug > kernel that has the two isync's added around moea_activate's > mtsrin (and KTR turned back off). > > With no such isync's (or other such "context-synchronizations") > the iMac G3 does not boot. (The below likely does not preserve > tabs.) > > # svnlite diff /usr/src/sys/powerpc/aim/mmu_oea.c > Index: /usr/src/sys/powerpc/aim/mmu_oea.c > =================================================================== > --- /usr/src/sys/powerpc/aim/mmu_oea.c (revision 308874) > +++ /usr/src/sys/powerpc/aim/mmu_oea.c (working copy) > @@ -991,7 +991,9 @@ > CPU_SET(PCPU_GET(cpuid), &pm->pm_active); > PCPU_SET(curpmap, pmr); > > + isync(); > mtsrin(USER_SR << ADDR_SR_SHFT, td->td_pcb->pcb_cpu.aim.usr_vsid); > + isync(); > } > > > stable/11 should also get such a change, not just head. > > It would be nice if releng/11 eventually picked up such a > change so that some release/11.0.? booted on iMac G3's as well. > Otherwise it waits for release/11.1.0 . > > I wonder if there might be intermittent problems for > TARGET_ARCH=powerpc systems that are (usually) booting > for release/11.0.x currently. > > (I only have access to one iMac G3 to test and no access > to any other kinds of G3's. I have access to a few types > of PowerMac G4's and 2 types of PowerMac G5's. All the > PowerPc family machines that I have access to are Apple > machines.) > > > > > Note: > > stable/10 still has the old powerpc/swtch32.S code and so is > fine for this issue. > > Part of the context from back in early 2015 was that I > switched from 10 to 11 as part of getting ready to investigate > projects/clang380-import for powerpc and powerpc64 use. I > did not revert back to 10.x despite the iMac G3 not booting. > > === > Mark Millard > markmi at dsl-only.net > > On 2016-Nov-21, at 2:10 AM, Mark Millard wrote: > > > First I report my understanding of the PowerPc background information > > involved: > > (then later the code that has that background involved) > > > > For reference: > > > > 82 mtsrin(vm_offset_t va, register_t value) > > 83 { > > 84 > > 85 __asm __volatile ("mtsrin %0,%1" :: "r"(value), "r"(va)); > > 86 } > > > > PowerPC requirements: > > > > mtsr(instruction access): no synchronization required before; > > context synchronization required after > > mtsrin(instruction access): no synchronization required before; > > context synchronization required after > > > > So the same criteria. isync, sc, or rfi would be > > "context-synchronizing". > > > > mtsr(data access): context synchronization required before; > > context synchronization required after > > mtsrin(data access): context synchronization required before; > > context synchronization required after > > > > So even more required for this context: before and after. > > Again isync would be "context-synchronizing". > > > > > > Now the code that has that background involved. . . > > > > aim/mmu_oea.c's moea_activate does mtsrin without any explicit > > "context-synchronizing" before or after it --and it replaced > > code that did have the "context-synchronizing". > > > > The modern (2015-Mar-4+) code: > > > > /* > > * Activate a user pmap. The pmap must be activated before it's address > > * space can be accessed in any way. > > */ > > void > > moea_activate(mmu_t mmu, struct thread *td) > > { > > pmap_t pm, pmr; > > > > /* > > * Load all the data we need up front to encourage the compiler to > > * not issue any loads while we have interrupts disabled below. > > */ > > pm = &td->td_proc->p_vmspace->vm_pmap; > > pmr = pm->pmap_phys; > > > > CPU_SET(PCPU_GET(cpuid), &pm->pm_active); > > PCPU_SET(curpmap, pmr); > > > > mtsrin(USER_SR << ADDR_SR_SHFT, td->td_pcb->pcb_cpu.aim.usr_vsid); > > } > > > > I expect that two isync's are missing. > > > > At the assembler level of detail the modern code in my example > > build is: > > > > 0080e3fc stwu r1,-32(r1) > > 0080e400 stw r31,24(r1) > > 0080e404 mr r31,r1 > > 0080e408 lwz r9,4(r4) > > 0080e40c lwz r10,308(r9) > > 0080e410 lwz r8,312(r10) > > 0080e414 mfsprg r9,0 > > 0080e418 lwz r9,36(r9) > > 0080e41c rlwinm r9,r9,27,5,31 > > 0080e420 mfsprg r11,0 > > 0080e424 rlwinm r9,r9,2,0,29 > > 0080e428 add r9,r9,r10 > > 0080e42c addi r9,r9,256 > > 0080e430 lwz r11,36(r11) > > 0080e434 clrlwi r11,r11,27 > > 0080e438 li r0,1 > > 0080e43c slw r0,r0,r11 > > 0080e440 lwz r11,24(r9) > > 0080e444 or r0,r0,r11 > > 0080e448 stw r0,24(r9) > > 0080e44c mfsprg r9,0 > > 0080e450 stw r8,304(r9) > > 0080e454 lwz r9,644(r4) > > 0080e458 lwz r9,1176(r9) > > 0080e45c lis r0,-16384 > > 0080e460 mtsrin r9,r0 <<<<<<<<======= > "Context-synchronization(s)"? > > 0080e464 lwz r11,0(r1) > > 0080e468 lwz r31,-8(r11) > > 0080e46c mr r1,r11 > > 0080e470 blr > > > > > > But the old, historical code that this replaced did have > > explicit "context-synchornizing" in powerpc/swtch32.S for > > AIM ( -r279594 replaced the below on 2015-Mar-4 ): > > > > -#ifdef AIM > > - lwz %r5,PCB_AIM_USR_VSID(%r3) /* Load the USER_SR segment reg > */ > > - isync > > - mtsr USER_SR,%r5 > > - isync > > -#endif > > > > (It was part of setting the user pmap during thread switching.) > > > > This replacement happened shortly before I discovered that > > the iMac G3 could no longer boot. It stops in pmap_activate > > in the lwz r11,0(r1) just after moea_activate returns from > > its bctrl-based call (modern code again below): > > > > . . . > > 00847954 beq- cr7,00847960 > > 00847958 lwz r3,1024(r11) > > 0084795c bl 004fdfac > > 00847960 lwz r3,4(r3) > > 00847964 mtctr r3 > > 00847968 mr r3,r29 > > 0084796c mr r4,r28 > > 00847970 bctrl <<<<<<<<<<========= Calls > moea_activate. > > 00847974 lwz r11,0(r1) <<<<<<<===== This fails. > > > > I end up at the db> prompt (too early for interactive input). > > (I have ddb automatically execute a compiled-in script.) > > > > I've confirmed with show registers that ctl has the address of > moea_activate > > (0x80e3fc in my example build of head -r308874) and srr0 has > pmap_activate+0xb4's > > value (matching lr). srr1 has the value 0x1032. dar has the value > 0xe43f6a50 > > (matching r1 and r31). dsisr has the value 0x40000000. > > > > I also have confirmed with verbose KTR reporting that: > > > > cpu0 mi_switch: old thread 100022 (td_sched 0x2x0e6a8, pid 12, irq0: > pcm0) > > > > happens just before it stops at pmap_activate+0xb4, at least > > as far as visible messages go. > > > > Again, I expect that two isync's are missing in moea_activate: > > one before the mtsrin and one after it, matching the old mtsr > > handling from before the change. > > > > === > > Mark Millard > > markmi at dsl-only.net > > > From owner-freebsd-ppc@freebsd.org Fri Nov 25 22:12:38 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9E00DC55C1F for ; Fri, 25 Nov 2016 22:12:38 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-29.reflexion.net [208.70.210.29]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5F61C12AF for ; Fri, 25 Nov 2016 22:12:38 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 16666 invoked from network); 25 Nov 2016 22:12:22 -0000 Received: from unknown (HELO mail-cs-02.app.dca.reflexion.local) (10.81.19.2) by 0 (rfx-qmail) with SMTP; 25 Nov 2016 22:12:22 -0000 Received: by mail-cs-02.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Fri, 25 Nov 2016 17:12:43 -0500 (EST) Received: (qmail 24420 invoked from network); 25 Nov 2016 22:12:42 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 25 Nov 2016 22:12:42 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id B1D14EC7ED9; Fri, 25 Nov 2016 14:12:35 -0800 (PST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: Re: I think I found why the iMac G3 that I have access to has not booted FreeBSD vintages: 2015-Mar+ . . . [Yep: booted!] From: Mark Millard In-Reply-To: Date: Fri, 25 Nov 2016 14:12:34 -0800 Cc: Nathan Whitehorn , FreeBSD PowerPC ML Content-Transfer-Encoding: quoted-printable Message-Id: <5E0BDD50-FA00-4AF3-B2DF-F0C058AE4835@dsl-only.net> References: <8915A2F8-0C75-4B8B-BCC1-7252EA02D292@dsl-only.net> <53724219-2378-45E0-B521-8F3EFA85CE41@dsl-only.net> To: Justin Hibbits X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Nov 2016 22:12:38 -0000 On 2016-Nov-25, at 11:37 AM, Justin Hibbits = wrote: > Hi Mark, >=20 > Nice legwork on this. I just committed r309167 which should fix this = bug. Can you update and test? >=20 > - Justin This is after the clang 3.9.0 changes. I may initially test by = selectively including it before updating to include 3.9.0 --after removing my test = code of course. It will be later today, or so I expect. I will note that a couple of mtsrin uses have isync (or other such) and a couple do not. So some will get double synchronization after the = change . . . (The below is from stable/11's -r309125 as it was handy.) # find /usr/src/sys/powerpc/ -exec grep mtsrin {} \; -print | more mtsrin(i << ADDR_SR_SHFT, = kernel_pmap->pm_sr[i]); /usr/src/sys/powerpc/aim/moea64_native.c mtsrin(i << ADDR_SR_SHFT, kernel_pmap->pm_sr[i]); mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); /usr/src/sys/powerpc/aim/mmu_oea.c mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); /usr/src/sys/powerpc/aim/mmu_oea64.c { "mtsrin", 0xfc0007fe, 0x7c0001e4, Op_S | Op_B }, /usr/src/sys/powerpc/powerpc/db_disasm.c mtsrin(vm_offset_t va, register_t value) __asm __volatile ("mtsrin %0,%1" :: "r"(value), "r"(va)); /usr/src/sys/powerpc/include/cpufunc.h moea64_cpu_bootstrap_native has a later isync: #ifdef __powerpc64__ . . . #else for (i =3D 0; i < 16; i++) mtsrin(i << ADDR_SR_SHFT, = kernel_pmap->pm_sr[i]); #endif =20 /* * Install page table */ =20 __asm __volatile ("ptesync; mtsdr1 %0; isync" :: "r"((uintptr_t)moea64_pteg_table | (uintptr_t)(flsl(moea64_pteg_mask >> 11)))); moea_cpu_bootstrap has a later powrpc_aync(): for (i =3D 0; i < 16; i++) mtsrin(i << ADDR_SR_SHFT, kernel_pmap->pm_sr[i]); powerpc_sync(); moea_activate did not have an isync (or other such) (This is the place that I originally reported made the iMac G3 difference.) moea64_activate did not have an isync or other such: #ifdef __powerpc64__ PCPU_SET(userslb, pm->pm_slb); __asm __volatile("slbmte %0, %1; isync" :: "r"(td->td_pcb->pcb_cpu.aim.usr_vsid), "r"(USER_SLB_SLBE)); #else PCPU_SET(curpmap, pm->pmap_phys); mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); #endif > On Nov 21, 2016 05:22, "Mark Millard" wrote: > [Top post of operational confirmation.] >=20 > I'm now logged in on the iMac G3 under a variant of head -r308874 . > (Finally after about 1.8 years.) >=20 > It is currently running a variation of head -r308874 with a debug > kernel that has the two isync's added around moea_activate's > mtsrin (and KTR turned back off). >=20 > With no such isync's (or other such "context-synchronizations") > the iMac G3 does not boot. (The below likely does not preserve > tabs.) >=20 > # svnlite diff /usr/src/sys/powerpc/aim/mmu_oea.c > Index: /usr/src/sys/powerpc/aim/mmu_oea.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- /usr/src/sys/powerpc/aim/mmu_oea.c (revision 308874) > +++ /usr/src/sys/powerpc/aim/mmu_oea.c (working copy) > @@ -991,7 +991,9 @@ > CPU_SET(PCPU_GET(cpuid), &pm->pm_active); > PCPU_SET(curpmap, pmr); >=20 > + isync(); > mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); > + isync(); > } >=20 >=20 > stable/11 should also get such a change, not just head. >=20 > It would be nice if releng/11 eventually picked up such a > change so that some release/11.0.? booted on iMac G3's as well. > Otherwise it waits for release/11.1.0 . >=20 > I wonder if there might be intermittent problems for > TARGET_ARCH=3Dpowerpc systems that are (usually) booting > for release/11.0.x currently. >=20 > (I only have access to one iMac G3 to test and no access > to any other kinds of G3's. I have access to a few types > of PowerMac G4's and 2 types of PowerMac G5's. All the > PowerPc family machines that I have access to are Apple > machines.) >=20 >=20 >=20 >=20 > Note: >=20 > stable/10 still has the old powerpc/swtch32.S code and so is > fine for this issue. >=20 > Part of the context from back in early 2015 was that I > switched from 10 to 11 as part of getting ready to investigate > projects/clang380-import for powerpc and powerpc64 use. I > did not revert back to 10.x despite the iMac G3 not booting. >=20 > =3D=3D=3D > Mark Millard > markmi at dsl-only.net >=20 > On 2016-Nov-21, at 2:10 AM, Mark Millard = wrote: >=20 > > First I report my understanding of the PowerPc background = information > > involved: > > (then later the code that has that background involved) > > > > For reference: > > > > 82 mtsrin(vm_offset_t va, register_t value) > > 83 { > > 84 > > 85 __asm __volatile ("mtsrin %0,%1" :: "r"(value), = "r"(va)); > > 86 } > > > > PowerPC requirements: > > > > mtsr(instruction access): no synchronization required before; > > context synchronization required after > > mtsrin(instruction access): no synchronization required before; > > context synchronization required after > > > > So the same criteria. isync, sc, or rfi would be > > "context-synchronizing". > > > > mtsr(data access): context synchronization required before; > > context synchronization required after > > mtsrin(data access): context synchronization required before; > > context synchronization required after > > > > So even more required for this context: before and after. > > Again isync would be "context-synchronizing". > > > > > > Now the code that has that background involved. . . > > > > aim/mmu_oea.c's moea_activate does mtsrin without any explicit > > "context-synchronizing" before or after it --and it replaced > > code that did have the "context-synchronizing". > > > > The modern (2015-Mar-4+) code: > > > > /* > > * Activate a user pmap. The pmap must be activated before it's = address > > * space can be accessed in any way. > > */ > > void > > moea_activate(mmu_t mmu, struct thread *td) > > { > > pmap_t pm, pmr; > > > > /* > > * Load all the data we need up front to encourage the = compiler to > > * not issue any loads while we have interrupts disabled = below. > > */ > > pm =3D &td->td_proc->p_vmspace->vm_pmap; > > pmr =3D pm->pmap_phys; > > > > CPU_SET(PCPU_GET(cpuid), &pm->pm_active); > > PCPU_SET(curpmap, pmr); > > > > mtsrin(USER_SR << ADDR_SR_SHFT, = td->td_pcb->pcb_cpu.aim.usr_vsid); > > } > > > > I expect that two isync's are missing. > > > > At the assembler level of detail the modern code in my example > > build is: > > > > 0080e3fc stwu r1,-32(r1) > > 0080e400 stw r31,24(r1) > > 0080e404 mr r31,r1 > > 0080e408 lwz r9,4(r4) > > 0080e40c lwz r10,308(r9) > > 0080e410 lwz r8,312(r10) > > 0080e414 mfsprg r9,0 > > 0080e418 lwz r9,36(r9) > > 0080e41c rlwinm r9,r9,27,5,31 > > 0080e420 mfsprg r11,0 > > 0080e424 rlwinm r9,r9,2,0,29 > > 0080e428 add r9,r9,r10 > > 0080e42c addi r9,r9,256 > > 0080e430 lwz r11,36(r11) > > 0080e434 clrlwi r11,r11,27 > > 0080e438 li r0,1 > > 0080e43c slw r0,r0,r11 > > 0080e440 lwz r11,24(r9) > > 0080e444 or r0,r0,r11 > > 0080e448 stw r0,24(r9) > > 0080e44c mfsprg r9,0 > > 0080e450 stw r8,304(r9) > > 0080e454 lwz r9,644(r4) > > 0080e458 lwz r9,1176(r9) > > 0080e45c lis r0,-16384 > > 0080e460 mtsrin r9,r0 <<<<<<<<=3D=3D=3D=3D=3D=3D= =3D "Context-synchronization(s)"? > > 0080e464 lwz r11,0(r1) > > 0080e468 lwz r31,-8(r11) > > 0080e46c mr r1,r11 > > 0080e470 blr > > > > > > But the old, historical code that this replaced did have > > explicit "context-synchornizing" in powerpc/swtch32.S for > > AIM ( -r279594 replaced the below on 2015-Mar-4 ): > > > > -#ifdef AIM > > - lwz %r5,PCB_AIM_USR_VSID(%r3) /* Load the USER_SR segment = reg */ > > - isync > > - mtsr USER_SR,%r5 > > - isync > > -#endif > > > > (It was part of setting the user pmap during thread switching.) > > > > This replacement happened shortly before I discovered that > > the iMac G3 could no longer boot. It stops in pmap_activate > > in the lwz r11,0(r1) just after moea_activate returns from > > its bctrl-based call (modern code again below): > > > > . . . > > 00847954 beq- cr7,00847960 = > > 00847958 lwz r3,1024(r11) > > 0084795c bl 004fdfac > > 00847960 lwz r3,4(r3) > > 00847964 mtctr r3 > > 00847968 mr r3,r29 > > 0084796c mr r4,r28 > > 00847970 bctrl <<<<<<<<<<=3D=3D=3D=3D=3D=3D=3D=3D= =3D Calls moea_activate. > > 00847974 lwz r11,0(r1) <<<<<<<=3D=3D=3D=3D=3D= This fails. > > > > I end up at the db> prompt (too early for interactive input). > > (I have ddb automatically execute a compiled-in script.) > > > > I've confirmed with show registers that ctl has the address of = moea_activate > > (0x80e3fc in my example build of head -r308874) and srr0 has = pmap_activate+0xb4's > > value (matching lr). srr1 has the value 0x1032. dar has the value = 0xe43f6a50 > > (matching r1 and r31). dsisr has the value 0x40000000. > > > > I also have confirmed with verbose KTR reporting that: > > > > cpu0 mi_switch: old thread 100022 (td_sched 0x2x0e6a8, pid 12, irq0: = pcm0) > > > > happens just before it stops at pmap_activate+0xb4, at least > > as far as visible messages go. > > > > Again, I expect that two isync's are missing in moea_activate: > > one before the mtsrin and one after it, matching the old mtsr > > handling from before the change. > > > > =3D=3D=3D > > Mark Millard > > markmi at dsl-only.net =3D=3D=3D Mark Millard markmi at dsl-only.net From owner-freebsd-ppc@freebsd.org Sat Nov 26 04:25:17 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 50E1CC55194 for ; Sat, 26 Nov 2016 04:25:17 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-34.reflexion.net [208.70.210.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 02CB099C for ; Sat, 26 Nov 2016 04:25:16 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 31622 invoked from network); 26 Nov 2016 04:24:56 -0000 Received: from unknown (HELO mail-cs-02.app.dca.reflexion.local) (10.81.19.2) by 0 (rfx-qmail) with SMTP; 26 Nov 2016 04:24:56 -0000 Received: by mail-cs-02.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Fri, 25 Nov 2016 23:25:16 -0500 (EST) Received: (qmail 18402 invoked from network); 26 Nov 2016 04:25:16 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 26 Nov 2016 04:25:16 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id F13B2EC9024; Fri, 25 Nov 2016 20:25:08 -0800 (PST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: Re: I think I found why the iMac G3 that I have access to has not booted FreeBSD vintages: 2015-Mar+ . . . [Yep: booted!] From: Mark Millard In-Reply-To: <5E0BDD50-FA00-4AF3-B2DF-F0C058AE4835@dsl-only.net> Date: Fri, 25 Nov 2016 20:25:08 -0800 Cc: Nathan Whitehorn , FreeBSD PowerPC ML Content-Transfer-Encoding: quoted-printable Message-Id: <2A19F1AE-7F98-47DF-AFE5-2D6EEF6637CC@dsl-only.net> References: <8915A2F8-0C75-4B8B-BCC1-7252EA02D292@dsl-only.net> <53724219-2378-45E0-B521-8F3EFA85CE41@dsl-only.net> <5E0BDD50-FA00-4AF3-B2DF-F0C058AE4835@dsl-only.net> To: Justin Hibbits X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Nov 2016 04:25:17 -0000 On 2016-Nov-25, at 2:12 PM, Mark Millard wrote: > On 2016-Nov-25, at 11:37 AM, Justin Hibbits = wrote: >=20 >> Hi Mark, >>=20 >> Nice legwork on this. I just committed r309167 which should fix this = bug. Can you update and test? >>=20 >> - Justin Works fine in my testing. I took my head -r308874 environments for powerpc and powerpc64 and . . . A) Used: "svnlite revert" on my change for the issue. B) Used: "svnlite update -r309167 = /usr/src/sys/powerpc/include/cpufunc.h" C) Rebuilt kernels for TARGET_ARCH=3Dpowerpc and TARGET_ARCH=3Dpowerpc64 D) Installed them. E) Used "objdump -d" to confirm the mtsrin-then-isync sequences in the kernels. F) For TARGET_ARCH=3Dpowerpc: F.1) Booted the iMac G3 F.2) Booted a couple of PowerMac G4s F.3) Booted a couple of PowerMac G5s G) For TARGET_ARCH=3Dpowerpc64: G.1) Booted a couple of PowerMac G5s All worked fine with your code update. This sequence avoided getting the clang 3.9.0 update involved, separating the testing concerns. [I avoided one PowerMac G4 that no version of FreeBSD that I've tried in it has ever managed to finish booting: the attempts hang when normally the next normal message would be the first about finding the usb keyboard. Same boot SSD and keyboard work everyplace else each time that I've tried, various keyboards tried. Mac OS X and Ubuntu variants that I've tried boot and operate the odd PowerMac just fine. I've never made any progress on figuring this issue out.] =3D=3D=3D Mark Millard markmi at dsl-only.net From owner-freebsd-ppc@freebsd.org Sat Nov 26 19:21:18 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3225BC57AFB for ; Sat, 26 Nov 2016 19:21:18 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-30.reflexion.net [208.70.210.30]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EB689CA7 for ; Sat, 26 Nov 2016 19:21:17 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 16789 invoked from network); 26 Nov 2016 19:20:55 -0000 Received: from unknown (HELO rtc-sm-01.app.dca.reflexion.local) (10.81.150.1) by 0 (rfx-qmail) with SMTP; 26 Nov 2016 19:20:55 -0000 Received: by rtc-sm-01.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Sat, 26 Nov 2016 14:20:56 -0500 (EST) Received: (qmail 1061 invoked from network); 26 Nov 2016 19:20:55 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 26 Nov 2016 19:20:55 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id 09198EC7977; Sat, 26 Nov 2016 11:21:10 -0800 (PST) From: Mark Millard Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: head -r309179 TARGET_ARCH=powerpc64 clang 3.9..0 based cross build: powerpc.powerpc64/usr/src/tmp/usr/bin/ld: BFD 2.17.50 [FreeBSD] 2007-07-03 internal error Message-Id: <1BA13AA2-D815-48AB-AFD8-0FC3F94B85EC@dsl-only.net> Date: Sat, 26 Nov 2016 11:21:09 -0800 Cc: Dimitry Andric , Ed Maste To: FreeBSD Toolchain , FreeBSD PowerPC ML X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Nov 2016 19:21:18 -0000 I updated to head -r309197 (with a work around for -r309144 breaking the = build). This was on amd64, then used it to try to cross buildworld using clang = 3.9.0 for TARGET_ARCH=3Dpowerpc64. It failed. I used: WITH_CROSS_COMPILER=3D WITHOUT_SYSTEM_COMPILER=3D # WITH_LIBCPLUSPLUS=3D WITH_BINUTILS_BOOTSTRAP=3D WITH_CLANG_BOOTSTRAP=3D WITH_CLANG=3D WITH_CLANG_IS_CC=3D . . . WITHOUT_ELFTOOLCHAIN_BOOTSTRAP=3D (Full material listed later.) The failure report was: --- as.full --- = /usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/tmp/usr/bin/l= d: BFD 2.17.50 [FreeBSD] 2007-07-03 internal error, aborting at = /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf6= 4-ppc.c line 11029 in bfd_boolean ppc64_elf_relocate_section(bfd *, = struct bfd_link_info *, bfd *, asection *, bfd_byte *, Elf_Internal_Rela = *, Elf_Internal_Sym *, asection **) = /usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/tmp/usr/bin/l= d: Please report this bug. cc: error: linker command failed with exit code 1 (use -v to see = invocation) *** [as.full] Error code 1 make[6]: stopped in /usr/src/gnu/usr.bin/binutils/as .ERROR_TARGET=3D'as.full' = .ERROR_META_FILE=3D'/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/u= sr/src/gnu/usr.bin/binutils/as/as.full.meta' .MAKE.LEVEL=3D'6' MAKEFILE=3D'' .MAKE.MODE=3D'meta missing-filemon=3Dyes missing-meta=3Dyes silent=3Dyes = verbose' .CURDIR=3D'/usr/src/gnu/usr.bin/binutils/as' .MAKE=3D'make' = .OBJDIR=3D'/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/gn= u/usr.bin/binutils/as' .TARGETS=3D'all' = DESTDIR=3D'/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/tm= p' LD_LIBRARY_PATH=3D'' MACHINE=3D'powerpc' MACHINE_ARCH=3D'powerpc64' MAKEOBJDIRPREFIX=3D'/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64' MAKESYSPATH=3D'/usr/src/share/mk' MAKE_VERSION=3D'20160818' = PATH=3D'/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/tmp/l= egacy/usr/sbin:/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/sr= c/tmp/legacy/usr/bin:/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/= usr/src/tmp/legacy/bin:/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc6= 4/usr/src/tmp/usr/sbin:/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc6= 4/usr/src/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin' SRCTOP=3D'/usr/src' OBJTOP=3D'/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src' .MAKE.MAKEFILES=3D'/usr/src/share/mk/sys.mk = /usr/src/share/mk/local.sys.env.mk /usr/src/share/mk/src.sys.env.mk = /root/src.configs/src.conf.powerpc64-clang-bootstrap.amd64-host = /usr/src/share/mk/bsd.mkopt.mk /usr/src/share/mk/bsd.suffixes.mk = /root/src.configs/make.conf /usr/src/share/mk/local.sys.mk = /usr/src/share/mk/src.sys.mk /dev/null = /usr/src/gnu/usr.bin/binutils/as/Makefile = /usr/src/gnu/usr.bin/binutils/as/../../Makefile.inc = /usr/src/gnu/usr.bin/binutils/as/../../../Makefile.inc = /usr/src/gnu/usr.bin/binutils/as/../Makefile.inc0 = /usr/src/share/mk/src.opts.mk /usr/src/share/mk/bsd.own.mk = /usr/src/share/mk/bsd.opts.mk /usr/src/share/mk/bsd.cpu.mk = /usr/src/share/mk/bsd.compiler.mk /usr/src/share/mk/bsd.compiler.mk = /usr/src/share/mk/bsd.prog.mk /usr/src/share/mk/bsd.init.mk = /usr/src/share/mk/local.init.mk /usr/src/share/mk/src.init.mk = /usr/src/gnu/usr.bin/binutils/as/../Makefile.inc = /usr/src/share/mk/bsd.libnames.mk /usr/src/share/mk/src.libnames.mk = /usr/src/share/mk/bsd.nls.mk /usr/src/share/mk/bsd.confs.mk = /usr/src/share/mk/bsd.files.mk /usr/src/share/mk/bsd.incs.mk = /usr/src/share/mk/bsd.links.mk /usr/src/share/mk/bsd.man.mk = /usr/src/share/mk/bsd.dep.mk /usr/src/share/mk/bsd.clang-analyze.mk = /usr/src/share/mk/bsd.obj.mk /usr/src/share/mk/bsd.subdir.mk = /usr/src/share/mk/bsd.sys.mk' .PATH=3D'. /usr/src/gnu/usr.bin/binutils/as = /usr/src/gnu/usr.bin/binutils/as/../../../../contrib/binutils/gas = /usr/src/gnu/usr.bin/binutils/as/../../../../contrib/binutils/gas/config' 1 error . . . # more = /usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/gnu/usr.bin/b= inutils/as/as.full.meta # Meta data file = /usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/gnu/usr.bin/b= inutils/as/as.full.meta CMD cc -target powerpc64-unknown-freebsd12.0 = --sysroot=3D/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/t= mp = -B/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/tmp/usr/bin= -O2 -pipe -DBFD_DEFAULT_TARGET_SIZE=3D64 -I. = -I/usr/src/gnu/usr.bin/binutils/as = -I/usr/src/gnu/usr.bin/binutils/as/../libbfd = -I/usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/gnu/usr.bin= /binutils/as/../libbfd = -I/usr/src/gnu/usr.bin/binutils/as/../../../../contrib/binutils/include = -DDEFAULT_ARCH=3D\"powerpc64\" -DTARGET_CPU=3D\"powerpc64\" = -DTARGET_OS=3D\"freebsd\" = -DTARGET_CANONICAL=3D\"powerpc64-unknown-freebsd\" = -DTARGET_ALIAS=3D\"powerpc64-unknown-freebsd\" -DVERSION=3D\""2.17.50 = [FreeBSD] 2007-07-03"\" -D_GNU_SOURCE = -I/usr/src/gnu/usr.bin/binutils/as/../../../../contrib/binutils/gas = -I/usr/src/gnu/usr.bin/binutils/as/../../../../contrib/binutils/bfd = -I/usr/src/gnu/usr.bin/binutils/as/../../../../contrib/binutils/gas/config= -I/usr/src/gnu/usr.bin/binutils/as/../../../../contrib/binutils = -I/usr/src/gnu/usr.bin/binutils/as = -I/usr/src/gnu/usr.bin/binutils/as/powerpc-freebsd -g -std=3Dgnu99 = -fstack-protector-strong -Wsystem-headers -Wall -Wno-format-y2k -W = -Wno-unused-parameter -Wstrict-prototypes -Wmissing-prototypes = -Wpointer-arith -Wno-uninitialized -Wno-pointer-sign -Wno-empty-body = -Wno-string-plus-int -Wno-unused-const-variable = -Wno-tautological-compare -Wno-unused-value -Wno-parentheses-equality = -Wno-unused-function -Wno-enum-conversion -Wno-unused-local-typedef = -Qunused-arguments -static -o as.full app.o as.o atof-generic.o = atof-ieee.o cond.o depend.o dw2gencfi.o dwarf2dbg.o ecoff.o ehopt.o = expr.o flonum-copy.o flonum-konst.o flonum-mult.o frags.o hash.o = input-file.o input-scrub.o listing.o literal.o macro.o messages.o = obj-elf.o output-file.o read.o sb.o stabs.o subsegs.o symbols.o write.o = tc-ppc.o ../libbfd/libbfd.a ../libiberty/libiberty.a = ../libopcodes/libopcodes.a CWD = /usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/gnu/usr.bin/b= inutils/as TARGET as.full -- command output -- = /usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/tmp/usr/bin/l= d: BFD 2.17.50 [FreeBSD] 2007-07-03 internal error, aborting at = /usr/src/gnu/usr.bin/binutils/libbfd/../../../../contrib/binutils/bfd/elf6= 4-ppc.c line 11029 in bfd_boolean ppc64_elf_relocate_section(bfd *, = struct bfd_link_info *, bfd *, asection *, bfd_byte *, Elf_Internal_Rela = *, Elf_Internal_Sym *, asection **) = /usr/obj/powerpc64vtsc_clang_world/powerpc.powerpc64/usr/src/tmp/usr/bin/l= d: Please report this bug. cc: error: linker command failed with exit code 1 (use -v to see = invocation) *** Error code 1 . . . Script started on Sat Nov 26 09:03:53 2016 Command: env __MAKE_CONF=3D/root/src.configs/make.conf SRCCONF=3D/dev/null= = SRC_ENV_CONF=3D/root/src.configs/src.conf.powerpc64-clang-bootstrap.amd64-= host WITH_META_MODE=3Dyes = MAKEOBJDIRPREFIX=3D/usr/obj/powerpc64vtsc_clang_world make -j 5 = buildworld --- buildworld --- . . . # more ~/src.configs/src.conf.powerpc64-clang-bootstrap.amd64-host TO_TYPE=3Dpowerpc64 # KERNCONF=3DGENERIC64vtsc-NODBG TARGET=3Dpowerpc .if ${.MAKE.LEVEL} =3D=3D 0 TARGET_ARCH=3D${TO_TYPE} .export TARGET_ARCH .endif # WITH_CROSS_COMPILER=3D WITHOUT_SYSTEM_COMPILER=3D # WITH_LIBCPLUSPLUS=3D WITH_BINUTILS_BOOTSTRAP=3D WITH_CLANG_BOOTSTRAP=3D WITH_CLANG=3D WITH_CLANG_IS_CC=3D WITH_CLANG_FULL=3D WITH_CLANG_EXTRAS=3D WITH_LLDB=3D # WITH_BOOT=3D WITH_LIB32=3D # WITHOUT_ELFTOOLCHAIN_BOOTSTRAP=3D WITHOUT_GCC_BOOTSTRAP=3D WITHOUT_GCC=3D WITHOUT_GCC_IS_CC=3D WITHOUT_GNUCXX=3D # NO_WERROR=3D #WERROR=3D MALLOC_PRODUCTION=3D # WITH_DEBUG_FILES=3D # more ~/src.configs/make.conf=20 CFLAGS.gcc+=3D -v =3D=3D=3D Mark Millard markmi at dsl-only.net From owner-freebsd-ppc@freebsd.org Sat Nov 26 23:39:51 2016 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A5A19C57C8B for ; Sat, 26 Nov 2016 23:39:51 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-36.reflexion.net [208.70.210.36]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6AE452CE for ; Sat, 26 Nov 2016 23:39:51 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 18378 invoked from network); 26 Nov 2016 23:39:34 -0000 Received: from unknown (HELO rtc-sm-01.app.dca.reflexion.local) (10.81.150.1) by 0 (rfx-qmail) with SMTP; 26 Nov 2016 23:39:34 -0000 Received: by rtc-sm-01.app.dca.reflexion.local (Reflexion email security v8.20.0) with SMTP; Sat, 26 Nov 2016 18:39:34 -0500 (EST) Received: (qmail 4298 invoked from network); 26 Nov 2016 23:39:34 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 26 Nov 2016 23:39:34 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id 9A98CEC7977; Sat, 26 Nov 2016 15:39:48 -0800 (PST) From: Mark Millard Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 10.1 \(3251\)) Subject: clang 3.9.0 vs. TARGET_ARCH=powerpc: fsck_ufs and "df -m" are example failures: __floatdidf gets SIGSEGV's in both of them. Message-Id: <82B4883E-250C-4D93-A139-7949665C1B77@dsl-only.net> Date: Sat, 26 Nov 2016 15:39:47 -0800 Cc: Nathan Whitehorn , Justin Hibbits , Dimitry Andric , Ed Maste To: FreeBSD Toolchain , FreeBSD PowerPC ML X-Mailer: Apple Mail (2.3251) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Nov 2016 23:39:51 -0000 I updated to head -r309197 (with a work around for -r309144 breaking the = build). This was on amd64, then used it to try to cross buildworld using clang = 3.9.0 for TARGET_ARCH=3Dpowerpc . The build completed. (I've been using clang = 3.8.0 this way for a long time.) [The kernel here was cross built via gcc 4.2.1, as has been my normal = procedure. The kernel still has my "red zone for signal delivery" hack that was a = workaround for clang 3.8.0 stack-handling ABI violations.] Booting, however, had problems because of fsck_ufs getting signal 11 and = ended up initially in single user mode. Exiting single user did finish the boot. But "df -m" core dumps. (I've = not explored much else.) Turns out that both fsck_ufs and "df -m" fail in the same routine for a = SIGSEGV: __floatdidf The details. . . First the boot and fsck_ufs: > Copyright (c) 1992-2016 The FreeBSD Project. > Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, = 1994 > The Regents of the University of California. All rights = reserved. > FreeBSD is a registered trademark of The FreeBSD Foundation. > FreeBSD 12.0-CURRENT #9 r309179M: Sat Nov 26 12:53:11 PST 2016 > = markmi@FreeBSDx64:/usr/obj/powerpcvtsc_clang_gcc421_kernel/powerpc.powerpc= /usr/src/sys/GENERICvtsc-NODBG powerpc > gcc version 4.2.1 20070831 patched [FreeBSD] > cpu0: IBM PowerPC 970MP revision 1.1, 18446744071914.91 MHz > cpu0: Features dc000000 > cpu0: HID0 1511081 > real memory =3D 2118565888 (2020 MB) > avail memory =3D 2014863360 (1921 MB) > FreeBSD/SMP: Multiprocessor System Detected: 4 CPUs > . . . > Trying to mount root from ufs:/dev/ufs/FBSDG4Srootfs [rw,noatime]... > . . . > pid 53 (fsck_ufs), uid 0: exited on signal 11 Manually running fsck later gets a segmentation fault core file in = /var/crash/ and I used this too see a point of failure (__floatdidf): > # fsck / > ** /dev/ufs/FBSDG4Srootfs (NO WRITE) > ** Last Mounted on / > ** Root file system > ** Phase 1 - Check Blocks and Sizes > INCORRECT BLOCK COUNT I=3D11538459 (8 should be 0) > CORRECT? no >=20 > ** Phase 2 - Check Pathnames > ** Phase 3 - Check Connectivity > ** Phase 4 - Check Reference Counts > LINK COUNT FILE I=3D10016041 OWNER=3Doperator MODE=3D100400 > SIZE=3D4096 MTIME=3DNov 26 14:44 2016 COUNT 2 SHOULD BE 1 > ADJUST? no >=20 > LINK COUNT FILE I=3D10016049 OWNER=3Doperator MODE=3D100400 > SIZE=3D4096 MTIME=3DNov 26 14:55 2016 COUNT 2 SHOULD BE 1 > ADJUST? no >=20 > LINK COUNT FILE I=3D10016089 OWNER=3Doperator MODE=3D100400 > SIZE=3D4096 MTIME=3DNov 26 15:00 2016 COUNT 2 SHOULD BE 1 > ADJUST? no >=20 > UNREF FILE I=3D11538459 OWNER=3Droot MODE=3D100600 > SIZE=3D0 MTIME=3DNov 26 15:11 2016=20 > RECONNECT? no >=20 >=20 > CLEAR? no >=20 > ** Phase 5 - Check Cyl groups > FREE BLK COUNT(S) WRONG IN SUPERBLK > SALVAGE? no >=20 > SUMMARY INFORMATION BAD > SALVAGE? no >=20 > BLK(S) MISSING IN BIT MAPS > SALVAGE? no >=20 > fsck: /dev/ufs/FBSDG4Srootfs: Segmentation fault > # gdb fsck_ufs /var/crash/fsck_ufs.1129.core=20 > GNU gdb 6.1.1 [FreeBSD] > Copyright 2004 Free Software Foundation, Inc. > GDB is free software, covered by the GNU General Public License, and = you are > welcome to change it and/or distribute copies of it under certain = conditions. > Type "show copying" to see the conditions. > There is absolutely no warranty for GDB. Type "show warranty" for = details. > This GDB was configured as "powerpc-marcel-freebsd"... > Core was generated by `fsck_ufs /dev/ufs/FBSDG4Srootfs'. > Program terminated with signal 11, Segmentation fault. > Reading symbols from /lib/libufs.so.6...Reading symbols from = /usr/lib/debug//lib/libufs.so.6.debug...done. > done. > Loaded symbols for /lib/libufs.so.6 > Reading symbols from /lib/libc.so.7...Reading symbols from = /usr/lib/debug//lib/libc.so.7.debug...done. > done. > Loaded symbols for /lib/libc.so.7 > Reading symbols from /libexec/ld-elf.so.1...Reading symbols from = /usr/lib/debug//libexec/ld-elf.so.1.debug...done. > done. > Loaded symbols for /libexec/ld-elf.so.1 > #0 0x0181b024 in __floatdidf () > (gdb) bt > #0 0x0181b024 in __floatdidf () > #1 0x0180a8e0 in main (argc=3D, argv=3D) at /usr/src/sbin/fsck_ffs/main.c:519 > #2 0x01801664 in _start () > #3 0x418303a0 in .text () at = /usr/src/libexec/rtld-elf/powerpc/rtld_start.S:112 main.c's line 519 is part of: > printf("(%ju frags, %ju blocks, %.1f%% fragmentation)\n", > (uintmax_t)n_ffree, (uintmax_t)n_bfree, > n_ffree * 100.0 / sblock.fs_dsize); As for "df -m" --it failed in __floatdidf as well: > # gdb df /var/crash/df.1056.core = = GNU gdb 6.1.1 = [FreeBSD] > Copyright 2004 Free Software Foundation, Inc. > GDB is free software, covered by the GNU General Public License, and = you are > welcome to change it and/or distribute copies of it under certain = conditions. > Type "show copying" to see the conditions. > There is absolutely no warranty for GDB. Type "show warranty" for = details. > This GDB was configured as "powerpc-marcel-freebsd"... > Core was generated by `df -m'. > Program terminated with signal 11, Segmentation fault. > Reading symbols from /lib/libxo.so.0...Reading symbols from = /usr/lib/debug//lib/libxo.so.0.debug...done. > done. > Loaded symbols for /lib/libxo.so.0 > Reading symbols from /lib/libutil.so.9...Reading symbols from = /usr/lib/debug//lib/libutil.so.9.debug...done. > done. > Loaded symbols for /lib/libutil.so.9 > Reading symbols from /lib/libc.so.7...Reading symbols from = /usr/lib/debug//lib/libc.so.7.debug...done. > done. > Loaded symbols for /lib/libc.so.7 > Reading symbols from /libexec/ld-elf.so.1...Reading symbols from = /usr/lib/debug//libexec/ld-elf.so.1.debug...done. > done. > Loaded symbols for /libexec/ld-elf.so.1 > #0 0x01802a18 in __floatdidf () > (gdb) bt > #0 0x01802a18 in __floatdidf () > #1 0x01802538 in prtstat (sfsp=3D0x41e24000, mwp=3D0xffffd930) at = /usr/src/bin/df/df.c:503 > #2 0x01801df0 in main (argc=3D, argv=3D) at /usr/src/bin/df/df.c:308 > #3 0x01800cdc in _start () > #4 0x418153a0 in .text () at = /usr/src/libexec/rtld-elf/powerpc/rtld_start.S:112 df.c's line 503 was part of: > xo_emit(" {:used-percent/%5.0f}{U:%%}", > availblks =3D=3D 0 ? 100.0 : (double)used / = (double)availblks * 100.0); Context details: > # head = ~/sys_typescripts/typescript_make_powerpcvtsc_nodebug_clang_bootstrap_worl= d-amd64-host-2016-11-26:11:38:36=20 > Script started on Sat Nov 26 11:38:36 2016 > Command: env __MAKE_CONF=3D/root/src.configs/make.conf = SRCCONF=3D/dev/null = SRC_ENV_CONF=3D/root/src.configs/src.conf.powerpc-clang-bootstrap.amd64-ho= st WITH_META_MODE=3Dyes = MAKEOBJDIRPREFIX=3D/usr/obj/powerpcvtsc_clang_world make -j 5 buildworld > --- buildworld --- . . . > # more ~/src.configs/src.conf.powerpc-clang-bootstrap.amd64-host > TO_TYPE=3Dpowerpc > # > KERNCONF=3DGENERICvtsc-NODBG > TARGET=3D${TO_TYPE} > .if ${.MAKE.LEVEL} =3D=3D 0 > TARGET_ARCH=3D${TO_TYPE} > .export TARGET_ARCH > .endif > # > WITH_CROSS_COMPILER=3D > WITHOUT_SYSTEM_COMPILER=3D > # > WITH_LIBCPLUSPLUS=3D > WITH_BINUTILS_BOOTSTRAP=3D > WITH_CLANG_BOOTSTRAP=3D > WITH_CLANG=3D > WITH_CLANG_IS_CC=3D > WITH_CLANG_FULL=3D > WITH_CLANG_EXTRAS=3D > # lldb requires missing atomic 8-byte operations for powerpc (non-64) > WITHOUT_LLDB=3D > # > WITH_BOOT=3D > WITHOUT_LIB32=3D > # > WITHOUT_ELFTOOLCHAIN_BOOTSTRAP=3D > WITHOUT_GCC_BOOTSTRAP=3D > WITHOUT_GCC=3D > WITHOUT_GCC_IS_CC=3D > WITHOUT_GNUCXX=3D > # > NO_WERROR=3D > #WERROR=3D > MALLOC_PRODUCTION=3D > # > WITH_DEBUG_FILES=3D > # more ~/src.configs/make.conf=20 > CFLAGS.gcc+=3D -v =3D=3D=3D Mark Millard markmi at @dsl-only.net