Commit 52e94ea5 authored by Peter Maydell's avatar Peter Maydell
Browse files

Merge remote-tracking branch 'remotes/sstabellini/tags/xen-20170421-v2-tag' into staging



Xen 2017/04/21 + fix

# gpg: Signature made Tue 25 Apr 2017 19:10:37 BST
# gpg:                using RSA key 0x894F8F4870E1AE90
# gpg: Good signature from "Stefano Stabellini <stefano.stabellini@eu.citrix.com>"
# gpg:                 aka "Stefano Stabellini <sstabellini@kernel.org>"
# Primary key fingerprint: D04E 33AB A51F 67BA 07D3  0AEA 894F 8F48 70E1 AE90

* remotes/sstabellini/tags/xen-20170421-v2-tag: (21 commits)
  move xen-mapcache.c to hw/i386/xen/
  move xen-hvm.c to hw/i386/xen/
  move xen-common.c to hw/xen/
  add xen-9p-backend to MAINTAINERS under Xen
  xen/9pfs: build and register Xen 9pfs backend
  xen/9pfs: send responses back to the frontend
  xen/9pfs: implement in/out_iov_from_pdu and vmarshal/vunmarshal
  xen/9pfs: receive requests from the frontend
  xen/9pfs: connect to the frontend
  xen/9pfs: introduce Xen 9pfs backend
  9p: introduce a type for the 9p header
  xen: import ring.h from xen
  configure: use pkg-config for obtaining xen version
  xen: additionally restrict xenforeignmemory operations
  xen: use libxendevice model to restrict operations
  xen: use 5 digit xen versions
  xen: use libxendevicemodel when available
  configure: detect presence of libxendevicemodel
  xen: create wrappers for all other uses of xc_hvm_XXX() functions
  xen: rename xen_modified_memory() to xen_hvm_modified_memory()
  ...

Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
parents fe491fa8 28b99f47
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -327,6 +327,7 @@ L: xen-devel@lists.xenproject.org
S: Supported
F: xen-*
F: */xen*
F: hw/9pfs/xen-9p-backend.c
F: hw/char/xen_console.c
F: hw/display/xenfb.c
F: hw/net/xen_nic.c
+0 −6
Original line number Diff line number Diff line
@@ -149,12 +149,6 @@ obj-y += dump.o
obj-y += migration/ram.o migration/savevm.o
LIBS := $(libs_softmmu) $(LIBS)

# xen support
obj-$(CONFIG_XEN) += xen-common.o
obj-$(CONFIG_XEN_I386) += xen-hvm.o xen-mapcache.o
obj-$(call lnot,$(CONFIG_XEN)) += xen-common-stub.o
obj-$(call lnot,$(CONFIG_XEN_I386)) += xen-hvm-stub.o

# Hardware support
ifeq ($(TARGET_NAME), sparc64)
obj-y += hw/sparc64/
+100 −64
Original line number Diff line number Diff line
@@ -1997,8 +1997,24 @@ fi
# xen probe

if test "$xen" != "no" ; then
  # Check whether Xen library path is specified via --extra-ldflags to avoid
  # overriding this setting with pkg-config output. If not, try pkg-config
  # to obtain all needed flags.

  if ! echo $EXTRA_LDFLAGS | grep tools/libxc > /dev/null && \
     $pkg_config --exists xencontrol ; then
    xen_ctrl_version="$(printf '%d%02d%02d' \
      $($pkg_config --modversion xencontrol | sed 's/\./ /g') )"
    xen=yes
    xen_pc="xencontrol xenstore xenguest xenforeignmemory xengnttab"
    xen_pc="$xen_pc xenevtchn xendevicemodel"
    QEMU_CFLAGS="$QEMU_CFLAGS $($pkg_config --cflags $xen_pc)"
    libs_softmmu="$($pkg_config --libs $xen_pc) $libs_softmmu"
    LDFLAGS="$($pkg_config --libs $xen_pc) $LDFLAGS"
  else

    xen_libs="-lxenstore -lxenctrl -lxenguest"
  xen_stable_libs="-lxenforeignmemory -lxengnttab -lxenevtchn"
    xen_stable_libs="-lxencall -lxenforeignmemory -lxengnttab -lxenevtchn"

    # First we test whether Xen headers and libraries are available.
    # If no, we are done and there is no Xen support.
