From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50587) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bD6bP-0007JB-Jv for qemu-devel@nongnu.org; Wed, 15 Jun 2016 04:55:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bD6bL-00074j-Bm for qemu-devel@nongnu.org; Wed, 15 Jun 2016 04:55:11 -0400 Received: from szxga01-in.huawei.com ([58.251.152.64]:33905) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bD6bK-0006TE-10 for qemu-devel@nongnu.org; Wed, 15 Jun 2016 04:55:07 -0400 Message-ID: <5761178F.60004@huawei.com> Date: Wed, 15 Jun 2016 16:53:35 +0800 From: Shannon Zhao MIME-Version: 1.0 References: <1465915112-29272-1-git-send-email-peter.maydell@linaro.org> In-Reply-To: <1465915112-29272-1-git-send-email-peter.maydell@linaro.org> Content-Type: text/plain; charset="ISO-8859-1" 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: Peter Maydell , qemu-devel@nongnu.org Cc: patches@linaro.org, Shlomo Pongratz , Shlomo Pongratz , Pavel Fedin , Shannon Zhao , Christoffer Dall On 2016/6/14 22:38, Peter Maydell wrote: > This series implements emulation of the GICv3 interrupt controller. > It is based to some extent on previous patches from Shlomo and > Pavel, but the bulk of it has turned out to be new code. (The > combination of changing the underlying data structures, adding > support for TrustZone and implementing proper GICv3 behaviour rather > than borrowing fragments of GICv2 emulation code meant there wasn't > much left to reuse.) I've tried to reflect this in the various > authorship credits on the patches, but please let me know if you > feel I got anything miscredited one way or the other. > > Key points about the GICv3 emulated here: > * "non-legacy" only, ie system registers and affinity routing > * TrustZone is implemented > * no virtualization support > * only the "core" GICv3, so no LPI support (via ITS or otherwise) > * no attempt to work around the Linux guest kernel bug fixed > in commit 7c9b973061b0 (so you need that fix for your guest to > boot with this GICv3) Hi Peter, I have another test with a freebsd guest. When I specify gic-version=3 at the QEMU command line, the guest can't start. But with gic-version=2 it's fine. And if I use gic-version=3 with kvm, the guest boots well too. It hangs with below log: [Bds]=============Begin Load Options Dumping ...============= Driver Options: SysPrep Options: Boot Options: Boot0000: UiApp 0x0109 Boot0001: EFI Internal Shell 0x0001 Boot0002: UEFI Misc Device 0x0001 Boot0003: UEFI Misc Device 2 0x0001 Boot0004: UEFI Misc Device 3 0x0001 Boot0005: UEFI PXEv4 (MAC:525400123456) 0x0001 PlatformRecovery Options: PlatformRecovery0000: Default PlatformRecovery 0x0001 [Bds]=============End Load Options Dumping============= [Bds]BdsWait ...Zzzzzzzzzzzz... [Bds]BdsWait(3)..Zzzz... The QEMU command line is: qemu-system-aarch64 \ -m 4096M -cpu cortex-a57 -M virt,gic-version=3 -smp 1 \ -bios QEMU_EFI.fd -serial telnet::4445,server -nographic \ -drive if=none,file=FreeBSD-11.0-ALPHA3-arm64-aarch64-20160528-r301815.qcow2,id=hd0 \ -device virtio-blk-device,drive=hd0 \ -device virtio-net-device,netdev=net0 \ -netdev user,id=net0 The QEMU_EFI.fd is built on edk2 commit ID 8f88f02 and the disk Image file is downloaded from http://www2.tw.freebsd.org/FreeBSD/snapshots/VM-IMAGES/11.0-ALPHA3/aarch64/20160528/FreeBSD-11.0-ALPHA3-arm64-aarch64-20160528-r301815.qcow2.xz Thanks, -- Shannon