Blob Blame Raw
From 7000ac85100400a686b48562d830c7b14a439a94 Mon Sep 17 00:00:00 2001
From: Miroslav Rezanina <mrezanin@redhat.com>
Date: Mon, 11 Sep 2017 07:11:00 +0200
Subject: Initial redhat build

This patch introduces redhat build structure in redhat subdirectory. In addition,
several issues are fixed in QEMU tree:

- Change of app name for sasl_server_init in VNC code from qemu to qemu-kvm
 - As we use qemu-kvm as name in all places, this is updated to be consistent
- Man page renamed from qemu to qemu-kvm
 - man page is installed using make install so we have to fix it in qemu tree
- Use "/share/qemu-kvm" as SHARE_SUFFIX
 - We reconfigured our share to qemu-kvm to be consistent with used name
- Added .gitpublish configuration file
 - Support for git publish has to be stored in repository root

--
Rebase notes for RHEL-8 (2.12.0):
- Conflict fix in .gitpublish
- Not packaging hppa-firmware.img
- Disable vxhs.o in block/Makefile.obj
- Disable ppc64 builds
- Removed acpi-dsdt.aml (upstream)
- dropped libjpeg build requirement
- Replaced buildrequirement librados2 and librbd1 by librados and librbd.
- dropping "-pie -fPIE -DPIE" as we're using --enable-pie
- Do not use tcmmaloc
- Dropping gperftools-devel dependency

Rebase notes for RHEL-8.0 (2.11.0):
- Removed references to rhel6 rom files (virtio.rom, pcnet, rtl8139,
                                         net2k_pci e1000, bios-256k,
                                         pxe-e1000e.rom)
- Removed 80-kvm.rules file
- Changing ipxe linking to match upstream
- Updating kvm.modules and ksmtuned files
- cleaning %kvm_files section
- Remove CONFIG_RHV
- Remove CONFIG_LIVE_BLOCK_OPS
- Removing CONFIG_VTD
- Moving vxhs related changes to another commit
- removed live-block-migration option

Rebase notes (2.11.0):
- Removed --with-pixman configure option (upstream)
- Enabling multipath for qemu-pr-helper
- Removed qemu-kvm-tools
- Removed references to "-rhev" and "-ma"
- Removing kvm-unit-tests
- Enabling qemu-geust-agent

Rebase notes (2.10.0):
- live_block_migration option added upstream
- moved qmp-spec.txt file (upstream)
- added s390-netboot.img (added upstream)
- removed qemu_vga.ndrv (added upstream)
- switch to (rhevh-)rhel-7.5-candidate
- switched differentiation defaults
- moved binary files to separate commit

Rebase notes (2.9.0):
- documentation files handling changes (upstrem)
- removed --enable-colo option and --disable-archipelago (upstream)
- bump BuildRequires versions
- new mandatory argument for tracetool.py (upstream)
- updated RHEL 6 roms
- switch from sha1sum to sha256sum
- Moved adding rhel6-e1000.rom from machine types commit
- Moved adding pxe-e1000e.rom from device disable commit
- Use rdma-core instead of librdmacm
- Add upstream tarballs tar.xz to .gitignore
- Updated git-backport-diff script

Rebase notes (2.8.0):
- removed vhdx option (upstream)
- qemu-tech.html merged to qemu-doc.html (upstream)
- removed skiboot.lid firmware
- Changed tracetool.py parameters
- Added support for easy z-stream switch

Rebase notes (2.7.0):
- removed kvm_stat
- added efi-e1000e.rom
- added efi-vmxnet.rom
- added linuxboot_dma.bin
- trace-events renamed to trace-events-all
- reverted dependency to seccomp on aarch64
- Add ipxe-qemu-roms ad build dependency to pass tests

Rebase notes (2.6.0):
- removed q35-acpi-dsdt.aml
- add enable-gcrypt option

Rebase notes (2.5.0):
- New seccomp hadling in configure
- New condition format  in migration/migration.c
- libcacard extracted
- vnc fixes
- libsecomp for aarch64 requirements changed downstream

Rebase notes (2.4.0):
- remove --enable-ws-vnc
- use error_setg instead of error_set in migration/migration.c
- remove target-x86_64.conf
- create /etc/qemu-kvm on copying of bridge.conf
- disabled opengl
- rebased to version 2.3.0-30.el7

