Received: from eggs.gnu.org ([2001:4830:134:3::10]:38027) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bG604-0002OQ-0u for qemu-devel@nongnu.org; Thu, 23 Jun 2016 10:53:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bG5zz-0006Vx-NW for qemu-devel@nongnu.org; Thu, 23 Jun 2016 10:52:58 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59817) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bG5zz-0006Vk-EV for qemu-devel@nongnu.org; Thu, 23 Jun 2016 10:52:55 -0400 References: <1465915112-29272-1-git-send-email-peter.maydell@linaro.org> <5761178F.60004@huawei.com> <20160615092023.fk2vfowubdk6nhmk@hawk.localdomain> <6f08849a-f76e-31f4-178f-ea67da824e59@redhat.com> From: Laszlo Ersek Message-ID: <5cb3a097-2722-8f2b-a44e-7c04205f8658@redhat.com> Date: Thu, 23 Jun 2016 16:52:52 +0200 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v3 00/20] GICv3 emulation List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Ed Maste Cc: Peter Maydell , QEMU Developers , Ard Biesheuvel On 06/23/16 16:18, Ed Maste wrote: > On 23 June 2016 at 07:36, Laszlo Ersek wrote: >> On 06/22/16 22:53, Peter Maydell wrote: >>> On 22 June 2016 at 19:09, Ed Maste wrote: >>>> On 15 June 2016 at 06:10, Peter Maydell wrote: >>>>> >>>>> A quick scan through http://fxr.watson.org/fxr/source/arm64/arm64/gic_v3.c >>>>> doesn't seem to show it setting the IGROUPR registers anywhere, >>>>> so it probably is a guest bug. (You can use "-d 'trace:gicv3*'" to >>>>> enable the tracepoints for the GIC which would let you check whether >>>>> the guest ever tries to write to the group config registers.) >>>> >>>> Is there a prebuilt QEMU_EFI.fd available somewhere for testing a >>>> FreeBSD change to address this? I've been using the prebuilt ones from >>>> https://wiki.linaro.org/LEG/UEFIforQEMU and the latest one I had did >>>> not start with gic-version=3. >>> >>> Yeah, it looks like the same bug is also present in UEFI itself >>> (it's super popular!). Laszlo, Ard, do you have a prebuilt >>> UEFI binary with Ard's fix? >> >> I just put up one here, in case it's still needed: >> >> http://people.redhat.com/~lersek/82a5e88f-f1e1-42e2-8462-66974c9cbfff/ > > Thank you. I ran your QEMU_EFI.fd with gic_version=3 and UEFI and > FreeBSD start up successfully (as expected, based on the discussion in > this thread). > > It sounds like we'll need to build a hacked UEFI build as Peter > Maydell suggested in order to actually test a FreeBSD fix when we have > it. Ah, sorry, I failed to understand this nuance from the discussion (although I quoted it myself -- sorry I'm not having a great day today). So apparently you need a recent enough firmware binary that *starts* with gicv3, but doesn't configure the gicv3 as otherwise needed, so you can reproduce the FreeBSD bug, and verify the FreeBSD bugfix, while booting with UEFI. Ard's patch has just been committed to upstream edk2 (c7fefb690661 -- ), but I can build a binary for you right before it (at bf57a42a0e2cf1c68e9db2f61c82ce93c806ab07)... http://people.redhat.com/~lersek/82a5e88f-f1e1-42e2-8462-66974c9cbfff/QEMU_EFI.fd.bf57a42a0e2c Thanks Laszlo