Received: from eggs.gnu.org ([2001:4830:134:3::10]:41779) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bmLWR-0008IJ-9C for qemu-devel@nongnu.org; Tue, 20 Sep 2016 09:55:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bmLWL-0000dl-CV for qemu-devel@nongnu.org; Tue, 20 Sep 2016 09:55:42 -0400 Received: from indium.canonical.com ([91.189.90.7]:35735) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bmLWK-0000dM-VX for qemu-devel@nongnu.org; Tue, 20 Sep 2016 09:55:37 -0400 Received: from loganberry.canonical.com ([91.189.90.37]) by indium.canonical.com with esmtp (Exim 4.76 #1 (Debian)) id 1bmLWK-0005ui-CI for ; Tue, 20 Sep 2016 13:55:36 +0000 Received: from loganberry.canonical.com (localhost [127.0.0.1]) by loganberry.canonical.com (Postfix) with ESMTP id 47B232E80C1 for ; Tue, 20 Sep 2016 13:55:36 +0000 (UTC) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Date: Tue, 20 Sep 2016 13:47:58 -0000 From: Peter Maydell Reply-To: Bug 1625295 <1625295@bugs.launchpad.net> Sender: bounces@canonical.com References: <20160919174005.12059.42887.malonedeb@gac.canonical.com> Message-Id: <20160920134758.6513.7111.malone@gac.canonical.com> Errors-To: bounces@canonical.com Subject: [Qemu-devel] [Bug 1625295] Re: qemu-arm dies with libarmmem inside ld.so.preload List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org This turns out to be nothing to do with setend. We're doing something wrong= emulating the following nasty hack: https://github.com/bavison/arm-mem/blob/master/architecture.S .arm architecture: sub pc, pc, #1 @ is an interworking branch on ARMv7, not ARMv6 and a1, a4, a1 @ second word interpreted as 'B .+0xA' if Thumb mov a1, #6 bx lr .thumb mov a1, #7 bx lr so after the 'sub pc, pc, #1' (which in my debug trace is at address 0xb6f086dc) QEMU next tries to execute from 0xb6f086e2 in ARM mode, which is neither of the two expected outcomes. As it happens we hit an undefined instruction pretty much immediately afterwards: 0xb6f086e2: 0006e003 andeq lr, r6, r3 0xb6f086e6: ff1ee3a0 undefined instruction 0xff1ee3a0 -- = You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1625295 Title: qemu-arm dies with libarmmem inside ld.so.preload Status in QEMU: New Bug description: When running raspbian inside qemu,the user has to first comment out the following line from /etc/ld.so.conf: /usr/lib/arm-linux-gnueabihf/libarmmem.so = Will future qemus will be able to work without changine /etc/ld.so.conf ? To manage notifications about this bug go to: https://bugs.launchpad.net/qemu/+bug/1625295/+subscriptions