- Merged patches (Rebase 2.12.0)
- spec: Change License line
- spec: Do not depend on ipxe for Power architectures
- configuration: Use gcrypt instead of nettle
- spec: Use hardening flags for ksmctl build

Merged patches (rebase 2.11.0)
- ce6e8e5b8a redhat/qemu-kvm.spec.template: Enable seccomp on s390x, too
- 8629f208c6 redhat: Remove qemu.binfmt from the downstream repository
- b889ce1c40 Disable build of qemu-kvm-ma for x86_64
- 4506913c42 redhat: add CONFIG_RHV flag
- 21ecaec46f s390x: vm.allocate_pgste sysctl is no longer needed
- 78a1864d99 Update build_configure for 2.10.0 options
- decf881320 redhat: Provide s390x specific /etc/modprobe.d/kvm.conf
- e0cd3138cc redhat/qemu-kvm.spec: Use the freshly built s390-ccw.img firmware image
- 7af6b9a4fa redhat: install generic kvm.conf except for s390 and x86 architectures
- c4290f50bb redhat: fix rh-srpm target
- 8943f52e8b Package qemu-block-drivers manpage
- 88b41044d6 update spec to build and install qemu-pr-helper

Merged patches (rebase 2.10.0)
- feefd46 qemu-kvm.spec: Enable s390x build
- 985051e Removing texi2html from build requirements
- 7c64a2a Update ignore files for redhat usage
- 8f9a95a Disable replication feature
- 1b7bbc5 block/vxhs: modularize VXHS via g_module
- 7511527 Remove the dependencies to seavgabios-bin and ipxe-roms-qemu on s390x
- aa0891c Downstream: Don't disable SMT on POWER9 hosts
- a13a0e9 Update configuration for qemu 2.9
- bbf46dd disable pulseaudio and alsa
- 9124839 redhat/Makefile: honor BREW_FLAGS like the kernel
- 53c03bd copy SLIT test reference blobs into tests directory
- c4c77e6 Differentiation support
- f1ec0e8 configure: allow to disable VT-d emulation
- b972023 Disable VT-d for rhel builds
- 29a0414 RHEL Diff.: Add option in configure to disable live block ops
- 1f33b29 RHEL Diff.: Unregister live block operations
- c590551 RHEL Diff.: Disable live block operations in HMP monitor
- c7e208f RHEL Diff.: Add rpm spec options for live block ops
- 733af5c pegas: add rpm spec options for vhost-user
- ff16138 Add support for local build
- fb426d4 qemu-kvm.spec: Configure vm.allocate_pgste for s390x

Merged patches (rebase 2.9.0)
- 9c7ab94 Enable seccomp for ppc64/ppc64le architecture
- f6d7e9d Update qemu-kvm package Summary and Description
- a9e55b6 Disable usbredir and libcacard for unsupported architectures
- 0218220 Update configuration for 2.8.0 release

Merged patches (rebase 2.7.0)
- 2be6077 Fix SLOF dependency
- dc58590 spec: Remove dependency to ipxe-roms-qemu for aarch64
- 357ef43 spec: link sgabios.bin only for x86_64
- 08d82cc spec: Update rules before triggering for kvm device
- 8980a76 spec: Do not package ivshmem-server and ivshmem-client
- 027067c spec: add a sample kvm.conf to enable Nested Virtualization
- ba2ba30 Adjust locked memory limits to allow unprivileged VMs on Power
- e9740b0 Increase locked memory limit for all users, not just kvm group
- 8c301be add vgabios-virtio.bin symlink
- 4d03723 usb: enable streams support
- 2a9363e Add install dependency required for usb streams
- 9a54442 Add dump-guest-memory.py to all archs
- 73fffc9 add e1000e ipxe rom symlink
- aaaa2a9 Add 'luks' to block driver whitelist
- c78c3a8 redhat: switch from gcrypt to nettle for crypto
- bb51a69 redhat: include username and date in RPM N-E-V-R for scratch builds

