Re: [Qemu-devel] [PATCH v3 0/4] xen: don't save/restore the physmap on VM save/restore
Hi, This series seems to have some coding style problems. See output below for more information: Message-id: 1499726403-10129-1-git-send-email-igor.druzhi...@citrix.com Type: series Subject: [Qemu-devel] [PATCH v3 0/4] xen: don't save/restore the physmap on VM save/restore === 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 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' 893068b xen: don't use xenstore to save/restore physmap anymore bab7b78 xen/mapcache: introduce xen_replace_cache_entry() b1ed857 xen/mapcache: add an ability to create dummy mappings f0688e9 xen: move physmap saving into a separate function === OUTPUT BEGIN === Checking PATCH 1/4: xen: move physmap saving into a separate function... Checking PATCH 2/4: xen/mapcache: add an ability to create dummy mappings... Checking PATCH 3/4: xen/mapcache: introduce xen_replace_cache_entry()... ERROR: space required before the open parenthesis '(' #180: FILE: hw/i386/xen/xen-mapcache.c:541: +if(!test_bits(address_offset >> XC_PAGE_SHIFT, total: 1 errors, 0 warnings, 205 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 4/4: xen: don't use xenstore to save/restore physmap anymore... ERROR: space prohibited between function name and open parenthesis '(' #48: FILE: hw/i386/xen/xen-hvm.c:380: +physmap = g_malloc(sizeof (XenPhysmap)); total: 1 errors, 0 warnings, 120 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. === OUTPUT END === Test command exited with code: 1 --- Email generated automatically by Patchew [http://patchew.org/]. Please send your feedback to patchew-de...@freelists.org
Re: [Qemu-devel] [PATCH v3 0/4] xen: don't save/restore the physmap on VM save/restore
Hi, This series failed build test on s390x host. Please find the details below. Type: series Subject: [Qemu-devel] [PATCH v3 0/4] xen: don't save/restore the physmap on VM save/restore Message-id: 1499726403-10129-1-git-send-email-igor.druzhi...@citrix.com === TEST SCRIPT BEGIN === #!/bin/bash # Testing script will be invoked under the git checkout with # HEAD pointing to a commit that has the patches applied on top of "base" # branch set -e echo "=== ENV ===" env echo "=== PACKAGES ===" rpm -qa echo "=== TEST BEGIN ===" CC=$HOME/bin/cc INSTALL=$PWD/install BUILD=$PWD/build echo -n "Using CC: " realpath $CC mkdir -p $BUILD $INSTALL SRC=$PWD cd $BUILD $SRC/configure --cc=$CC --prefix=$INSTALL make -j4 # XXX: we need reliable clean up # make check -j4 V=1 make install === TEST SCRIPT END === Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384 Switched to a new branch 'test' 893068b xen: don't use xenstore to save/restore physmap anymore bab7b78 xen/mapcache: introduce xen_replace_cache_entry() b1ed857 xen/mapcache: add an ability to create dummy mappings f0688e9 xen: move physmap saving into a separate function === OUTPUT BEGIN === === ENV === XDG_SESSION_ID=146112 SHELL=/bin/sh USER=fam PATCHEW=/home/fam/patchew/patchew-cli -s http://patchew.org --nodebug PATH=/usr/bin:/bin PWD=/var/tmp/patchew-tester-tmp-_hhpulql/src LANG=en_US.UTF-8 HOME=/home/fam SHLVL=2 LOGNAME=fam DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1012/bus XDG_RUNTIME_DIR=/run/user/1012 _=/usr/bin/env === PACKAGES === gpg-pubkey-873529b8-54e386ff xz-libs-5.2.2-2.fc24.s390x libxshmfence-1.2-3.fc24.s390x giflib-4.1.6-15.fc24.s390x trousers-lib-0.3.13-6.fc24.s390x ncurses-base-6.0-6.20160709.fc25.noarch gmp-6.1.1-1.fc25.s390x libidn-1.33-1.fc25.s390x slang-2.3.0-7.fc25.s390x libsemanage-2.5-8.fc25.s390x pkgconfig-0.29.1-1.fc25.s390x alsa-lib-1.1.1-2.fc25.s390x yum-metadata-parser-1.1.4-17.fc25.s390x python3-slip-dbus-0.6.4-4.fc25.noarch python2-cssselect-0.9.2-1.fc25.noarch python-fedora-0.8.0-2.fc25.noarch createrepo_c-libs-0.10.0-6.fc25.s390x initscripts-9.69-1.fc25.s390x wget-1.18-2.fc25.s390x dhcp-client-4.3.5-1.fc25.s390x parted-3.2-21.fc25.s390x flex-2.6.0-3.fc25.s390x colord-libs-1.3.4-1.fc25.s390x python-osbs-client-0.33-3.fc25.noarch perl-Pod-Simple-3.35-1.fc25.noarch python2-simplejson-3.10.0-1.fc25.s390x brltty-5.4-2.fc25.s390x librados2-10.2.4-2.fc25.s390x tcp_wrappers-7.6-83.fc25.s390x libcephfs_jni1-10.2.4-2.fc25.s390x nettle-devel-3.3-1.fc25.s390x bzip2-devel-1.0.6-21.fc25.s390x libuuid-2.28.2-2.fc25.s390x pango-1.40.4-1.fc25.s390x python3-dnf-1.1.10-6.fc25.noarch cryptsetup-libs-1.7.4-1.fc25.s390x texlive-kpathsea-doc-svn41139-33.fc25.1.noarch netpbm-10.77.00-3.fc25.s390x openssh-7.4p1-4.fc25.s390x texlive-kpathsea-bin-svn40473-33.20160520.fc25.1.s390x texlive-graphics-svn41015-33.fc25.1.noarch texlive-dvipdfmx-def-svn40328-33.fc25.1.noarch texlive-mfware-svn40768-33.fc25.1.noarch texlive-texlive-scripts-svn41433-33.fc25.1.noarch texlive-euro-svn22191.1.1-33.fc25.1.noarch texlive-etex-svn37057.0-33.fc25.1.noarch texlive-iftex-svn29654.0.2-33.fc25.1.noarch texlive-palatino-svn31835.0-33.fc25.1.noarch texlive-texlive-docindex-svn41430-33.fc25.1.noarch texlive-xunicode-svn30466.0.981-33.fc25.1.noarch texlive-koma-script-svn41508-33.fc25.1.noarch texlive-pst-grad-svn15878.1.06-33.fc25.1.noarch texlive-pst-blur-svn15878.2.0-33.fc25.1.noarch texlive-jknapltx-svn19440.0-33.fc25.1.noarch netpbm-progs-10.77.00-3.fc25.s390x texinfo-6.1-4.fc25.s390x openssl-devel-1.0.2k-1.fc25.s390x python2-sssdconfig-1.15.2-1.fc25.noarch gdk-pixbuf2-2.36.6-1.fc25.s390x mesa-libEGL-13.0.4-3.fc25.s390x pcre-cpp-8.40-6.fc25.s390x pcre-utf16-8.40-6.fc25.s390x glusterfs-extra-xlators-3.10.1-1.fc25.s390x mesa-libGL-devel-13.0.4-3.fc25.s390x nss-devel-3.29.3-1.1.fc25.s390x libaio-0.3.110-6.fc24.s390x libfontenc-1.1.3-3.fc24.s390x lzo-2.08-8.fc24.s390x isl-0.14-5.fc24.s390x libXau-1.0.8-6.fc24.s390x linux-atm-libs-2.5.1-14.fc24.s390x libXext-1.3.3-4.fc24.s390x libXxf86vm-1.1.4-3.fc24.s390x bison-3.0.4-4.fc24.s390x perl-srpm-macros-1-20.fc25.noarch gawk-4.1.3-8.fc25.s390x libwayland-client-1.12.0-1.fc25.s390x perl-Exporter-5.72-366.fc25.noarch perl-version-0.99.17-1.fc25.s390x fftw-libs-double-3.3.5-3.fc25.s390x libssh2-1.8.0-1.fc25.s390x ModemManager-glib-1.6.4-1.fc25.s390x newt-python3-0.52.19-2.fc25.s390x python-munch-2.0.4-3.fc25.noarch python-bugzilla-1.2.2-4.fc25.noarch libedit-3.1-16.20160618cvs.fc25.s390x python-pycurl-7.43.0-4.fc25.s390x createrepo_c-0.10.0-6.fc25.s390x device-mapper-multipath-libs-0.4.9-83.fc25.s390x yum-3.4.3-510.fc25.noarch dhcp-common-4.3.5-1.fc25.noarch dracut-config-rescue-044-78.fc25.s390x teamd-1.26-1.fc25.s390x mozjs17-17.0.0-16.fc25.s390x libselinux-2.5-13.fc25.s390x libgo-devel-6.3.1-1.fc25.s390x NetworkManager-libnm-1.4.4-3.fc25.s390x python2-pyparsing-2.1.10-1.fc25.noarch cairo-gobject-1.14.8-1.fc25.s390x ethtool-4.8-1.fc25.s390x xorg-x11-proto-devel-7.7-20.fc25.noarch
[Qemu-devel] [PATCH v3 0/4] xen: don't save/restore the physmap on VM save/restore
Saving/restoring the physmap to/from xenstore was introduced to QEMU majorly in order to cover up the VRAM region restore issue. The sequence of restore operations implies that we should know the effective guest VRAM address *before* we have the VRAM region restored (which happens later). Unfortunately, in Xen environment VRAM memory does actually belong to a guest - not QEMU itself - which means the position of this region is unknown beforehand and can't be mapped into QEMU address space immediately. Previously, recreating xenstore keys, holding the physmap, by the toolstack helped to get this information in place at the right moment ready to be consumed by QEMU to map the region properly. But using xenstore for it has certain disadvantages: toolstack needs to be aware of these keys and save/restore them accordingly; accessing xenstore requires extra privileges which hinders QEMU sandboxing. The previous attempt to get rid of that was to remember all the VRAM pointers during QEMU initialization phase and then update them all at once when an actual foreign mapping is established. Unfortunately, this approach worked only for VRAM and only for a predefined set of devices - stdvga and cirrus. QXL and other possible future devices using a moving emulated MMIO region would be equally broken. The new approach leverages xenforeignmemory_map2() call recently introduced in libxenforeignmemory. It allows to create a dummy anonymous mapping for QEMU during its initialization and change it to a real one later during machine state restore. --- Changes in v3: * Patch 3: use dummy flag based checks to gate ram_block_notify_* functions * Patch 3: switch to inline compat function instead of a straight define * Patch 4: add additional XEN_COMPAT_PHYSMAP blocks Changed in v2: * Patch 2: set dummy flag in a new flags field in struct MapCacheEntry * Patch 3: change xen_remap_cache_entry name and signature * Patch 3: gate ram_block_notify_* functions in xen_remap_bucket * Patch 3: rewrite the logic of xen_replace_cache_entry_unlocked to reuse the existing entry instead of allocating a new one * Patch 4: don't use xen_phys_offset_to_gaddr in non-compat mode --- Igor Druzhinin (4): xen: move physmap saving into a separate function xen/mapcache: add an ability to create dummy mappings xen/mapcache: introduce xen_replace_cache_entry() xen: don't use xenstore to save/restore physmap anymore configure | 18 +++ hw/i386/xen/xen-hvm.c | 105 +++- hw/i386/xen/xen-mapcache.c| 121 ++ include/hw/xen/xen_common.h | 15 ++ include/sysemu/xen-mapcache.h | 11 +++- 5 files changed, 222 insertions(+), 48 deletions(-) -- 2.7.4