Re: [Qemu-devel] [PATCH v15 00/10] Add ARMv8 RAS virtualization support in QEMU
Hi, This series failed docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 1541672153-15529-1-git-send-email-gengdong...@huawei.com Subject: [Qemu-devel] [PATCH v15 00/10] Add ARMv8 RAS virtualization support in QEMU === TEST SCRIPT BEGIN === #!/bin/bash time make docker-test-quick@centos7 SHOW_ENV=1 J=8 === TEST SCRIPT END === Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384 Switched to a new branch 'test' ea6f559ebb target-arm: kvm64: handle SIGBUS signal from kernel or KVM f7559fdd5e hw/arm/virt: Add RAS platform version for migration 5d5ce7694f target-arm: kvm64: inject synchronous External Abort 5d4a5f1e8e KVM: Move related hwpoison page functions to accel/kvm/ folder cfe8041c05 docs: APEI GHES generation and CPER record description 9cbe3a1625 ACPI: Add APEI GHES table generation and CPER record support f50bae0c92 acpi: add build_append_ghes_generic_status() helper for Generic Error Status Block 5202c7810c acpi: add build_append_ghes_generic_data() helper for Generic Error Data Entry d56660774b acpi: add build_append_ghes_notify() helper for Hardware Error Notification f62584522a ACPI: add some GHES structures and macros definition === OUTPUT BEGIN === BUILD centos7 make[1]: Entering directory '/var/tmp/patchew-tester-tmp-o0v_u04j/src' GEN /var/tmp/patchew-tester-tmp-o0v_u04j/src/docker-src.2018-11-08-17.37.09.13041/qemu.tar Cloning into '/var/tmp/patchew-tester-tmp-o0v_u04j/src/docker-src.2018-11-08-17.37.09.13041/qemu.tar.vroot'... done. Your branch is up-to-date with 'origin/test'. Submodule 'dtc' (git://git.qemu-project.org/dtc.git) registered for path 'dtc' Cloning into '/var/tmp/patchew-tester-tmp-o0v_u04j/src/docker-src.2018-11-08-17.37.09.13041/qemu.tar.vroot/dtc'... Submodule path 'dtc': checked out '88f18909db731a627456f26d779445f84e449536' Submodule 'ui/keycodemapdb' (git://git.qemu.org/keycodemapdb.git) registered for path 'ui/keycodemapdb' Cloning into '/var/tmp/patchew-tester-tmp-o0v_u04j/src/docker-src.2018-11-08-17.37.09.13041/qemu.tar.vroot/ui/keycodemapdb'... Submodule path 'ui/keycodemapdb': checked out '6b3d716e2b6472eb7189d3220552280ef3d832ce' COPYRUNNER RUN test-quick in qemu:centos7 Packages installed: SDL-devel-1.2.15-14.el7.x86_64 bison-3.0.4-1.el7.x86_64 bzip2-1.0.6-13.el7.x86_64 bzip2-devel-1.0.6-13.el7.x86_64 ccache-3.3.4-1.el7.x86_64 csnappy-devel-0-6.20150729gitd7bc683.el7.x86_64 flex-2.5.37-3.el7.x86_64 gcc-4.8.5-28.el7_5.1.x86_64 gettext-0.19.8.1-2.el7.x86_64 git-1.8.3.1-14.el7_5.x86_64 glib2-devel-2.54.2-2.el7.x86_64 libaio-devel-0.3.109-13.el7.x86_64 libepoxy-devel-1.3.1-2.el7_5.x86_64 libfdt-devel-1.4.6-1.el7.x86_64 lzo-devel-2.06-8.el7.x86_64 make-3.82-23.el7.x86_64 mesa-libEGL-devel-17.2.3-8.20171019.el7.x86_64 mesa-libgbm-devel-17.2.3-8.20171019.el7.x86_64 nettle-devel-2.7.1-8.el7.x86_64 package g++ is not installed package librdmacm-devel is not installed pixman-devel-0.34.0-1.el7.x86_64 spice-glib-devel-0.34-3.el7_5.1.x86_64 spice-server-devel-0.14.0-2.el7_5.4.x86_64 tar-1.26-34.el7.x86_64 vte-devel-0.28.2-10.el7.x86_64 xen-devel-4.6.6-12.el7.x86_64 zlib-devel-1.2.7-17.el7.x86_64 Environment variables: PACKAGES=bison bzip2 bzip2-devel ccache csnappy-devel flex g++ gcc gettext git glib2-devel libaio-devel libepoxy-devel libfdt-devel librdmacm-devel lzo-devel make mesa-libEGL-devel mesa-libgbm-devel nettle-devel pixman-devel SDL-devel spice-glib-devel spice-server-devel tar vte-devel xen-devel zlib-devel HOSTNAME=f4d1f67e0bad MAKEFLAGS= -j8 J=8 CCACHE_DIR=/var/tmp/ccache EXTRA_CONFIGURE_OPTS= V= SHOW_ENV=1 PATH=/usr/lib/ccache:/usr/lib64/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin PWD=/ TARGET_LIST= SHLVL=1 HOME=/home/patchew TEST_DIR=/tmp/qemu-test FEATURES= dtc DEBUG= _=/usr/bin/env Configure options: --enable-werror --target-list=x86_64-softmmu,aarch64-softmmu --prefix=/tmp/qemu-test/install No C++ compiler available; disabling C++ specific optional code Install prefix/tmp/qemu-test/install BIOS directory/tmp/qemu-test/install/share/qemu firmware path /tmp/qemu-test/install/share/qemu-firmware binary directory /tmp/qemu-test/install/bin library directory /tmp/qemu-test/install/lib module directory /tmp/qemu-test/install/lib/qemu libexec directory /tmp/qemu-test/install/libexec include directory /tmp/qemu-test/install/include config directory /tmp/qemu-test/install/etc local state directory /tmp/qemu-test/install/var Manual directory /tmp/qemu-test/install/share/man ELF interp prefix /usr/gnemul/qemu-%M Source path /tmp/qemu-test/src GIT binarygit GIT submodules C compilercc Host C compiler cc C++ compiler Objective-C compiler cc ARFLAGS rv CFLAGS-O2 -U_FORTIFY_SOURCE
Re: [Qemu-devel] [PATCH v15 00/10] Add ARMv8 RAS virtualization support in QEMU
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 1541672153-15529-1-git-send-email-gengdong...@huawei.com Subject: [Qemu-devel] [PATCH v15 00/10] Add ARMv8 RAS virtualization support in QEMU === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log --oneline $BASE.. | wc -l) failed=0 git config --local diff.renamelimit 0 git config --local diff.renames True git config --local diff.algorithm histogram commits="$(git log --format=%H --reverse $BASE..)" for c in $commits; do echo "Checking PATCH $n/$total: $(git log -n 1 --format=%s $c)..." if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then failed=1 echo fi n=$((n+1)) done exit $failed === TEST SCRIPT END === Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384 Switched to a new branch 'test' ea6f559ebb target-arm: kvm64: handle SIGBUS signal from kernel or KVM f7559fdd5e hw/arm/virt: Add RAS platform version for migration 5d5ce7694f target-arm: kvm64: inject synchronous External Abort 5d4a5f1e8e KVM: Move related hwpoison page functions to accel/kvm/ folder cfe8041c05 docs: APEI GHES generation and CPER record description 9cbe3a1625 ACPI: Add APEI GHES table generation and CPER record support f50bae0c92 acpi: add build_append_ghes_generic_status() helper for Generic Error Status Block 5202c7810c acpi: add build_append_ghes_generic_data() helper for Generic Error Data Entry d56660774b acpi: add build_append_ghes_notify() helper for Hardware Error Notification f62584522a ACPI: add some GHES structures and macros definition === OUTPUT BEGIN === Checking PATCH 1/10: ACPI: add some GHES structures and macros definition... Checking PATCH 2/10: acpi: add build_append_ghes_notify() helper for Hardware Error Notification... Checking PATCH 3/10: acpi: add build_append_ghes_generic_data() helper for Generic Error Data Entry... Checking PATCH 4/10: acpi: add build_append_ghes_generic_status() helper for Generic Error Status Block... Checking PATCH 5/10: ACPI: Add APEI GHES table generation and CPER record support... WARNING: added, moved or deleted file(s), does MAINTAINERS need updating? #46: new file mode 100644 WARNING: line over 80 characters #106: FILE: hw/acpi/acpi_ghes.c:56: +build_append_int_noprefix((void *)hardware_errors, 1, GHES_ADDRESS_SIZE); WARNING: line over 80 characters #134: FILE: hw/acpi/acpi_ghes.c:84: +build_append_int_noprefix(table_data, cpu_to_le16(i), 2); /* source id */ WARNING: line over 80 characters #135: FILE: hw/acpi/acpi_ghes.c:85: +build_append_int_noprefix(table_data, 0x, 2); /* related source id */ WARNING: line over 80 characters #148: FILE: hw/acpi/acpi_ghes.c:98: +build_append_gas(table_data, AML_SYSTEM_MEMORY, 0x40, 0, 4 /* QWord access */, 0); WARNING: line over 80 characters #172: FILE: hw/acpi/acpi_ghes.c:122: +build_append_gas(table_data, AML_SYSTEM_MEMORY, 0x40, 0, 4 /* QWord access */, 0); ERROR: line over 90 characters #309: FILE: include/hw/acpi/acpi_ghes.h:29: +/* The size of Address field in Generic Address Structure, ACPI 2.0/3.0: 5.2.3.1 Generic Address total: 1 errors, 6 warnings, 311 lines checked Your patch has style problems, please review. If any of these errors are false positives report them to the maintainer, see CHECKPATCH in MAINTAINERS. Checking PATCH 6/10: docs: APEI GHES generation and CPER record description... WARNING: added, moved or deleted file(s), does MAINTAINERS need updating? #14: new file mode 100644 total: 0 errors, 1 warnings, 97 lines checked Your patch has style problems, please review. If any of these errors are false positives report them to the maintainer, see CHECKPATCH in MAINTAINERS. Checking PATCH 7/10: KVM: Move related hwpoison page functions to accel/kvm/ folder... Checking PATCH 8/10: target-arm: kvm64: inject synchronous External Abort... Checking PATCH 9/10: hw/arm/virt: Add RAS platform version for migration... Checking PATCH 10/10: target-arm: kvm64: handle SIGBUS signal from kernel or KVM... WARNING: line over 80 characters #80: FILE: hw/acpi/acpi_ghes.c:68: +current_block_length = sizeof(AcpiGenericErrorStatus) + le32_to_cpu(data_length); WARNING: line over 80 characters #89: FILE: hw/acpi/acpi_ghes.c:77: +if ((data_length + sizeof(AcpiGenericErrorStatus)) > GHES_MAX_RAW_DATA_LENGTH) { WARNING: line over 80 characters #94: FILE: hw/acpi/acpi_ghes.c:82: +build_append_ghes_generic_status(block, cpu_to_le32(ACPI_GEBS_UNCORRECTABLE), 0, 0, WARNING: line over 80 characters #106: FILE: hw/acpi/acpi_ghes.c:94: +cpu_to_le32(ACPI_CPER_SEV_RECOVERABLE), cpu_to_le32(0x300), 0, 0, WARNING: line over 80 characters #107: FILE: hw/acpi/acpi_ghes.c:95: +cpu_to_le32(80)/* the total size of Memory Error Record */, fru_id, total: 0 errors, 5 warnings, 256 lines checked Your patch has style
[Qemu-devel] [PATCH v15 00/10] Add ARMv8 RAS virtualization support in QEMU
In the ARMv8 platform, the CPU error type are synchronous external abort(SEA) and SError Interrupt (SEI). If exception happens to guest, sometimes guest itself do the recovery is better, because host does not know guest's detailed information. For example, if a guest user-space application happen exception, host doe not which application encounter errors. For the ARMv8 SEA/SEI, KVM or host kernel will deliver SIGBUS or use other interface to notify user space. After user space gets the notification, it will record the CPER to guest GHES buffer for guest and inject a exception or IRQ to KVM. In the current implement, if the SIGBUS is BUS_MCEERR_AR, we will treat it as synchronous exception, and use ARMv8 SEA notification type to notify guest after recording CPER for guest; This series patches are based on Qemu 2.12, which have two parts: 1. Generate APEI/GHES table and record CPER for guest in runtime. 2. Handle the SIGBUS signal, record the CPER and fill into guest memory, then according to SIGBUS type(BUS_MCEERR_AR or BUS_MCEERR_AO), using different ACPI notification type to notify guest. Whole solution was suggested by James(james.mo...@arm.com); APEI part solution is suggested by Laszlo(ler...@redhat.com). Shown some discussion in [1]. This series patches have already tested on ARM64 platform with RAS feature enabled: Show the APEI part verification result in [2] Show the BUS_MCEERR_AR SIGBUS handling verification result in [3] --- Change since v14: 1. Remove the BUS_MCEERR_AO handling logic because this asynchronous signal was masked by main thread 2. Address some Igor Mammedov's comments(ACPI part) 1) change the comments for the enum AcpiHestNotifyType definition and remove ditto in patch 1 2) change some patch commit messages and separate "APEI GHES table generation" patch to more patches. 3. Address some peter's comments(arm64 Synchronous External Abort injection) 1) change some code notes 2) using arm_current_el() for current EL 2) use the helper functions for those (syn_data_abort_*). Change since v13: 1. Move the patches that set guest ESR and inject virtual SError out of this series 2. Clean and optimize the APEI part patches 3. Update the commit messages and add some comments for the code Change since v12: 1. Address Paolo's comments to move HWPoisonPage definition to accel/kvm/kvm-all.c 2. Only call kvm_cpu_synchronize_state() when get the BUS_MCEERR_AR signal 3. Only add and enable GPIO-Signal and ARMv8 SEA two hardware error sources 4. Address Michael's comments to not sync SPDX from Linux kernel header file Change since v11: Address James's comments(james.mo...@arm.com) 1. Check whether KVM has the capability to to set ESR instead of detecting host CPU RAS capability 2. For SIGBUS_MCEERR_AR SIGBUS, use Synchronous-External-Abort(SEA) notification type for SIGBUS_MCEERR_AO SIGBUS, use GPIO-Signal notification Address Shannon's comments(for ACPI part): 1. Unify hest_ghes.c and hest_ghes.h license declaration 2. Remove unnecessary including "qmp-commands.h" in hest_ghes.c 3. Unconditionally add guest APEI table based on James's comments(james.mo...@arm.com) 4. Add a option to virt machine for migration compatibility. On new virt machine it's on by default while off for old ones, we enabled it since 2.12 5. Refer to the ACPI spec version which introduces Hardware Error Notification first time 6. Add ACPI_HEST_NOTIFY_RESERVED notification type Address Igor's comments(for ACPI part): 1. Add doc patch first which will describe how it's supposed to work between QEMU/firmware/guest OS with expected flows. 2. Move APEI diagrams into doc/spec patch 3. Remove redundant g_malloc in ghes_record_cper() 4. Use build_append_int_noprefix() API to compose whole error status block and whole APEI table, and try to get rid of most structures in patch 1, as they will be left unused after that 5. Reuse something like https://github.com/imammedo/qemu/commit/3d2fd6d13a3ea298d2ee814835495ce6241d085c to build GAS 6. Remove much offsetof() in the function 7. Build independent tables first and only then build dependent tables passing to it pointers to previously build table if necessary. 8. Redefine macro GHES_ACPI_HEST_NOTIFY_RESERVED to ACPI_HEST_ERROR_SOURCE_COUNT to avoid confusion Address Peter Maydell's comments 1. linux-headers is done as a patch of their own created using scripts/update-linux-headers.sh run against a mainline kernel tree 2. Tested whether this patchset builds OK on aarch32 3. Abstract Hwpoison page adding code out properly into a cpu-independent source file from target/i386/kvm.c, such as kvm-all.c 4. Add doc-comment formatted documentation comment for new globally-visible function prototype in a header --- [1]: https://lkml.org/lkml/2017/2/27/246 https://patchwork.kernel.org/patch/9633105/ https://patchwork.kernel.org/patch/9925227/ [2]: Note: the UEFI(QEMU_EFI.fd) is needed if guest want to use ACPI