1. 25 9月, 2015 7 次提交
    • P
      Merge remote-tracking branch 'remotes/weil/tags/pull-wxx-20150924' into staging · 8a47d575
      Peter Maydell 提交于
      wxx patch queue
      
      # gpg: Signature made Thu 24 Sep 2015 20:24:50 BST using RSA key ID 677450AD
      # gpg: Good signature from "Stefan Weil <sw@weilnetz.de>"
      # gpg:                 aka "Stefan Weil <stefan.weil@weilnetz.de>"
      # gpg:                 aka "Stefan Weil <stefan.weil@bib.uni-mannheim.de>"
      # gpg: WARNING: This key is not certified with sufficiently trusted signatures!
      # gpg:          It is not certain that the signature belongs to the owner.
      # Primary key fingerprint: 4923 6FEA 75C9 5D69 8EC2  B78A E08C 21D5 6774 50AD
      
      * remotes/weil/tags/pull-wxx-20150924:
        oslib-win32: only provide localtime_r/gmtime_r if missing
        gtk: avoid redefining _WIN32_WINNT macro
        qemu-thread: add a fast path to the Win32 QemuEvent
        slirp: Fix non blocking connect for w32
        nsis: Add QEMU version information to Windows registry
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      8a47d575
    • D
      oslib-win32: only provide localtime_r/gmtime_r if missing · 4d9310f4
      Daniel P. Berrange 提交于
      The oslib-win32 file currently provides a localtime_r and
      gmtime_r replacement unconditionally. Some versions of
      Mingw-w64 would provide crude macros for localtime_r/gmtime_r
      which QEMU takes care to disable. Latest versions of Mingw-w64
      now provide actual functions for localtime_r/gmtime_r, but
      with a twist that you have to include unistd.h or pthread.h
      before including time.h.  By luck some files in QEMU have
      such an include order, resulting in compile errors:
      
        CC    util/osdep.o
      In file included from include/qemu-common.h:48:0,
                       from util/osdep.c:48:
      include/sysemu/os-win32.h:77:12: error: redundant redeclaration of 'gmtime_r' [-Werror=redundant-decls]
       struct tm *gmtime_r(const time_t *timep, struct tm *result);
                  ^
      In file included from include/qemu-common.h:35:0,
                       from util/osdep.c:48:
      /usr/i686-w64-mingw32/sys-root/mingw/include/time.h:272:107: note: previous definition of 'gmtime_r' was here
      In file included from include/qemu-common.h:48:0,
                       from util/osdep.c:48:
      include/sysemu/os-win32.h:79:12: error: redundant redeclaration of 'localtime_r' [-Werror=redundant-decls]
       struct tm *localtime_r(const time_t *timep, struct tm *result);
                  ^
      In file included from include/qemu-common.h:35:0,
                       from util/osdep.c:48:
      /usr/i686-w64-mingw32/sys-root/mingw/include/time.h:269:107: note: previous definition of 'localtime_r' was here
      
      This change adds a configure test to see if localtime_r
      exits, and only enables the QEMU impl if missing. We also
      re-arrange qemu-common.h try attempt to guarantee that all
      source files get unistd.h before time.h and thus see the
      localtime_r/gmtime_r defs.
      
      [sw: Use "official" spellings for Mingw-w64, MinGW in comments.]
      [sw: Terminate sentences with a dot in comments.]
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      Reviewed-by: NDenis V. Lunev <den@openvz.org>
      Signed-off-by: NStefan Weil <sw@weilnetz.de>
      4d9310f4
    • D
      gtk: avoid redefining _WIN32_WINNT macro · c8f3f17c
      Daniel P. Berrange 提交于
      When building for Mingw64 target on Fedora 22 a warning
      is issued about _WIN32_WINNT being redefined.
      
      In file included from ui/gtk.c:40:0:
      include/ui/gtk.h:5:0: warning: "_WIN32_WINNT" redefined
       # define _WIN32_WINNT 0x0601 /* needed to get definition of MAPVK_VK_TO_VSC */
        ^
      In file included from /usr/i686-w64-mingw32/sys-root/mingw/include/crtdefs.h:10:0,
                       from /usr/i686-w64-mingw32/sys-root/mingw/include/stdio.h:9,
                       from /home/berrange/src/virt/qemu/include/qemu/fprintf-fn.h:12,
                       from /home/berrange/src/virt/qemu/include/qemu-common.h:18,
                       from ui/gtk.c:37:
      /usr/i686-w64-mingw32/sys-root/mingw/include/_mingw.h:225:0: note: this is the location of the previous definition
       #define _WIN32_WINNT 0x502
       ^
      
      Rather than try to get MAPVK_VK_TO_VSC defined indirectly
      by defining _WIN32_WINNT, instead just define it explicitly
      if missing.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      Signed-off-by: NStefan Weil <sw@weilnetz.de>
      Acked-by: NPaolo Bonzini <pbonzini@redhat.com>
      c8f3f17c
    • P
      qemu-thread: add a fast path to the Win32 QemuEvent · 7c9b2bf6
      Paolo Bonzini 提交于
      QemuEvents are used heavily by call_rcu.  We do not want them to be slow,
      but the current implementation does a kernel call on every invocation
      of qemu_event_* and won't cut it.
      
      So, wrap a Win32 manual-reset event with a fast userspace path.  The
      states and transitions are the same as for the futex and mutex/condvar
      implementations, but the slow path is different of course.  The idea
      is to reset the Win32 event lazily, as part of a test-reset-test-wait
      sequence.  Such a sequence is, indeed, how QemuEvents are used by
      RCU and other subsystems!
      
      The patch includes a formal model of the algorithm.
      Tested-by: NStefan Weil <sw@weilnetz.de>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NStefan Weil <sw@weilnetz.de>
      7c9b2bf6
    • S
      slirp: Fix non blocking connect for w32 · a246a016
      Stefan Weil 提交于
      Signed-off-by: NStefan Weil <sw@weilnetz.de>
      a246a016
    • S
      nsis: Add QEMU version information to Windows registry · 805d8a67
      Stefan Weil 提交于
      The uninstall keys include an option key "DisplayVersion" which we set
      now. By default the version value is read from file VERSION, but it is
      also possible to pass VERSION=#.#.# to make.
      Signed-off-by: NStefan Weil <sw@weilnetz.de>
      805d8a67
    • P
      Merge remote-tracking branch 'remotes/elmarco/tags/rm-libcacard' into staging · 9438fe9e
      Peter Maydell 提交于
      Remove libcacard
      
      # gpg: Signature made Wed 23 Sep 2015 22:37:11 BST using RSA key ID 75969CE5
      # gpg: Good signature from "Marc-André Lureau <marcandre.lureau@redhat.com>"
      # gpg:                 aka "Marc-André Lureau <marcandre.lureau@gmail.com>"
      # gpg: WARNING: This key is not certified with sufficiently trusted signatures!
      # gpg:          It is not certain that the signature belongs to the owner.
      # Primary key fingerprint: 87A9 BD93 3F87 C606 D276  F62D DAE8 E109 7596 9CE5
      
      * remotes/elmarco/tags/rm-libcacard:
        libcacard: use the standalone project
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      9438fe9e
  2. 24 9月, 2015 29 次提交
  3. 23 9月, 2015 4 次提交
    • P
      Merge remote-tracking branch 'remotes/dgibson/tags/spapr-next-20150923' into staging · 684bb577
      Peter Maydell 提交于
      sPAPR Patch Queue: 2015-09-23
      
      Highlights:
          * pseries-2.5 machine type
          * Memory hotplug for "pseries" guests
          * Fixes to the PAPR Dynamic Reconfiguration hotplug code
          * Several PAPR compliance fixes
          * New SLOF with:
              * GPT support
              * Much faster VGA handling
      
      # gpg: Signature made Wed 23 Sep 2015 02:50:10 BST using DSA key ID FDDA6FC6
      # gpg: Good signature from "David Gibson <david@gibson.dropbear.id.au>"
      # gpg: WARNING: This key is not certified with a trusted signature!
      # gpg:          There is no indication that the signature belongs to the owner.
      # Primary key fingerprint: F730 2185 38B4 D13E FD80  34F2 6882 CAC6 FDDA 6FC6
      
      * remotes/dgibson/tags/spapr-next-20150923: (36 commits)
        sPAPR: Enable EEH on VFIO PCI device only
        sPAPR: Revert don't enable EEH on emulated PCI devices
        ppc/spapr: Implement H_RANDOM hypercall in QEMU
        ppc/spapr: Fix buffer overflow in spapr_populate_drconf_memory()
        spapr: Fix default NUMA node allocation for threads
        spapr: Move memory hotplug to RTAS_LOG_V6_HP_ID_DRC_COUNT type
        spapr: Support hotplug by specifying DRC count
        spapr: Revert to memory@XXXX representation for non-hotplugged memory
        spapr: Populate ibm,associativity-lookup-arrays correctly for non-NUMA
        spapr: Provide better error message when slots exceed max allowed
        spapr: Don't allow memory hotplug to memory less nodes
        spapr: Memory hotplug support
        spapr: Make hash table size a factor of maxram_size
        spapr: Support ibm,dynamic-reconfiguration-memory
        spapr: Add LMB DR connectors
        spapr: Use QEMU limit for maximum CPUs number
        spapr: Don't use QOM [*] syntax for DR connectors.
        spapr_drc: use RTAS return codes for methods called by RTAS
        spapr: Initialize hotplug memory address space
        spapr_drc: don't allow 'empty' DRCs to be unisolated or allocated
        ...
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      684bb577
    • G
      sPAPR: Enable EEH on VFIO PCI device only · d76548a9
      Gavin Shan 提交于
      This checks if the PCI device retrieved from the PCI device address
      is VFIO PCI device when enabling EEH functionality. If it's not
      VFIO PCI device, the EEH functonality isn't enabled.
      Signed-off-by: NGavin Shan <gwshan@linux.vnet.ibm.com>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      d76548a9
    • G
      sPAPR: Revert don't enable EEH on emulated PCI devices · 47445c80
      Gavin Shan 提交于
      This reverts commit 7cb18007 ("sPAPR: Don't enable EEH on emulated
      PCI devices") as rtas_ibm_set_eeh_option() isn't the right place
      to check if there has the corresponding PCI device for the input
      address, which can be PE address, not PCI device address.
      Signed-off-by: NGavin Shan <gwshan@linux.vnet.ibm.com>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      47445c80
    • T
      ppc/spapr: Implement H_RANDOM hypercall in QEMU · 4d9392be
      Thomas Huth 提交于
      The PAPR interface defines a hypercall to pass high-quality
      hardware generated random numbers to guests. Recent kernels can
      already provide this hypercall to the guest if the right hardware
      random number generator is available. But in case the user wants
      to use another source like EGD, or QEMU is running with an older
      kernel, we should also have this call in QEMU, so that guests that
      do not support virtio-rng yet can get good random numbers, too.
      
      This patch now adds a new pseudo-device to QEMU that either
      directly provides this hypercall to the guest or is able to
      enable the in-kernel hypercall if available. The in-kernel
      hypercall can be enabled with the use-kvm property, e.g.:
      
       qemu-system-ppc64 -device spapr-rng,use-kvm=true
      
      For handling the hypercall in QEMU instead, a "RngBackend" is
      required since the hypercall should provide "good" random data
      instead of pseudo-random (like from a "simple" library function
      like rand() or g_random_int()). Since there are multiple RngBackends
      available, the user must select an appropriate back-end via the
      "rng" property of the device, e.g.:
      
       qemu-system-ppc64 -object rng-random,filename=/dev/hwrng,id=gid0 \
                         -device spapr-rng,rng=gid0 ...
      
      See http://wiki.qemu-project.org/Features-Done/VirtIORNG for
      other example of specifying RngBackends.
      Signed-off-by: NThomas Huth <thuth@redhat.com>
      Signed-off-by: NDavid Gibson <david@gibson.dropbear.id.au>
      4d9392be