Merged patches (rebase 2.4.0)
- 9201274 spec: Remove obsolete differentiation code
- a938a8c spec: Use external configuration script
- 5ca8d0e spec: Use configure options to prevent default resolution
- 5dca391 spec: Ship complete QMP documentation files
- 7899edd aarch64: allow --enable-seccomp
- a56fb9c aarch64: redhat spec: enable seccomp
- a9571e6 rhel: Update package version for SLOF dependency
- 25c70c4 configure: Add support for tcmalloc
- db72485 Change fsreeze-hook default location
- 14b8a9e redhat: add kvm-unit-tests tarball to environment
- 5ee4238 spec: Build tscdeadline_latency.flat from kvm-unit-tests
- 6ba800b Downstream-only: Start kvm-setup service before libvirtd service
- 59b43d6 Do not stop qemu-guest-agent service on target switch
- 4d851fa provide vhost module config file with max_mem_regions set to 509
- 0b18027 spec: Require proper version of SLOF
- 3c436c7 Fix rh-brew-aarch64, rh-brew-ppc rh-brew-ga-ppc target

(cherry picked from commit ba7591ec4a0906121d15ffbf740580bd79ec5814)
---
 .gitpublish                        |  58 +--
 Makefile                           |   2 +-
 block/Makefile.objs                |   2 +-
 os-posix.c                         |   2 +-
 redhat/.gitignore                  |   5 +
 redhat/85-kvm.preset               |   5 +
 redhat/95-kvm-memlock.conf         |  10 +
 redhat/99-qemu-guest-agent.rules   |   2 +
 redhat/Makefile                    |  88 ++++
 redhat/Makefile.common             |  48 +++
 redhat/Makefile.local              |  76 ++++
 redhat/bridge.conf                 |   1 +
 redhat/build_configure.sh          | 145 +++++++
 redhat/ksm.service                 |  13 +
 redhat/ksm.sysconfig               |   4 +
 redhat/ksmctl.c                    |  77 ++++
 redhat/ksmtuned                    | 139 +++++++
 redhat/ksmtuned.conf               |  21 +
 redhat/ksmtuned.service            |  12 +
 redhat/kvm-s390x.conf              |   7 +
 redhat/kvm-setup                   |  40 ++
 redhat/kvm-setup.service           |  14 +
 redhat/kvm-x86.conf                |  12 +
 redhat/kvm.conf                    |   3 +
 redhat/kvm.modules                 |  18 +
 redhat/qemu-ga.sysconfig           |  19 +
 redhat/qemu-guest-agent.service    |  20 +
 redhat/qemu-kvm.spec.template      | 794 +++++++++++++++++++++++++++++++++++++
 redhat/qemu-pr-helper.service      |  15 +
 redhat/qemu-pr-helper.socket       |   9 +
 redhat/rpmbuild/BUILD/.gitignore   |   2 +
 redhat/rpmbuild/RPMS/.gitignore    |   2 +
 redhat/rpmbuild/SOURCES/.gitignore |   2 +
 redhat/rpmbuild/SPECS/.gitignore   |   2 +
 redhat/rpmbuild/SRPMS/.gitignore   |   2 +
 redhat/scripts/frh.py              |  26 ++
 redhat/scripts/git-backport-diff   | 327 +++++++++++++++
 redhat/scripts/git-compile-check   | 215 ++++++++++
 redhat/scripts/process-patches.sh  |  78 ++++
 redhat/scripts/tarball_checksum.sh |   3 +
 redhat/vhost.conf                  |   3 +
 ui/vnc.c                           |   2 +-
 42 files changed, 2270 insertions(+), 55 deletions(-)
 create mode 100644 redhat/.gitignore
 create mode 100644 redhat/85-kvm.preset
 create mode 100644 redhat/95-kvm-memlock.conf
 create mode 100644 redhat/99-qemu-guest-agent.rules
 create mode 100644 redhat/Makefile
 create mode 100644 redhat/Makefile.common
 create mode 100644 redhat/Makefile.local
 create mode 100644 redhat/bridge.conf
 create mode 100755 redhat/build_configure.sh
 create mode 100644 redhat/ksm.service
 create mode 100644 redhat/ksm.sysconfig
 create mode 100644 redhat/ksmctl.c
 create mode 100644 redhat/ksmtuned
 create mode 100644 redhat/ksmtuned.conf
 create mode 100644 redhat/ksmtuned.service
 create mode 100644 redhat/kvm-s390x.conf
 create mode 100644 redhat/kvm-setup
 create mode 100644 redhat/kvm-setup.service
 create mode 100644 redhat/kvm-x86.conf
 create mode 100644 redhat/kvm.conf
 create mode 100644 redhat/kvm.modules
 create mode 100644 redhat/qemu-ga.sysconfig
 create mode 100644 redhat/qemu-guest-agent.service
 create mode 100644 redhat/qemu-kvm.spec.template
 create mode 100644 redhat/qemu-pr-helper.service
 create mode 100644 redhat/qemu-pr-helper.socket
 create mode 100644 redhat/rpmbuild/BUILD/.gitignore
 create mode 100644 redhat/rpmbuild/RPMS/.gitignore
 create mode 100644 redhat/rpmbuild/SOURCES/.gitignore
 create mode 100644 redhat/rpmbuild/SPECS/.gitignore
 create mode 100644 redhat/rpmbuild/SRPMS/.gitignore
 create mode 100755 redhat/scripts/frh.py
 create mode 100755 redhat/scripts/git-backport-diff
 create mode 100755 redhat/scripts/git-compile-check
 create mode 100755 redhat/scripts/process-patches.sh
 create mode 100755 redhat/scripts/tarball_checksum.sh
 create mode 100644 redhat/vhost.conf

