summaryrefslogtreecommitdiff
path: root/Makefile
AgeCommit message (Collapse)AuthorFilesLines
2019-01-10keymaps: remove common includeGerd Hoffmann1-1/+1
Copy the content into the sl and sv files (the only ones left which are not generated by qemu-keymap). Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 20181116104319.10329-4-kraxel@redhat.com
2019-01-10keymaps: drop nl-be mapGerd Hoffmann1-1/+1
It doesn't define any keys, only includes "common". Which makes it effectively an "en-us" map. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 20181116104319.10329-3-kraxel@redhat.com
2019-01-10keymaps: remove modifiers includeGerd Hoffmann1-1/+1
"common" is the only file using it, so we can just include it directly. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 20181116104319.10329-2-kraxel@redhat.com
2018-12-22contrib/rdmacm-mux: Add implementation of RDMA User MAD multiplexerYuval Shaia1-0/+3
RDMA MAD kernel module (ibcm) disallow more than one MAD-agent for a given MAD class. This does not go hand-by-hand with qemu pvrdma device's requirements where each VM is MAD agent. Fix it by adding implementation of RDMA MAD multiplexer service which on one hand register as a sole MAD agent with the kernel module and on the other hand gives service to more than one VM. Design Overview: Reviewed-by: Shamir Rabinovitch <shamir.rabinovitch@oracle.com> ---------------- A server process is registered to UMAD framework (for this to work the rdma_cm kernel module needs to be unloaded) and creates a unix socket to listen to incoming request from clients. A client process (such as QEMU) connects to this unix socket and registers with its own GID. TX: ---- When client needs to send rdma_cm MAD message it construct it the same way as without this multiplexer, i.e. creates a umad packet but this time it writes its content to the socket instead of calling umad_send(). The server, upon receiving such a message fetch local_comm_id from it so a context for this session can be maintain and relay the message to UMAD layer by calling umad_send(). RX: ---- The server creates a worker thread to process incoming rdma_cm MAD messages. When an incoming message arrived (umad_recv()) the server, depending on the message type (attr_id) looks for target client by either searching in gid->fd table or in local_comm_id->fd table. With the extracted fd the server relays to incoming message to the client. Signed-off-by: Yuval Shaia <yuval.shaia@oracle.com> Reviewed-by: Shamir Rabinovitch <shamir.rabinovitch@oracle.com> Signed-off-by: Marcel Apfelbaum <marcel.apfelbaum@gmail.com>
2018-12-20build: Remake config-host.mak when VERSION changesMarkus Armbruster1-1/+1
configure gets the version number from VERSION, and writes it to config-host.mak. The make dependency for that is missing. Because of that, a rebuild after a VERSION change may not pick up the change. Fix that. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20181214084754.23854-1-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
2018-12-11qapi: Reduce Makefile boilerplateEric Blake1-170/+24
Adding a new qapi module had some rather tedious repetition to wire it into Makefile, Makefile.objs, and .gitignore (for example, see commit bf42508f and its followup b61acdec). For make, add some indirection by taking advantage of GNU Make string processing to expand a list of module names into all the required artifacts, so that future additions of a new module need only touch the list of module names. And for gitignore, use globs to cover all generated file names. The list has to live in Makefile.objs, due to the way that our unnest-vars macro slirps in that file without remembering any definition of $(QAPI_MODULES) from Makefile. Signed-off-by: Eric Blake <eblake@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Tested-by: Yuval Shaia <yuval.shaia@oracle.com> Message-Id: <20181116200016.2080785-1-eblake@redhat.com> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
2018-10-15Makefile: Install new vgabios binariesAlex Williamson1-0/+1
Difficult to make use of if not installed Fixes: cd1bfd5ef336 ("seabios: update bios and vgabios binaries") Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-id: 153936155938.28040.11513367417790075721.stgit@gimli.home Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2018-10-02contrib: add elf2dmp toolViktor Prutyanov1-0/+5
elf2dmp is a converter from ELF dump (produced by 'dump-guest-memory') to Windows MEMORY.DMP format (also know as 'Complete Memory Dump') which can be opened in WinDbg. This tool can help if VMCoreInfo device/driver is absent in Windows VM and 'dump-guest-memory -w' is not available but dump can be created in ELF format. The tool works as follows: 1. Determine the system paging root looking at GS_BASE or KERNEL_GS_BASE to locate the PRCB structure and finds the kernel CR3 nearby if QEMU CPU state CR3 is not suitable. 2. Find an address within the kernel image by dereferencing the first IDT entry and scans virtual memory upwards until the start of the kernel. 3. Download a PDB matching the kernel from the Microsoft symbol store, and figure out the layout of certain relevant structures necessary for the dump. 4. Populate the corresponding structures in the memory image and create the appropriate dump header. Signed-off-by: Viktor Prutyanov <viktor.prutyanov@virtuozzo.com> Message-Id: <1535546488-30208-3-git-send-email-viktor.prutyanov@virtuozzo.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2018-10-01Merge remote-tracking branch 'remotes/kraxel/tags/vga-20180927-pull-request' ↵Peter Maydell1-0/+2
into staging vga: add edid support, qxl bugfixes. # gpg: Signature made Thu 27 Sep 2018 08:12:32 BST # gpg: using RSA key 4CB6D8EED3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" # Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138 * remotes/kraxel/tags/vga-20180927-pull-request: qxl: support mono cursors with inverted colors qxl: use guest_monitor_config for local renderer. display/stdvga: add edid support. display/edid: add DEFINE_EDID_PROPERTIES display/edid: add region helper. display/edid: add qemu_edid_size() display/edid: add edid generator to qemu. Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-09-27display/edid: add edid generator to qemu.Gerd Hoffmann1-0/+2
EDID is a metadata format to describe monitors. On physical hardware the monitor has an eeprom with that data block which can be read over i2c bus. On a linux system you can usually find the EDID data block in /sys/class/drm/$card/$connector/edid. xorg ships a edid-decode utility which you can use to turn the blob into readable form. I think it would be a good idea to use EDID for virtual displays too. Needs changes in both qemu and guest kms drivers. This patch is the first step, it adds an generator for EDID blobs to qemu. Comes with a qemu-edid test tool included. With EDID we can pass more information to the guest. Names and serial numbers, so the guests display configuration has no boring "Unknown Monitor". List of video modes. Display resolution, pretty important in case we want add HiDPI support some day. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 20180925075646.25114-2-kraxel@redhat.com
2018-09-25Makefile: Add missing dependency for qemu-deprecated.texiThomas Huth1-1/+1
Make sure that the docs get correctly regenerated when the file qemu-deprecated.texi has been changed. Fixes: 44c67847e32c91a6071fb0440c357b9489f08bc6 Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com> (cherry picked from commit f99ce85279178385f204a52236f855c879c29cdc)
2018-08-27configure: We don't want to clean configuration filesJuan Quintela1-1/+2
If you don't want to compile everything, you configure config-devices.mak. And then make clean remove it, and make will create a default one without your configuration. Fix it by not removing it on clean target. Remove it instead on distclean. Signed-off-by: Juan Quintela <quintela@redhat.com> Reviewed-by: Thomas Huth <thuth@redhat.com> --- Remove it instead on distclean.
2018-08-16docs: add guidance on configuring CPU models for x86Daniel P. Berrangé1-1/+6
With the recent set of CPU hardware vulnerabilities on x86, it is increasingly difficult to understand which CPU configurations are good to use and what flaws they might be vulnerable to. This doc attempts to help management applications and administrators in picking sensible CPU configuration on x86 hosts. It outlines which of the named CPU models are good choices, and describes which extra CPU flags should be enabled to allow the guest to mitigate hardware flaws. Signed-off-by: Daniel P. Berrangé <berrange@redhat.com> Message-Id: <20180627160103.13634-1-berrange@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
2018-07-05build-system: add coverage-report targetAlex Bennée1-0/+13
This will build a coverage report under the current directory in reports/coverage. At the users option a report can be generated by directly invoking something like: make foo/bar/coverage-report.html Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
2018-07-05build-system: add clean-coverage targetAlex Bennée1-0/+11
This can be used to remove any stale coverage data before any particular test run. This is useful for analysing individual tests. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>---
2018-07-05Revert "Makefile: Rename TARGET_DIRS to TARGET_LIST"Alex Bennée1-10/+10
This reverts commit 208ecb3e1acc8d55dab49fdf721a86d513691688. This was causing problems by making DEF_TARGET_LIST pointless and having to jump through hoops to build on mingw with a dully enabled config. This includes a change to fix the per-guest TCG test probe which was added after 208ecb3 and used TARGET_LIST. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Cc: Paolo Bonzini <pbonzini@redhat.com>
2018-06-22Revert commit d4e5ec877caMatthias Maier1-4/+2
This commit removes the PYTHON_UTF8 workaround. The problem with setting LC_ALL= LANG=C LC_CTYPE=en_US.UTF-8 is that the en_US.UTF-8 locale might not be available. In this case setting above locales results in build errors even though another UTF-8 locale was originally set [1]. The only stable way of fixing the encoding problem is by specifying the encoding in Python, like the previous commit does. [1] https://bugs.gentoo.org/657766 Signed-off-by: Arfrever Frehtes Taifersar Arahesis <arfrever.fta@gmail.com> Signed-off-by: Matthias Maier <tamiko@43-1.org> Message-Id: <20180618175958.29073-3-armbru@redhat.com> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> [Commit message tweaked] Signed-off-by: Markus Armbruster <armbru@redhat.com>
2018-06-14Merge remote-tracking branch 'remotes/kraxel/tags/ui-20180614-pull-request' ↵Peter Maydell1-0/+1
into staging ui: bugfixes for sdl and gtk # gpg: Signature made Thu 14 Jun 2018 09:32:45 BST # gpg: using RSA key 4CB6D8EED3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" # Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138 * remotes/kraxel/tags/ui-20180614-pull-request: sdl2: restore window dimensions by resize ui: darwin: gtk: Add missing input keymap Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-06-14Merge remote-tracking branch 'remotes/armbru/tags/pull-misc-2018-06-13' into ↵Peter Maydell1-3/+0
staging Miscellaneous patches for 2018-06-13 # gpg: Signature made Wed 13 Jun 2018 13:51:51 BST # gpg: using RSA key 3870B400EB918653 # gpg: Good signature from "Markus Armbruster <armbru@redhat.com>" # gpg: aka "Markus Armbruster <armbru@pond.sub.org>" # Primary key fingerprint: 354B C8B3 D7EB 2A6B 6867 4E5F 3870 B400 EB91 8653 * remotes/armbru/tags/pull-misc-2018-06-13: Purge uses of banned g_assert_FOO() coverity-model: replay data is considered trusted Revert "Makefile: add target to print generated files" Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-06-14ui: darwin: gtk: Add missing input keymapKeno Fischer1-0/+1
In appears the input keymap for osx was forgotten in the commit that converted the gtk frontend to keycodemapdb. Add it. Fixes: 2ec78706 ("ui: convert GTK and SDL1 frontends to keycodemapdb") CC: Daniel P. Berrange <berrange@redhat.com> Signed-off-by: Keno Fischer <keno@juliacomputing.com> Message-id: 1528933916-40670-1-git-send-email-keno@juliacomputing.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2018-06-13Revert "Makefile: add target to print generated files"Markus Armbruster1-3/+0
This reverts commit 9578f8cc3e8bd71de8e3f543dc7b95644d64824e. The patch snuck in by accident without having been posted to qemu-devel. It's entirely redundant: existing target print-% already serves the purpose. Cc: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180504054241.6833-1-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
2018-06-12Merge remote-tracking branch ↵Peter Maydell1-1/+1
'remotes/vivier2/tags/linux-user-for-3.0-pull-request' into staging Fixes in syscall numbers, disable the build of binaries not needed for linux-user, update of qemu-binfmt-conf.sh and cleanup around is_error() # gpg: Signature made Tue 12 Jun 2018 11:57:18 BST # gpg: using RSA key F30C38BD3F2FBE3C # gpg: Good signature from "Laurent Vivier <lvivier@redhat.com>" # gpg: aka "Laurent Vivier <laurent@vivier.eu>" # gpg: aka "Laurent Vivier (Red Hat) <lvivier@redhat.com>" # Primary key fingerprint: CD2F 75DD C8E3 A4DC 2E4F 5173 F30C 38BD 3F2F BE3C * remotes/vivier2/tags/linux-user-for-3.0-pull-request: linux-user/sparc64: Add inotify_rm_watch and tee syscalls linux-user/microblaze: Fix typo in accept4 syscall linux-user/hppa: Fix typo in mknodat syscall linux-user/alpha: Fix epoll syscalls qemu-binfmt-conf.sh: ignore the OS/ABI field linux-user: disable qemu-bridge-helper and socket_scm_helper build linux-user: Use is_error() to avoid warnings and make the code clearer linux-user: Export use is_error(), use it to avoid warnings Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-06-11linux-user: disable qemu-bridge-helper and socket_scm_helper buildLaurent Vivier1-1/+1
linux-user targets don't need them, and if we ask to build statically linked binaries, some static libraries they need are not available. Signed-off-by: Laurent Vivier <laurent@vivier.eu> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-Id: <20180605160958.5434-1-laurent@vivier.eu>
2018-06-08python: Remove scripts/ordereddict.pyEduardo Habkost1-1/+0
Python 2.7 (the minimum Python version we require) provides collections.OrderedDict on the standard library, so we don't need to carry our own implementation. Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Message-Id: <20180608175252.25110-3-ehabkost@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
2018-06-05Makefile: Rename TARGET_DIRS to TARGET_LISTFam Zheng1-10/+10
To be more accurate on its purpose and make code that looks for a certain target out of this variable more readable. Signed-off-by: Fam Zheng <famz@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
2018-05-23job: Introduce qapi/job.jsonKevin Wolf1-0/+9
This adds a separate schema file for all job-related definitions that aren't tied to the block layer. For a start, move the enums JobType, JobStatus and JobVerb. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
2018-05-11build: Silence dtc directory creationJan Kiszka1-1/+1
Align with other mkdir calls. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <0dd4c8f5-d60e-e564-652f-cd0101f6ee68@web.de> Message-Id: <20180415230522.24404-5-f4bug@amsat.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2018-04-16Makefile: install gtk message catalogs if CONFIG_GTK=y too, not only =mMichael Tokarev1-1/+1
Fixes 722cd7496474cebb2218f21e038592fad8603365 Signed-off-by: Michael Tokarev <mjt@tls.msk.ru> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Message-id: 20180416093719.2543-1-mjt@msgid.tls.msk.ru Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-03-20Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into stagingPeter Maydell1-1/+3
virtio,vhost,pci,pc: features, cleanups SRAT tables for DIMM devices new virtio net flags for speed/duplex post-copy migration support in vhost cleanups in pci Signed-off-by: Michael S. Tsirkin <mst@redhat.com> # gpg: Signature made Tue 20 Mar 2018 14:40:43 GMT # gpg: using RSA key 281F0DB8D28D5469 # gpg: Good signature from "Michael S. Tsirkin <mst@kernel.org>" # gpg: aka "Michael S. Tsirkin <mst@redhat.com>" # Primary key fingerprint: 0270 606B 6F3C DF3D 0B17 0970 C350 3912 AFBE 8E67 # Subkey fingerprint: 5D09 FD08 71C8 F85B 94CA 8A0D 281F 0DB8 D28D 5469 * remotes/mst/tags/for_upstream: (51 commits) postcopy shared docs libvhost-user: Claim support for postcopy postcopy: Allow shared memory vhost: Huge page align and merge vhost+postcopy: Wire up POSTCOPY_END notify vhost-user: Add VHOST_USER_POSTCOPY_END message libvhost-user: mprotect & madvises for postcopy vhost+postcopy: Call wakeups vhost+postcopy: Add vhost waker postcopy: postcopy_notify_shared_wake postcopy: helper for waking shared vhost+postcopy: Resolve client address postcopy-ram: add a stub for postcopy_request_shared_page vhost+postcopy: Helper to send requests to source for shared pages vhost+postcopy: Stash RAMBlock and offset vhost+postcopy: Send address back to qemu libvhost-user+postcopy: Register new regions with the ufd migration/ram: ramblock_recv_bitmap_test_byte_offset postcopy+vhost-user: Split set_mem_table for postcopy vhost+postcopy: Transmit 'listen' to slave ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org> # Conflicts: # scripts/update-linux-headers.sh
2018-03-20Makefile: add target to print generated filesMichael S. Tsirkin1-0/+3
This is helpful for automatic code analysis. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2018-03-16Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into stagingPeter Maydell1-9/+14
* Record-replay lockstep execution, log dumper and fixes (Alex, Pavel) * SCSI fix to pass maximum transfer size (Daniel Barboza) * chardev fixes and improved iothread support (Daniel Berrangé, Peter) * checkpatch tweak (Eric) * make help tweak (Marc-André) * make more PCI NICs available with -net or -nic (myself) * change default q35 NIC to e1000e (myself) * SCSI support for NDOB bit (myself) * membarrier system call support (myself) * SuperIO refactoring (Philippe) * miscellaneous cleanups and fixes (Thomas) # gpg: Signature made Mon 12 Mar 2018 16:10:52 GMT # gpg: using RSA key BFFBD25F78C7AE83 # gpg: Good signature from "Paolo Bonzini <bonzini@gnu.org>" # gpg: aka "Paolo Bonzini <pbonzini@redhat.com>" # Primary key fingerprint: 46F5 9FBD 57D6 12E7 BFD4 E2F7 7E15 100C CD36 69B1 # Subkey fingerprint: F133 3857 4B66 2389 866C 7682 BFFB D25F 78C7 AE83 * remotes/bonzini/tags/for-upstream: (69 commits) tcg: fix cpu_io_recompile replay: update documentation replay: save vmstate of the asynchronous events replay: don't process async events when warping the clock scripts/replay-dump.py: replay log dumper replay: avoid recursive call of checkpoints replay: check return values of fwrite replay: push replay_mutex_lock up the call tree replay: don't destroy mutex at exit replay: make locking visible outside replay code replay/replay-internal.c: track holding of replay_lock replay/replay.c: bump REPLAY_VERSION again replay: save prior value of the host clock replay: added replay log format description replay: fix save/load vm for non-empty queue replay: fixed replay_enable_events replay: fix processing async events cpu-exec: fix exception_index handling hw/i386/pc: Factor out the superio code hw/alpha/dp264: Use the TYPE_SMC37C669_SUPERIO ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org> # Conflicts: # default-configs/i386-softmmu.mak # default-configs/x86_64-softmmu.mak
2018-03-13acpi: remove unused acpi-dsdt.amlIgor Mammedov1-1/+0
SeaBIOS blob which is currently shipped with QEMU doesn't need acpi-dsdt.aml nor is able to use it and code that loaded it in QEMU was removed by (commit 9fb7aaaf4c "pc: drop external DSDT loading") in 2013. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Eric Auger <eric.auger@redhat.com> Tested-by: Eric Auger <eric.auger@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2018-03-12Merge remote-tracking branch ↵Peter Maydell1-0/+4
'remotes/kraxel/tags/audio-20180312-pull-request' into staging modules: use gmodule-export. audio: add driver registry, enable module builds. # gpg: Signature made Mon 12 Mar 2018 10:42:19 GMT # gpg: using RSA key 4CB6D8EED3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" # Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138 * remotes/kraxel/tags/audio-20180312-pull-request: audio/sdl: build as module audio/pulseaudio: build as module audio/oss: build as module audio/alsa: build as module build: enable audio modules audio: add module loading support audio: add driver registry modules: use gmodule-export Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-03-12Polish the version strings containing the package versionThomas Huth1-9/+11
Since commit 67a1de0d195a there is no space anymore between the version number and the parentheses when running configure with --with-pkgversion=foo : $ qemu-system-s390x --version QEMU emulator version 2.11.50(foo) But the space is included when building without that option when building from a git checkout: $ qemu-system-s390x --version QEMU emulator version 2.11.50 (v2.11.0-1494-gbec9c64-dirty) The same confusion exists with the "query-version" QMP command. Let's fix this by introducing a proper QEMU_FULL_VERSION definition that includes the space and parentheses, while the QEMU_PKGVERSION should just cleanly contain the package version string itself. Note that this also changes the behavior of the "query-version" QMP command (the space and parentheses are not included there anymore), but that's supposed to be OK since the strings there are not meant to be parsed by other tools. Fixes: 67a1de0d195a6185c39b436159c9ffc7720bf979 Buglink: https://bugs.launchpad.net/qemu/+bug/1673373 Signed-off-by: Thomas Huth <thuth@redhat.com> Message-Id: <1518692807-25859-1-git-send-email-thuth@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2018-03-12build-sys: make help could have 'modules' targetMarc-André Lureau1-0/+3
Available when configure --enable-modules. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20180306161728.20890-1-marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2018-03-12build: enable audio modulesGerd Hoffmann1-0/+4
Add audio/ to common-obj-m variable. Also run both audio and ui variables through unnest-vars. This avoids sdl.mo (exists in both audio/ and ui/) name clashes. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 20180306074053.22856-4-kraxel@redhat.com
2018-03-12make: switch language file build to be gtk module awareBruce Rogers1-1/+1
Now that gtk support builds as a module, CONFIG_GTK changed from y to m. Adjust Makefile correspondingly. Signed-off-by: Bruce Rogers <brogers@suse.com> Message-id: 20180307155517.32570-1-brogers@suse.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2018-03-06ppc: Add aCube Sam460ex boardBALATON Zoltan1-1/+1
Add emulation of aCube Sam460ex board based on AMCC 460EX embedded SoC. This is not a complete implementation yet with a lot of components still missing but enough for the U-Boot firmware to start and to boot a Linux kernel or AROS. Signed-off-by: François Revol <revol@free.fr> Signed-off-by: BALATON Zoltan <balaton@eik.bme.hu> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2018-03-06pc-bios: Added u-boot-sam460 firmware binaryBALATON Zoltan1-1/+1
Signed-off-by: BALATON Zoltan <balaton@eik.bme.hu> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2018-03-02qapi: Don't create useless directory qapi-generatedMarkus Armbruster1-1/+0
We used to generate first test and later QGA QAPI code into qapi-generated/. Commit b93b63f574 moved the test code to tests/. Commit 54c2e50205 moved the QGA code to qga/qapi-generated/. The directory has been unused since. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180211093607.27351-30-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Eric Blake <eblake@redhat.com>
2018-03-02qapi: Move qapi-schema.json to qapi/, rename generated filesMarkus Armbruster1-21/+21
Move qapi-schema.json to qapi/, so it's next to its modules, and all files get generated to qapi/, not just the ones generated for modules. Consistently name the generated files qapi-MODULE.EXT: qmp-commands.[ch] become qapi-commands.[ch], qapi-event.[ch] become qapi-events.[ch], and qmp-introspect.[ch] become qapi-introspect.[ch]. This gets rid of the temporary hacks in scripts/qapi/commands.py, scripts/qapi/events.py, and scripts/qapi/common.py. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180211093607.27351-28-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com> [eblake: Fix trailing dot in tpm.c, undo temporary hack for OSX toolchain] Signed-off-by: Eric Blake <eblake@redhat.com>
2018-03-02qapi: Empty out qapi-schema.jsonMarkus Armbruster1-0/+9
The previous commit improved compile time by including less of the generated QAPI headers. This is impossible for stuff defined directly in qapi-schema.json, because that ends up in headers that that pull in everything. Move everything but include directives from qapi-schema.json to new sub-module qapi/misc.json, then include just the "misc" shard where possible. It's possible everywhere, except: * monitor.c needs qmp-command.h to get qmp_init_marshal() * monitor.c, ui/vnc.c and the generated qapi-event-FOO.c need qapi-event.h to get enum QAPIEvent Perhaps we'll get rid of those some other day. Adding a type to qapi/migration.json now recompiles some 120 instead of 2300 out of 5100 objects. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180211093607.27351-25-armbru@redhat.com> [eblake: rebase to master] Signed-off-by: Eric Blake <eblake@redhat.com>
2018-03-02qapi: Generate separate .h, .c for each moduleMarkus Armbruster1-0/+120
Our qapi-schema.json is composed of modules connected by include directives, but the generated code is monolithic all the same: one qapi-types.h with all the types, one qapi-visit.h with all the visitors, and so forth. These monolithic headers get included all over the place. In my "build everything" tree, adding a QAPI type recompiles about 4800 out of 5100 objects. We wouldn't write such monolithic headers by hand. It stands to reason that we shouldn't generate them, either. Split up generated qapi-types.h to mirror the schema's modular structure: one header per module. Name the main module's header qapi-types.h, and sub-module D/B.json's header D/qapi-types-B.h. Mirror the schema's includes in the headers, so that qapi-types.h gets you everything exactly as before. If you need less, you can include one or more of the sub-module headers. To be exploited shortly. Split up qapi-types.c, qapi-visit.h, qapi-visit.c, qmp-commands.h, qmp-commands.c, qapi-event.h, qapi-event.c the same way. qmp-introspect.h, qmp-introspect.c and qapi.texi remain monolithic. The split of qmp-commands.c duplicates static helper function qmp_marshal_output_str() in qapi-commands-char.c and qapi-commands-misc.c. This happens when commands returning the same type occur in multiple modules. Not worth avoiding. Since I'm going to rename qapi-event.[ch] to qapi-events.[ch], and qmp-commands.[ch] to qapi-commands.[ch], name the shards that way already, to reduce churn. This requires temporary hacks in commands.py and events.py. Similarly, c_name() must temporarily be taught to munge '/' in common.py. They'll go away with the rename. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180211093607.27351-23-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> [eblake: declare a dummy variable in each .c file, to shut up OSX toolchain warnings about empty .o files, including hacking c_name()] Signed-off-by: Eric Blake <eblake@redhat.com>
2018-03-02qapi/types qapi/visit: Generate built-in stuff into separate filesMarkus Armbruster1-4/+9
Linking code from multiple separate QAPI schemata into the same program is possible, but involves some weirdness around built-in types: * We generate code for built-in types into .c only with option --builtins. The user is responsible for generating code for exactly one QAPI schema per program with --builtins. * We generate code for built-in types into .h regardless of --builtins, but guarded by #ifndef QAPI_VISIT_BUILTIN. Because all copies of this code are exactly the same, including any combination of these headers works. Replace this contraption by something more conventional: generate code for built-in types into their very own files: qapi-builtin-types.c, qapi-builtin-visit.c, qapi-builtin-types.h, qapi-builtin-visit.h, but only with --builtins. Obey --output-dir, but ignore --prefix for them. Make qapi-types.h include qapi-builtin-types.h. With multiple schemata you now have multiple qapi-types.[ch], but only one qapi-builtin-types.[ch]. Same for qapi-visit.[ch] and qapi-builtin-visit.[ch]. Bonus: if all you need is built-in stuff, you can include a much smaller header. To be exploited shortly. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180211093607.27351-21-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com> [eblake: fix octal constant for python 3] Signed-off-by: Eric Blake <eblake@redhat.com>
2018-03-02qapi: Rename generated qmp-marshal.c to qmp-commands.cMarkus Armbruster1-3/+3
All generated .c are named like their .h, except for qmp-marshal.c and qmp-commands.h. To add to the confusion, tests-qmp-commands.c falsely matches generated test-qmp-commands.h. Get rid of this unnecessary complication. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20180211093607.27351-19-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Eric Blake <eblake@redhat.com>
2018-03-02qapi-gen: New common driver for code and doc generatorsMarkus Armbruster1-50/+38
Whenever qapi-schema.json changes, we run six programs eleven times to update eleven files. Similar for qga/qapi-schema.json. This is silly. Replace the six programs by a single program that spits out all eleven files. The programs become modules in new Python package qapi, along with the helper library. This requires moving them to scripts/qapi/. While moving them, consistently drop executable mode bits. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20180211093607.27351-9-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com> [eblake: move change to one-line 'blurb' earlier in series, mention mode bit change as intentional, update qapi-code-gen.txt to match actual generated events.c file] Signed-off-by: Eric Blake <eblake@redhat.com>
2018-02-15allow to build with older sedJan Beulich1-2/+1
sed's -E option may not be supported by older distros. As there's no point using sed here at all, use just shell mechanisms to establish the variable values, starting from the stem instead of the full target. Signed-off-by: Jan Beulich <jbeulich@suse.com> Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2018-02-13make: fix help message reference to bogus V=0 variableDaniel P. Berrange1-1/+2
The make rules for building QEMU are mostly silent by default. They can be made verbose by setting the variable V=1. The default state does not however correspond to a V=0 setting - $(V) must be undefined / empty to get the default quiet build. Signed-off-by: Daniel P. Berrange <berrange@redhat.com> Message-Id: <20180123164718.12714-3-berrange@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2018-02-13Revert "build-sys: silence make by default or V=0"Daniel P. Berrange1-1/+1
This reverts commit 42a77f1ce4934b243df003f95bda88530631387a. The primary intention of this change was to silence messages like make[1]: '/home/berrange/src/virt/qemu/capstone/libcapstone.a' is up to date. which we get when calling make recursively with explicit targets. The problem is that this change affected every make target, not merely the targets that triggered these "is up to date" messages. As a result any targets that were not invoking commands via "$(call quiet-command ...)" suddenly become silent. This is particularly bad for "make install" which now appears todo nothing. Rather than go through every make rule and try to identify places where we now need to explicitly print a message to show work taking place, just revert the change. To address the original problem of silencing "is up to date" messages, we simply add --quiet to the SUBDIR_MAKEVARS variable, so it only affects us on recursive make calls. Signed-off-by: Daniel P. Berrange <berrange@redhat.com> Message-Id: <20180123164718.12714-2-berrange@redhat.com> Tested-by: Eric Blake <eblake@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2018-02-05qapi: force a UTF-8 locale for running PythonDaniel P. Berrange1-10/+12
Python2 did not validate locale correctness when reading input data, so would happily read UTF-8 data in non-UTF-8 locales. Python3 is strict so if you try to read UTF-8 data in the C locale, it will raise an error for any UTF-8 bytes that aren't representable in 7-bit ascii encoding. e.g. UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 54: ordinal not in range(128) Traceback (most recent call last): File "/tmp/qemu-test/src/scripts/qapi-commands.py", line 317, in <module> schema = QAPISchema(input_file) File "/tmp/qemu-test/src/scripts/qapi.py", line 1468, in __init__ parser = QAPISchemaParser(open(fname, 'r')) File "/tmp/qemu-test/src/scripts/qapi.py", line 301, in __init__ previously_included) File "/tmp/qemu-test/src/scripts/qapi.py", line 348, in _include exprs_include = QAPISchemaParser(fobj, previously_included, info) File "/tmp/qemu-test/src/scripts/qapi.py", line 271, in __init__ self.src = fp.read() File "/usr/lib64/python3.5/encodings/ascii.py", line 26, in decode return codecs.ascii_decode(input, self.errors)[0] More background on this can be seen in https://www.python.org/dev/peps/pep-0538/ Many distros support a new C.UTF-8 locale that is like the C locale, but with UTF-8 instead of 7-bit ASCII. That is not entirely portable though. This patch thus sets the LANG to "C", but overrides LC_CTYPE to be en_US.UTF-8 locale. This gets us pretty close to C.UTF-8, but in a way that should be portable to everywhere QEMU builds. This patch only forces UTF-8 for QAPI scripts, since that is the one showing the immediate error under Python3 with C locale, but potentially we ought to force this for all python scripts used in the build process. Signed-off-by: Daniel P. Berrange <berrange@redhat.com> Message-Id: <20180116134217.8725-9-berrange@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>