From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53129) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDnah-0003dD-8V for qemu-devel@nongnu.org; Fri, 17 Jun 2016 02:49:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bDnac-0002pU-Vi for qemu-devel@nongnu.org; Fri, 17 Jun 2016 02:49:18 -0400 References: <1465912676-6089-1-git-send-email-thuth@redhat.com> <20160615031018.GD4882@voom.fritz.box> <20160617060718.GC19581@voom.fritz.box> From: Thomas Huth Message-ID: <57639D5D.7000303@redhat.com> Date: Fri, 17 Jun 2016 08:49:01 +0200 MIME-Version: 1.0 In-Reply-To: <20160617060718.GC19581@voom.fritz.box> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="HLilNT4gNLs4IVlNCNXMHFDoLQwJGQxV0" Subject: Re: [Qemu-devel] [PATCH v2] ppc / sparc: Add a tester for checking whether OpenBIOS runs successfully List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: David Gibson Cc: agraf@suse.de, Mark Cave-Ayland , Markus Armbruster , qemu-devel@nongnu.org, blauwirbel@gmail.com, qemu-ppc@nongnu.org, Artyom Tarasenko , Richard Henderson This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --HLilNT4gNLs4IVlNCNXMHFDoLQwJGQxV0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 17.06.2016 08:07, David Gibson wrote: > On Wed, Jun 15, 2016 at 01:10:18PM +1000, David Gibson wrote: >> On Tue, Jun 14, 2016 at 03:57:56PM +0200, Thomas Huth wrote: >>> Since the mac99 and g3beige PowerPC machines recently broke without >>> being noticed, it would be good to have a tester for "make check" >>> that detects such issues immediately. A simple way to test the firmwa= re >>> of these machines is to use the "-prom-env" parameter of QEMU. This >>> parameter can be used to put some Forth code into the 'boot-command' >>> firmware variable which then can signal success to the tester by >>> writing a magic value to a known memory location. And since some of t= he >>> Sparc machines are also using OpenBIOS, they are now tested with this= >>> prom-env-tester, too. >>> >>> Reviewed-by: Markus Armbruster >>> Signed-off-by: Thomas Huth >>> --- >>> v2: Removed unnecessary include statements (as suggested by Markus) >> >> Beautiful, I've applied this to ppc-for-2.7, assuming I don't get an >> objection to taking this through my tree. >=20 > Ugh.. turns out this fails on sparc64 target on a 32-bit x86 host. > Specifically it trips the tcg_abort() at the end of tcg_reg_alloc() > (tcg/tcg.c). Looks like the test is already doing its job well ;-) > I'm reasonably confident this is a pre-existing bug, just triggered by > this test, but in the interests of getting this up and running on the > platforms where it is working, I've disabled the testcase on sparc64 > for now. Ok, makes sense to disable this for now. I also just compiled the QEMU sources with -m32, and for me it is also failing when I run QEMU manually without the test-wrapper - but it's triggering a segfault here instead: $ gdb --args sparc64-softmmu/qemu-system-sparc64 -nographic [...] (gdb) r Starting program: qemu-build32/sparc64-softmmu/qemu-system-sparc64 -nogra= phic [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". [New Thread 0xf7a82b40 (LWP 4860)] [New Thread 0xf4beab40 (LWP 4861)] OpenBIOS for Sparc64 Inconsistency for register %eax: reg state: _frame: %esp env: %ebp regwptr: %edx xcc: 76892(%ebp) asi: 76896(%ebp) fprs: 77188(%ebp) softint: 77380(%ebp) cc_op: 116(%ebp) psr: 128(%ebp) gsr_1: 77220(%ebp) Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0xf4beab40 (LWP 4861)] 0x5698cd4b in pstrcpy (buf=3D0xf4be9dcc "gsr_1", buf_size=3D64, str=3D0x1=
) at qemu/util/cutils.c:50 50 c =3D *str++; Missing separate debuginfos, use: debuginfo-install glib2-2.42.2-5.el7.i6= 86 glibc-2.17-106.el7_2.6.i686 libgcc-4.8.5-4.el7.i686 libstdc++-4.8.5-4.= el7.i686 pixman-0.32.6-3.el7.i686 zlib-1.2.7-15.el7.i686 (gdb) bt #0 0x5698cd4b in pstrcpy (buf=3D0xf4be9dcc "gsr_1", buf_size=3D64, str=3D= 0x1
) at qemu/util/cutils.c:50 #1 0x5660e916 in tcg_get_arg_str_ptr (s=3D0x56c6bba0 , buf=3D0x= f4be9dcc "gsr_1", buf_size=3D64,=20 ts=3D0x56c6be60 ) at qemu/tcg/tcg.c:939 #2 0x5660ea08 in tcg_get_arg_str_idx (s=3D0x56c6bba0 , buf=3D0x= f4be9dcc "gsr_1", buf_size=3D64, idx=3D10) at qemu/tcg/tcg.c:952 #3 0x56610389 in dump_regs (s=3D0x56c6bba0 ) at qemu/tcg/tcg.c:= 1598 #4 0x56610632 in check_regs (s=3D0x56c6bba0 ) at qemu/tcg/tcg.c= :1654 #5 0x56612731 in tcg_gen_code (s=3D0x56c6bba0 , tb=3D0xf4bf83b4= ) at qemu/tcg/tcg.c:2458 #6 0x56605ef0 in tb_gen_code (cpu=3D0x570ccde0, pc=3D4291974856, cs_base= =3D4291974860, flags=3D7, cflags=3D0) at qemu/translate-all.c:1214 #7 0x56607e6e in tb_find_slow (cpu=3D0x570ccde0, pc=3D4291974856, cs_bas= e=3D4291974860, flags=3D7) at qemu/cpu-exec.c:310 #8 0x56607fe8 in tb_find_fast (cpu=3D0x570ccde0, last_tb=3D0xf4bea084, t= b_exit=3D1) at qemu/cpu-exec.c:339 #9 0x5660880c in cpu_sparc_exec (cpu=3D0x570ccde0) at qemu/cpu-exec.c:62= 5 #10 0x5663be6b in tcg_cpu_exec (cpu=3D0x570ccde0) at qemu/cpus.c:1541 #11 0x5663bf76 in tcg_exec_all () at qemu/cpus.c:1574 #12 0x5663b27b in qemu_tcg_cpu_thread_fn (arg=3D0x570ccde0) at qemu/cpus.= c:1171 #13 0xf7c4ab2c in start_thread () from /lib/libpthread.so.0 #14 0xf7b7d77e in clone () from /lib/libc.so.6 Thomas --HLilNT4gNLs4IVlNCNXMHFDoLQwJGQxV0 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAEBAgAGBQJXY51jAAoJEC7Z13T+cC21RbAP/R3R1SCB4hvqKDeQ8R5MuAil c6huI5TC1pkWwYzWZLfJG4ptUcOxAVW83ZRoX2Uu452AIt9swPqcqvmsG7cCreK5 mywoqvdYo78MiNxlDYlOidgoD52t2OpzgHGe9iPble2Rp3YiD4iY6P1BUZoKXLsm NTypMoJlGIqu63F4ViE6DXokCSRiqG1qKArODGclw6jb7XyEmSixLtn0kYcSfQiQ HqAEhcSf0Ujf3VqtR1FhYjRzak/nQIHV2jCPte+4oY1NMemom51HHtHa2lqAGGYl E0nVmxUaILB2Z9byPCdOEeRH3wxEPz4M9USPQ+ebicNX9mUQVNpmTLqDmnkoX7Ns wuftagFdcoHAh1zPG9DeZwABKtEz5uqFfmodHFarN36u/sd/978OCqCGBZLdnX3T ECM+cMrD6WsAbZW6/IvN7YG8f9vl5TZ1bY4ty5oRhhQmR7UlTk3PFQz6TJjBmBHB WeAiwj8g7I9gBlWZAdI9cyK/5yalGlR5c/Dj8MFN71GQmGlh+VDDAH6Mi1HJfw1W cZmF/JK8tvHNTk0nCdmYcsqz/u4rZrcHqZvOsM3Gcqv+UoS0QKnmGwrU+nK12s+7 cCrQCDRaxy0GQvG58/cGKsnk/IJnmcXxjgqXX26mUtePk2dqznYgnoARSFR43fpr tD2eO1KodcPNJIeZyfab =wE/S -----END PGP SIGNATURE----- --HLilNT4gNLs4IVlNCNXMHFDoLQwJGQxV0--