diff --git a/Makefile b/Makefile
index d71dd5b..89ba4c5 100644
--- a/Makefile
+++ b/Makefile
@@ -804,7 +804,7 @@ install-doc: $(DOCS)
 	$(INSTALL_DATA) docs/interop/qemu-qmp-ref.txt "$(DESTDIR)$(qemu_docdir)"
 ifdef CONFIG_POSIX
 	$(INSTALL_DIR) "$(DESTDIR)$(mandir)/man1"
-	$(INSTALL_DATA) qemu.1 "$(DESTDIR)$(mandir)/man1"
+	$(INSTALL_DATA) qemu.1 "$(DESTDIR)$(mandir)/man1/qemu-kvm.1"
 	$(INSTALL_DIR) "$(DESTDIR)$(mandir)/man7"
 	$(INSTALL_DATA) docs/interop/qemu-qmp-ref.7 "$(DESTDIR)$(mandir)/man7"
 	$(INSTALL_DATA) docs/qemu-block-drivers.7 "$(DESTDIR)$(mandir)/man7"
diff --git a/block/Makefile.objs b/block/Makefile.objs
index d644bac..c0693fc 100644
--- a/block/Makefile.objs
+++ b/block/Makefile.objs
@@ -20,7 +20,7 @@ block-obj-$(CONFIG_LIBNFS) += nfs.o
 block-obj-$(CONFIG_CURL) += curl.o
 block-obj-$(CONFIG_RBD) += rbd.o
 block-obj-$(CONFIG_GLUSTERFS) += gluster.o
-block-obj-$(CONFIG_VXHS) += vxhs.o
+#block-obj-$(CONFIG_VXHS) += vxhs.o
 block-obj-$(CONFIG_LIBSSH2) += ssh.o
 block-obj-y += accounting.o dirty-bitmap.o
 block-obj-y += write-threshold.o
diff --git a/os-posix.c b/os-posix.c
index b9c2343..05de8ee 100644
--- a/os-posix.c
+++ b/os-posix.c
@@ -75,7 +75,7 @@ void os_setup_signal_handling(void)
 /* Find a likely location for support files using the location of the binary.
    For installed binaries this will be "$bindir/../share/qemu".  When
    running from the build tree this will be "$bindir/../pc-bios".  */
-#define SHARE_SUFFIX "/share/qemu"
+#define SHARE_SUFFIX "/share/qemu-kvm"
 #define BUILD_SUFFIX "/pc-bios"
 char *os_find_datadir(void)
 {
diff --git a/ui/vnc.c b/ui/vnc.c
index e164eb7..0c3011b 100644
--- a/ui/vnc.c
+++ b/ui/vnc.c
@@ -4045,7 +4045,7 @@ void vnc_display_open(const char *id, Error **errp)
     trace_vnc_auth_init(vd, 1, vd->ws_auth, vd->ws_subauth);
 
 #ifdef CONFIG_VNC_SASL
-    if ((saslErr = sasl_server_init(NULL, "qemu")) != SASL_OK) {
+    if ((saslErr = sasl_server_init(NULL, "qemu-kvm")) != SASL_OK) {
         error_setg(errp, "Failed to initialize SASL auth: %s",
                    sasl_errstring(saslErr, NULL, NULL));
         goto fail;
-- 
1.8.3.1