diff options
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Makefile | 26 | ||||
-rw-r--r-- | block/qapi.c | 2 | ||||
-rwxr-xr-x | configure | 5 | ||||
-rw-r--r-- | hw/vfio/pci.c | 4 | ||||
-rw-r--r-- | include/qemu-common.h | 1 | ||||
-rw-r--r-- | include/qemu/cutils.h | 2 | ||||
-rw-r--r-- | include/sysemu/kvm.h | 2 | ||||
-rw-r--r-- | python/qemu/qtest.py | 2 | ||||
-rw-r--r-- | qapi/string-output-visitor.c | 2 | ||||
-rw-r--r-- | qemu-deprecated.texi | 3 | ||||
-rw-r--r-- | qemu-options.hx | 2 | ||||
-rw-r--r-- | target/m68k/fpu_helper.c | 8 | ||||
-rw-r--r-- | tests/acceptance/cpu_queries.py | 3 | ||||
-rw-r--r-- | tests/acceptance/linux_ssh_mips_malta.py | 10 | ||||
-rw-r--r-- | tests/libqtest.c | 2 | ||||
-rw-r--r-- | tests/migration/guestperf/engine.py | 2 | ||||
-rwxr-xr-x | tests/qemu-iotests/172 | 2 | ||||
-rw-r--r-- | util/cacheinfo.c | 23 |
19 files changed, 57 insertions, 45 deletions
diff --git a/.gitignore b/.gitignore index e9bbc006d3..7de868d1ea 100644 --- a/.gitignore +++ b/.gitignore @@ -41,6 +41,7 @@ /qapi/qapi-types-*.[ch] /qapi/qapi-types.[ch] /qapi/qapi-visit-*.[ch] +!/qapi/qapi-visit-core.c /qapi/qapi-visit.[ch] /qapi/qapi-doc.texi /qemu-doc.html @@ -324,8 +324,19 @@ endif endif endif +# Sphinx does not allow building manuals into the same directory as +# the source files, so if we're doing an in-tree QEMU build we must +# build the manuals into a subdirectory (and then install them from +# there for 'make install'). For an out-of-tree build we can just +# use the docs/ subdirectory in the build tree as normal. +ifeq ($(realpath $(SRC_PATH)),$(realpath .)) +MANUAL_BUILDDIR := docs/built +else +MANUAL_BUILDDIR := docs +endif + ifdef BUILD_DOCS -DOCS=qemu-doc.html qemu-doc.txt qemu.1 qemu-img.1 qemu-nbd.8 docs/interop/qemu-ga.8 +DOCS=qemu-doc.html qemu-doc.txt qemu.1 qemu-img.1 qemu-nbd.8 $(MANUAL_BUILDDIR)/interop/qemu-ga.8 DOCS+=docs/interop/qemu-qmp-ref.html docs/interop/qemu-qmp-ref.txt docs/interop/qemu-qmp-ref.7 DOCS+=docs/interop/qemu-ga-ref.html docs/interop/qemu-ga-ref.txt docs/interop/qemu-ga-ref.7 DOCS+=docs/qemu-block-drivers.7 @@ -699,17 +710,6 @@ dist: qemu-$(VERSION).tar.bz2 qemu-%.tar.bz2: $(SRC_PATH)/scripts/make-release "$(SRC_PATH)" "$(patsubst qemu-%.tar.bz2,%,$@)" -# Sphinx does not allow building manuals into the same directory as -# the source files, so if we're doing an in-tree QEMU build we must -# build the manuals into a subdirectory (and then install them from -# there for 'make install'). For an out-of-tree build we can just -# use the docs/ subdirectory in the build tree as normal. -ifeq ($(realpath $(SRC_PATH)),$(realpath .)) -MANUAL_BUILDDIR := docs/built -else -MANUAL_BUILDDIR := docs -endif - define clean-manual = rm -rf $(MANUAL_BUILDDIR)/$1/_static rm -f $(MANUAL_BUILDDIR)/$1/objects.inv $(MANUAL_BUILDDIR)/$1/searchindex.js $(MANUAL_BUILDDIR)/$1/*.html @@ -819,7 +819,7 @@ ifdef CONFIG_TRACE_SYSTEMTAP $(INSTALL_DATA) scripts/qemu-trace-stap.1 "$(DESTDIR)$(mandir)/man1" endif ifneq (,$(findstring qemu-ga,$(TOOLS))) - $(INSTALL_DATA) docs/interop/qemu-ga.8 "$(DESTDIR)$(mandir)/man8" + $(INSTALL_DATA) $(MANUAL_BUILDDIR)/interop/qemu-ga.8 "$(DESTDIR)$(mandir)/man8" $(INSTALL_DATA) docs/interop/qemu-ga-ref.html "$(DESTDIR)$(qemu_docdir)" $(INSTALL_DATA) docs/interop/qemu-ga-ref.txt "$(DESTDIR)$(qemu_docdir)" $(INSTALL_DATA) docs/interop/qemu-ga-ref.7 "$(DESTDIR)$(mandir)/man7" diff --git a/block/qapi.c b/block/qapi.c index 15f1030264..7ee2ee065d 100644 --- a/block/qapi.c +++ b/block/qapi.c @@ -23,7 +23,7 @@ */ #include "qemu/osdep.h" -#include "qemu-common.h" +#include "qemu/cutils.h" #include "block/qapi.h" #include "block/block_int.h" #include "block/throttle-groups.h" @@ -1521,6 +1521,10 @@ for opt do ;; --disable-libpmem) libpmem=no ;; + --enable-xkbcommon) xkbcommon=yes + ;; + --disable-xkbcommon) xkbcommon=no + ;; *) echo "ERROR: unknown option $opt" echo "Try '$0 --help' for more information" @@ -1804,6 +1808,7 @@ disabled with --disable-FEATURE, default is enabled if available: capstone capstone disassembler support debug-mutex mutex debugging support libpmem libpmem support + xkbcommon xkbcommon support NOTE: The object files are built at the place where configure is launched EOF diff --git a/hw/vfio/pci.c b/hw/vfio/pci.c index dc3479c374..c5e6fe61cb 100644 --- a/hw/vfio/pci.c +++ b/hw/vfio/pci.c @@ -44,7 +44,7 @@ #define TYPE_VFIO_PCI "vfio-pci" #define PCI_VFIO(obj) OBJECT_CHECK(VFIOPCIDevice, obj, TYPE_VFIO_PCI) -#define TYPE_VIFO_PCI_NOHOTPLUG "vfio-pci-nohotplug" +#define TYPE_VFIO_PCI_NOHOTPLUG "vfio-pci-nohotplug" static void vfio_disable_interrupts(VFIOPCIDevice *vdev); static void vfio_mmap_set_enabled(VFIOPCIDevice *vdev, bool enabled); @@ -3199,7 +3199,7 @@ static void vfio_pci_nohotplug_dev_class_init(ObjectClass *klass, void *data) } static const TypeInfo vfio_pci_nohotplug_dev_info = { - .name = TYPE_VIFO_PCI_NOHOTPLUG, + .name = TYPE_VFIO_PCI_NOHOTPLUG, .parent = TYPE_VFIO_PCI, .instance_size = sizeof(VFIOPCIDevice), .class_init = vfio_pci_nohotplug_dev_class_init, diff --git a/include/qemu-common.h b/include/qemu-common.h index 0235cd3b91..8d84db90b0 100644 --- a/include/qemu-common.h +++ b/include/qemu-common.h @@ -123,7 +123,6 @@ void qemu_hexdump(const char *buf, FILE *fp, const char *prefix, size_t size); int parse_debug_env(const char *name, int max, int initial); const char *qemu_ether_ntoa(const MACAddr *mac); -char *size_to_str(uint64_t val); void page_size_init(void); /* returns non-zero if dump is in progress, otherwise zero is diff --git a/include/qemu/cutils.h b/include/qemu/cutils.h index 12301340a4..b54c847e0f 100644 --- a/include/qemu/cutils.h +++ b/include/qemu/cutils.h @@ -155,6 +155,8 @@ int qemu_strtosz(const char *nptr, const char **end, uint64_t *result); int qemu_strtosz_MiB(const char *nptr, const char **end, uint64_t *result); int qemu_strtosz_metric(const char *nptr, const char **end, uint64_t *result); +char *size_to_str(uint64_t val); + /* used to print char* safely */ #define STR_OR_NULL(str) ((str) ? (str) : "null") diff --git a/include/sysemu/kvm.h b/include/sysemu/kvm.h index 909bcd77cf..fd674772ab 100644 --- a/include/sysemu/kvm.h +++ b/include/sysemu/kvm.h @@ -308,7 +308,7 @@ int kvm_vm_check_attr(KVMState *s, uint32_t group, uint64_t attr); int kvm_device_check_attr(int fd, uint32_t group, uint64_t attr); /** - * kvm_device_access - set or get value of a specific vm attribute + * kvm_device_access - set or get value of a specific device attribute * @fd: The device file descriptor * @group: the group * @attr: the attribute of that group to set or get diff --git a/python/qemu/qtest.py b/python/qemu/qtest.py index eebcc233ed..3f1d2cb325 100644 --- a/python/qemu/qtest.py +++ b/python/qemu/qtest.py @@ -96,7 +96,7 @@ class QEMUQtestMachine(QEMUMachine): def _base_args(self): args = super(QEMUQtestMachine, self)._base_args() args.extend(['-qtest', 'unix:path=' + self._qtest_path, - '-machine', 'accel=qtest']) + '-accel', 'qtest']) return args def _pre_launch(self): diff --git a/qapi/string-output-visitor.c b/qapi/string-output-visitor.c index 7ab64468d9..0d93605d77 100644 --- a/qapi/string-output-visitor.c +++ b/qapi/string-output-visitor.c @@ -11,7 +11,7 @@ */ #include "qemu/osdep.h" -#include "qemu-common.h" +#include "qemu/cutils.h" #include "qapi/string-output-visitor.h" #include "qapi/visitor-impl.h" #include "qemu/host-utils.h" diff --git a/qemu-deprecated.texi b/qemu-deprecated.texi index 9d74a1cfc0..01245e0b1c 100644 --- a/qemu-deprecated.texi +++ b/qemu-deprecated.texi @@ -26,8 +26,7 @@ The @option{enforce-config-section} parameter is replaced by the @subsection -no-kvm (since 1.3.0) -The ``-no-kvm'' argument is now a synonym for setting -``-machine accel=tcg''. +The ``-no-kvm'' argument is now a synonym for setting ``-accel tcg''. @subsection -usbdevice (since 2.10.0) diff --git a/qemu-options.hx b/qemu-options.hx index ed9292f65e..618a57d409 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -4160,7 +4160,7 @@ STEXI Enable FIPS 140-2 compliance mode. ETEXI -HXCOMM Deprecated by -machine accel=tcg property +HXCOMM Deprecated by -accel tcg DEF("no-kvm", 0, QEMU_OPTION_no_kvm, "", QEMU_ARCH_I386) DEF("msg", HAS_ARG, QEMU_OPTION_msg, diff --git a/target/m68k/fpu_helper.c b/target/m68k/fpu_helper.c index 9b039c856d..4137542ec0 100644 --- a/target/m68k/fpu_helper.c +++ b/target/m68k/fpu_helper.c @@ -396,14 +396,14 @@ typedef int (*float_access)(CPUM68KState *env, uint32_t addr, FPReg *fp, uintptr_t ra); static uint32_t fmovem_predec(CPUM68KState *env, uint32_t addr, uint32_t mask, - float_access access) + float_access access_fn) { uintptr_t ra = GETPC(); int i, size; for (i = 7; i >= 0; i--, mask <<= 1) { if (mask & 0x80) { - size = access(env, addr, &env->fregs[i], ra); + size = access_fn(env, addr, &env->fregs[i], ra); if ((mask & 0xff) != 0x80) { addr -= size; } @@ -414,14 +414,14 @@ static uint32_t fmovem_predec(CPUM68KState *env, uint32_t addr, uint32_t mask, } static uint32_t fmovem_postinc(CPUM68KState *env, uint32_t addr, uint32_t mask, - float_access access) + float_access access_fn) { uintptr_t ra = GETPC(); int i, size; for (i = 0; i < 8; i++, mask <<= 1) { if (mask & 0x80) { - size = access(env, addr, &env->fregs[i], ra); + size = access_fn(env, addr, &env->fregs[i], ra); addr += size; } } diff --git a/tests/acceptance/cpu_queries.py b/tests/acceptance/cpu_queries.py index e71edec39f..af47d2795a 100644 --- a/tests/acceptance/cpu_queries.py +++ b/tests/acceptance/cpu_queries.py @@ -18,6 +18,9 @@ class QueryCPUModelExpansion(Test): """ def test(self): + """ + :avocado: tags=arch:x86_64 + """ self.vm.set_machine('none') self.vm.add_args('-S') self.vm.launch() diff --git a/tests/acceptance/linux_ssh_mips_malta.py b/tests/acceptance/linux_ssh_mips_malta.py index 134f10cac3..7200507a3a 100644 --- a/tests/acceptance/linux_ssh_mips_malta.py +++ b/tests/acceptance/linux_ssh_mips_malta.py @@ -12,7 +12,7 @@ import logging import paramiko import time -from avocado import skipIf +from avocado import skipUnless from avocado_qemu import Test from avocado.utils import process from avocado.utils import archive @@ -171,7 +171,7 @@ class LinuxSSH(Test): self.run_common_commands() self.shutdown_via_ssh() - @skipIf(os.getenv('CONTINUOUS_INTEGRATION'), 'Running on Travis-CI') + @skipUnless(os.getenv('AVOCADO_TIMEOUT_EXPECTED'), 'Test might timeout') def test_mips_malta32eb_kernel3_2_0(self): """ :avocado: tags=arch:mips @@ -186,7 +186,7 @@ class LinuxSSH(Test): self.check_mips_malta('be', kernel_path, 'mips') - @skipIf(os.getenv('CONTINUOUS_INTEGRATION'), 'Running on Travis-CI') + @skipUnless(os.getenv('AVOCADO_TIMEOUT_EXPECTED'), 'Test might timeout') def test_mips_malta32el_kernel3_2_0(self): """ :avocado: tags=arch:mipsel @@ -201,7 +201,7 @@ class LinuxSSH(Test): self.check_mips_malta('le', kernel_path, 'mips') - @skipIf(os.getenv('CONTINUOUS_INTEGRATION'), 'Running on Travis-CI') + @skipUnless(os.getenv('AVOCADO_TIMEOUT_EXPECTED'), 'Test might timeout') def test_mips_malta64eb_kernel3_2_0(self): """ :avocado: tags=arch:mips64 @@ -215,7 +215,7 @@ class LinuxSSH(Test): kernel_path = self.fetch_asset(kernel_url, asset_hash=kernel_hash) self.check_mips_malta('be', kernel_path, 'mips64') - @skipIf(os.getenv('CONTINUOUS_INTEGRATION'), 'Running on Travis-CI') + @skipUnless(os.getenv('AVOCADO_TIMEOUT_EXPECTED'), 'Test might timeout') def test_mips_malta64el_kernel3_2_0(self): """ :avocado: tags=arch:mips64el diff --git a/tests/libqtest.c b/tests/libqtest.c index 4a7556462d..38e4f5b587 100644 --- a/tests/libqtest.c +++ b/tests/libqtest.c @@ -241,7 +241,7 @@ QTestState *qtest_init_without_qmp_handshake(const char *extra_args) "-qtest-log %s " "-chardev socket,path=%s,id=char0 " "-mon chardev=char0,mode=control " - "-machine accel=qtest " + "-accel qtest " "-display none " "%s", qemu_binary, socket_path, getenv("QTEST_LOG") ? "/dev/fd/2" : "/dev/null", diff --git a/tests/migration/guestperf/engine.py b/tests/migration/guestperf/engine.py index f13dbea800..1dd04ce33b 100644 --- a/tests/migration/guestperf/engine.py +++ b/tests/migration/guestperf/engine.py @@ -287,7 +287,7 @@ class Engine(object): cmdline = "'" + cmdline + "'" argv = [ - "-machine", "accel=kvm", + "-accel", "kvm", "-cpu", "host", "-kernel", self._kernel, "-initrd", self._initrd, diff --git a/tests/qemu-iotests/172 b/tests/qemu-iotests/172 index ba7dad9057..d67997e5f6 100755 --- a/tests/qemu-iotests/172 +++ b/tests/qemu-iotests/172 @@ -55,7 +55,7 @@ do_run_qemu() done fi echo quit - ) | $QEMU -machine accel=qtest -nographic -monitor stdio -serial none "$@" + ) | $QEMU -accel qtest -nographic -monitor stdio -serial none "$@" echo } diff --git a/util/cacheinfo.c b/util/cacheinfo.c index eebe1ce9c5..ea6f3e99bf 100644 --- a/util/cacheinfo.c +++ b/util/cacheinfo.c @@ -65,25 +65,28 @@ static void sys_cache_info(int *isize, int *dsize) g_free(buf); } -#elif defined(__APPLE__) \ - || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) +#elif defined(__APPLE__) # include <sys/sysctl.h> -# if defined(__APPLE__) -# define SYSCTL_CACHELINE_NAME "hw.cachelinesize" -# else -# define SYSCTL_CACHELINE_NAME "machdep.cacheline_size" -# endif - static void sys_cache_info(int *isize, int *dsize) { /* There's only a single sysctl for both I/D cache line sizes. */ long size; size_t len = sizeof(size); - if (!sysctlbyname(SYSCTL_CACHELINE_NAME, &size, &len, NULL, 0)) { + if (!sysctlbyname("hw.cachelinesize", &size, &len, NULL, 0)) { + *isize = *dsize = size; + } +} +#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) +# include <sys/sysctl.h> +static void sys_cache_info(int *isize, int *dsize) +{ + /* There's only a single sysctl for both I/D cache line sizes. */ + int size; + size_t len = sizeof(size); + if (!sysctlbyname("machdep.cacheline_size", &size, &len, NULL, 0)) { *isize = *dsize = size; } } - #else /* POSIX */ |