@@ -2021,6 +2037,25 @@ EOF
    # Xen unstable
    elif
        cat > $TMPC <<EOF &&
#undef XC_WANT_COMPAT_DEVICEMODEL_API
#define __XEN_TOOLS__
#include <xendevicemodel.h>
int main(void) {
  xendevicemodel_handle *xd;

  xd = xendevicemodel_open(0, 0);
  xendevicemodel_close(xd);

  return 0;
}
EOF
        compile_prog "" "$xen_libs -lxendevicemodel $xen_stable_libs"
      then
      xen_stable_libs="-lxendevicemodel $xen_stable_libs"
      xen_ctrl_version=40900
      xen=yes
    elif
        cat > $TMPC <<EOF &&
/*
 * If we have stable libs the we don't want the libxc compat
 * layers, regardless of what CFLAGS we may have been given.
@@ -2072,7 +2107,7 @@ int main(void) {
EOF
        compile_prog "" "$xen_libs $xen_stable_libs"
      then
    xen_ctrl_version=480
      xen_ctrl_version=40800
      xen=yes
    elif
        cat > $TMPC <<EOF &&
@@ -2123,7 +2158,7 @@ int main(void) {
EOF
        compile_prog "" "$xen_libs $xen_stable_libs"
      then
    xen_ctrl_version=471
      xen_ctrl_version=40701
      xen=yes
    elif
        cat > $TMPC <<EOF &&
@@ -2138,7 +2173,7 @@ int main(void) {
EOF
        compile_prog "" "$xen_libs"
      then
    xen_ctrl_version=470
      xen_ctrl_version=40700
      xen=yes

    # Xen 4.6
@@ -2166,7 +2201,7 @@ int main(void) {
EOF
        compile_prog "" "$xen_libs"
      then
    xen_ctrl_version=460
      xen_ctrl_version=40600
      xen=yes

    # Xen 4.5
@@ -2193,7 +2228,7 @@ int main(void) {
EOF
        compile_prog "" "$xen_libs"
      then
    xen_ctrl_version=450
      xen_ctrl_version=40500
      xen=yes

    elif
@@ -2218,7 +2253,7 @@ int main(void) {
EOF
        compile_prog "" "$xen_libs"
      then
    xen_ctrl_version=420
      xen_ctrl_version=40200
      xen=yes

    else
@@ -2230,12 +2265,13 @@ EOF
    fi

    if test "$xen" = yes; then
    if test $xen_ctrl_version -ge 471  ; then
      if test $xen_ctrl_version -ge 40701  ; then
        libs_softmmu="$xen_stable_libs $libs_softmmu"
      fi
      libs_softmmu="$xen_libs $libs_softmmu"
    fi
  fi
fi

if test "$xen_pci_passthrough" != "no"; then
  if test "$xen" = "yes" && test "$linux" = "yes"; then
+0 −1
Original line number Diff line number Diff line
@@ -39,7 +39,6 @@ CONFIG_TPM_TIS=$(CONFIG_TPM)
CONFIG_MC146818RTC=y
CONFIG_PCI_PIIX=y
CONFIG_WDT_IB700=y
CONFIG_XEN_I386=$(CONFIG_XEN)
CONFIG_ISA_DEBUG=y
CONFIG_ISA_TESTDEV=y
CONFIG_VMPORT=y
+0 −1
Original line number Diff line number Diff line
@@ -39,7 +39,6 @@ CONFIG_TPM_TIS=$(CONFIG_TPM)
CONFIG_MC146818RTC=y
CONFIG_PCI_PIIX=y
CONFIG_WDT_IB700=y
CONFIG_XEN_I386=$(CONFIG_XEN)
CONFIG_ISA_DEBUG=y
CONFIG_ISA_TESTDEV=y
CONFIG_VMPORT=y
Loading