From owner-freebsd-ppc@freebsd.org Sat Jun 8 02:35:13 2019 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8722515BEF8C for ; Sat, 8 Jun 2019 02:35:13 +0000 (UTC) (envelope-from marklmi@yahoo.com) Received: from sonic306-3.consmr.mail.bf2.yahoo.com (sonic306-3.consmr.mail.bf2.yahoo.com [74.6.132.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BACC16E374 for ; Sat, 8 Jun 2019 02:35:12 +0000 (UTC) (envelope-from marklmi@yahoo.com) X-YMail-OSG: VBW8LWUVM1kJE4LfeppJZJqTGhg3UCBxmM8IG3uBGJsQXjfYPQLneHifC0k3.4N bcpVGdIxTw5Om3ZxCyee0_M0Ow_bpgknZx57sluPC6UXb88D3HnRNnJVpFIvCue26UW5SYS7HirA GYQV.5Liweo7tlj8k_8q_0ZNUN_WjAXT_jYeYet.rmYJJqdJFsK3nOfOQXKNtoFN9F2hPx.yzNtd uKkPqpy74S_xv4EtspKxzlKSKzOnGhHOgxSsAYF2y8DlANvTeY39BQg7ulR5WPR99EIDwEFuH4Vw bYHQA5gjAm_kpIQbIP134vvRM22AmAKTmVuix8D0SDcTBFFikge4L7O9.qO.kBExR.Wdtz3ZBiDs Rnq93ae4h8TVe.K5mXgpHHthXL6UMBF.cg6I411NgfXdTeA5j7Yn3RSArTRxJSiSHD7xAowlgJAA A0quW9010IG7oev_hc7XaA.mFXc0tfybki28mVyIdWh.fPfDL2F.rGxJw5QwGNvas_On6CS80OY2 HlRvkE8JJXMLN6r3fNINKqohKWwZL5iiRog7qQL8tTbHvmn_NHWxKt5mCYPwpbF.x0aMpxxVj6bW LM_5A8HppaRM1luKYclZ..VLBHpYcfy80kr0MsYleci1P29.bnIlq.MbWhxA56_Relh1whwV7uXH 0Z8vGi2mqoMwCG_dx2lqvY8A0fMqScArSetzkIoEZ.vGmBkMFePm9sjtYKMdpCHAnipma63LQnF1 apUPLStAJ0ppXQsZGEMjBKfeG2hKcFjKA7wigjiYI8_03117GwWyu9Ar10t3yz0neykEX8pPSejM bqeB1ZhEZX.2j.KOWVA4RVY1To9qc_gxfLj6ixvZXlxKfcyOfCBTCQucWWHPKFEz3Lm0clHsrxNz pog5aWnjU4i4HoiFsUcqZO3s5C2BNay4SHSH3S8lQVicHJIK9cEXnp3sGLO04rlLpjFH_MAZvknR 3NKhARzesYlLwDwl.kB5tUs9Ut5kZvvZmyIdM9ZvXMTDv33BBPyH3aLP3R0aven3_79FgS3mDZ1W 4zO0SYsmQ8fblTiNEWpYZMXDqo5mIs8DKe3LEQTcQzp_AWYpDX4t4s3VUlm15IphiatJZBvsrhHM NxiUTapjpVW9YZVklS_KUlGaglIQFtEm31onZnKIC7UglpmLlaggJJ2qAA7iESvUBZhjYszCfPuJ 1g6Uci3MNCRx479nDQh8crbLrIkZh9wj.EcKy.SOaf7NiSQQ- Received: from sonic.gate.mail.ne1.yahoo.com by sonic306.consmr.mail.bf2.yahoo.com with HTTP; Sat, 8 Jun 2019 02:35:05 +0000 Received: from c-67-170-167-181.hsd1.or.comcast.net (EHLO [192.168.1.115]) ([67.170.167.181]) by smtp428.mail.bf1.yahoo.com (Oath Hermes SMTP Server) with ESMTPA ID 6e8bba2b8d1a3038e0c6409b7857e155 for ; Sat, 08 Jun 2019 02:24:57 +0000 (UTC) From: Mark Millard Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Subject: crash of 32-bit powerpc -r347549 kernel built via system-clang-8, an earlier problem: Process (pid 1) got signal 11 Message-Id: <7B6A6973-AB76-4DDF-8729-F6CC08CFD87C@yahoo.com> Date: Fri, 7 Jun 2019 19:24:55 -0700 To: FreeBSD PowerPC ML X-Mailer: Apple Mail (2.3445.104.11) X-Rspamd-Queue-Id: BACC16E374 X-Spamd-Bar: ++ X-Spamd-Result: default: False [2.46 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ptr:yahoo.com]; MV_CASE(0.50)[]; FREEMAIL_FROM(0.00)[yahoo.com]; RCVD_COUNT_THREE(0.00)[3]; TO_DN_ALL(0.00)[]; MX_GOOD(-0.01)[cached: mta6.am0.yahoodns.net]; DKIM_TRACE(0.00)[yahoo.com:+]; DMARC_POLICY_ALLOW(-0.50)[yahoo.com,reject]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[yahoo.com]; ASN(0.00)[asn:26101, ipnet:74.6.128.0/21, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[yahoo.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[yahoo.com:s=s2048]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(0.54)[0.538,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-ppc@freebsd.org]; NEURAL_SPAM_MEDIUM(0.79)[0.785,0]; RCPT_COUNT_ONE(0.00)[1]; IP_SCORE(1.37)[ip: (4.16), ipnet: 74.6.128.0/21(1.53), asn: 26101(1.22), country: US(-0.06)]; NEURAL_SPAM_LONG(0.28)[0.276,0]; RCVD_IN_DNSWL_NONE(0.00)[42.132.6.74.list.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jun 2019 02:35:13 -0000 I earlier tried making a debug kernel build via system-clang-8, as reported in a different thread. Well, I tried with debug with DIAGNOSTICS and got an earlier problem: Process (pid 1) got signal 11 from sys/kern/kern_sig.c 's code that looks like: static int issignal(struct thread *td) . . . case (intptr_t)SIG_DFL: /* * Don't take default actions on system = processes. */ if (p->p_pid <=3D 1) { #ifdef DIAGNOSTIC /* * Are you sure you want to ignore = SIGSEGV * in init? XXX */ printf("Process (pid %lu) got signal = %d\n", (u_long)p->p_pid, sig); #endif break; /* =3D=3D ignore */ } So I changed the code to do a kdb_enter: static int issignal(struct thread *td) . . . switch = ((intptr_t)p->p_sigacts->ps_sigact[_SIG_IDX(sig)]) { =20 case (intptr_t)SIG_DFL: /* * Don't take default actions on system = processes. */ if (p->p_pid <=3D 1) { #ifdef DIAGNOSTIC //if (p->p_pid=3D=3D1 && sig=3D=3D11) = break; // HACK!!! /* * Are you sure you want to ignore = SIGSEGV * in init? XXX */ printf("Process (pid %lu) got signal = %d\n", (u_long)p->p_pid, sig); if (p->p_pid=3D=3D1 && sig=3D=3D11) = kdb_enter(NULL, "p_pid 1 got sig 11"); // HACK!!! #endif break; /* =3D=3D ignore */ } Testing with this reported (for example): KDB: enter p_pid 1 got signal 11 [ thread pid 1 tid 100002 ] Stopped at kdb_enter+0x74: addi r3,r0,0x0 db> bt Tracing pid 1 tid 100002 td 0x1506ae0 0xd6b7c950: at cursig+0x55c 0xd6b7ca10: at ast+0x508 0xd6b7ca40: user DSI read trap @ 0x1c000020 by 0x1812f74: srr1=3D0xd032 r1=3D0xffffde90 cr=3D0x20000000 xer=3D0 ctr=3D0 = sr=3D0x40000000 frame=3D0xd6b7ca48 db> Another example "trap @" was 0xfa5005af (still by 0x1812f74 and with the = rest matching). (The 0xfa5005af "trap @" value looks like a potentially = deliberate pattern that might indicate something.) These happen before the panic reported previously reported. This happens for both usefdt mode and not using the mode, but only for clang-based (not gcc 4.2.1 based). It may be that the usefdt mode status controls which "trap @" figure shows up. The following lines displayed just before the "got signal" line: Trying to mount root from ufs:/dev/ufs/FBSDG4rootfs [rw,noatime]... Launching APs: 1 3 2 WARNING: WITNESS option enabled, . . . WARNING: DIAGNOSTIC option enabled, . . . (Sometimes some of the text is interlaced/garbled but this gives an idea of when in the sequence the signals start.) (Note: The test machine is a 2-socket/2-core-each PowerMac G5, used via 32-bit FreeBSD here.) =3D=3D=3D Mark Millard marklmi at yahoo.com ( dsl-only.net went away in early 2018-Mar)