- 19 10月, 2017 1 次提交
-
-
由 Pavel Hrdina 提交于
Reviewed-by: NJohn Ferlan <jferlan@redhat.com> Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 18 10月, 2017 1 次提交
-
-
由 Peter Krempa 提交于
The file object is needed when formatting the command line, but it makes nesting of the objects less easy for use with blockdev. Separate the wrapping into the 'file' object into a helper used specifically for disk sources in the old code path.
-
- 16 10月, 2017 2 次提交
-
-
由 Daniel P. Berrange 提交于
The default_tls_x509_verify (and related) parameters in qemu.conf control whether the QEMU TLS servers request & verify certificates from clients. This works as a simple access control system for servers by requiring the CA to issue certs to permitted clients. This use of client certificates is disabled by default, since it requires extra work to issue client certificates. Unfortunately the code was using this configuration parameter when setting up both TLS clients and servers in QEMU. The result was that TLS clients for character devices and disk devices had verification turned off, meaning they would ignore errors while validating the server certificate. This allows for trivial MITM attacks between client and server, as any certificate returned by the attacker will be accepted by the client. This is assigned CVE-2017-1000256 / LSN-2017-0002 Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
This adds a rule to require https links for the libvirt, qemu and kvm websites. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 05 10月, 2017 4 次提交
-
-
由 Michal Privoznik 提交于
https://bugzilla.redhat.com/show_bug.cgi?id=1447169 Since domain can have at most one watchdog it simplifies things a bit. However, since we must be able to set the watchdog action as well, new monitor command needs to be used. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJohn Ferlan <jferlan@redhat.com>
-
由 Peter Krempa 提交于
Apart from not littering the command line generator, the added benefit is that new configs with a FDC will be rejected at define stage.
-
由 Peter Krempa 提交于
Remove validation code into a separate function so that it's not interleaved with actual building of the command line.
-
由 Michal Privoznik 提交于
Similarly to previous patch, for some types of interface domain and host are on the same side of RX/TX barrier. In that case, we need to set up the QoS differently. Well, swapped. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJohn Ferlan <jferlan@redhat.com>
-
- 04 10月, 2017 1 次提交
-
-
由 Lin Ma 提交于
qemu 2.7.0 introduces multiqueue virtio-blk(commit 2f27059). This patch introduces a new attribute "queues". An example of the XML: <disk type='file' device='disk'> <driver name='qemu' type='qcow2' queues='4'/> The corresponding QEMU command line: -device virtio-blk-pci,scsi=off,num-queues=4,id=virtio-disk0 Signed-off-by: NLin Ma <lma@suse.com> Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
- 28 9月, 2017 1 次提交
-
-
由 Ashish Mittal 提交于
Alter qemu command line generation in order to possibly add TLS for a suitably configured domain. Sample TLS args generated by libvirt - -object tls-creds-x509,id=objvirtio-disk0_tls0,dir=/etc/pki/qemu,\ endpoint=client,verify-peer=yes \ -drive file.driver=vxhs,file.tls-creds=objvirtio-disk0_tls0,\ file.vdisk-id=eb90327c-8302-4725-9e1b-4e85ed4dc251,\ file.server.type=tcp,file.server.host=192.168.0.1,\ file.server.port=9999,format=raw,if=none,\ id=drive-virtio-disk0,cache=none \ -device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\ id=virtio-disk0 Update the qemuxml2argvtest with a couple of examples. One for a simple case and the other a bit more complex where multiple VxHS disks are added where at least one uses a VxHS that doesn't require TLS credentials and thus sets the domain disk source attribute "tls = 'no'". Update the hotplug to be able to handle processing the tlsAlias whether it's to add the TLS object when hotplugging a disk or to remove the TLS object when hot unplugging a disk. The hot plug/unplug code is largely generic, but the addition code does make the VXHS specific checks only because it needs to grab the correct config directory and generate the object as the command line would do. Signed-off-by: NAshish Mittal <Ashish.Mittal@veritas.com> Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
-
- 21 9月, 2017 1 次提交
-
-
由 Michal Privoznik 提交于
The virSocketAddrFormat() allocates the string and it's caller responsibility to free it afterwards. ==28857== 11 bytes in 1 blocks are definitely lost in loss record 37 of 168 ==28857== at 0x4C2BEDF: malloc (vg_replace_malloc.c:299) ==28857== by 0x9A81D79: strdup (in /lib64/libc-2.23.so) ==28857== by 0x5DA3BF0: virStrdup (virstring.c:902) ==28857== by 0x5D96182: virSocketAddrFormatFull (virsocketaddr.c:427) ==28857== by 0x5D95E13: virSocketAddrFormat (virsocketaddr.c:352) ==28857== by 0x5706890: qemuBuildHostNetStr (qemu_command.c:3891) ==28857== by 0x57138D3: qemuBuildInterfaceCommandLine (qemu_command.c:8597) ==28857== by 0x5713D6A: qemuBuildNetCommandLine (qemu_command.c:8699) ==28857== by 0x57176F6: qemuBuildCommandLine (qemu_command.c:10027) ==28857== by 0x5769D61: qemuProcessCreatePretendCmd (qemu_process.c:6004) ==28857== by 0x4056EC: testCompareXMLToArgv (qemuxml2argvtest.c:502) ==28857== by 0x41DF40: virTestRun (testutils.c:180) Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NJohn Ferlan <jferlan@redhat.com>
-
- 20 9月, 2017 2 次提交
-
-
由 Ashish Mittal 提交于
The VxHS block device will only use the newer formatting options and avoid the legacy URI syntax. An excerpt for a sample QEMU command line is: -drive file.driver=vxhs,file.vdisk-id=eb90327c-8302-4725-9e1b-4e85ed4dc251,\ file.server.type=tcp,file.server.host=192.168.0.1,\ file.server.port=9999,format=raw,if=none,id=drive-virtio-disk0,cache=none \ -device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\ id=virtio-disk0 Update qemuxml2argvtest with a simple test. Signed-off-by: NAshish Mittal <Ashish.Mittal@veritas.com> Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
-
由 Ashish Mittal 提交于
Add a new virStorageNetProtocol for Veritas HyperScale (VxHS) disks Signed-off-by: NAshish Mittal <Ashish.Mittal@veritas.com> Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
-
- 18 9月, 2017 1 次提交
-
-
由 Michal Privoznik 提交于
https://bugzilla.redhat.com/show_bug.cgi?id=1075520 Apart from generic checks, we need to constrain netmask/prefix length a bit. Thing is, with current implementation QEMU needs to be able to 'assign' some IP addresses to the virtual network. For instance, the default gateway is at x.x.x.2, dns is at x.x.x.3, the default DHCP range is x.x.x.15-x.x.x.30. Since we don't expose these settings yet, it's safer to require shorter prefix to have room for the defaults. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: laine@laine.org
-
- 12 9月, 2017 1 次提交
-
-
由 Michal Privoznik 提交于
If there was an error when constructing the buffer, NULL is returned. The buffer is never freed though. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 07 9月, 2017 1 次提交
-
-
由 Andrea Bolognani 提交于
Add a 'cleanup' label and improve the readability of one of the checks by making it conform to our formatting standard and moving the corresponding comment. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NLaine Stump <laine@laine.org>
-
- 05 9月, 2017 1 次提交
-
-
由 Cole Robinson 提交于
Will be needed for future patches to pull the default video type setting out of XML parsing routines. Signed-off-by: NCole Robinson <crobinso@redhat.com>
-
- 29 8月, 2017 2 次提交
-
-
由 Martin Kletzander 提交于
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1449712Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
由 Pavel Hrdina 提交于
The reconnect attribute for chardev devices in QEMU is used to configure the reconnect timeout in seconds. Setting '0' value disables the reconnect functionality thus we don't allow to set '0' for QEMU. To disable the reconnect user should use <reconnect enabled='no'/>. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1254971Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 27 8月, 2017 1 次提交
-
-
由 Cole Robinson 提交于
Both of these are dead code: qemu_command.c explicitly rejects VIRT_XEN earlier in the call chain, and qemu_parse_command.c will never set VIRT_XEN anymore Reviewed-by: NJohn Ferlan <jferlan@redhat.com> Signed-off-by: NCole Robinson <crobinso@redhat.com>
-
- 10 8月, 2017 1 次提交
-
-
由 Michal Privoznik 提交于
https://bugzilla.redhat.com/show_bug.cgi?id=1458638 This code is so complicated because we allow enabling the same bits at many places. Just like in this case: huge pages can be enabled by global <hugepages/> element under <memoryBacking> or on per <memory/> basis. To complicate things a bit more, users are allowed to omit the page size which case the default page size is used. And this is what is causing this bug. If no page size is specified, @pagesize is keeping value of zero throughout whole function. Therefore we need yet another boolean to hold [use, don't use] information as we can't sue @pagesize for that. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com> Reviewed-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 03 8月, 2017 3 次提交
-
-
由 Cole Robinson 提交于
The code only currently handles writing an x86 default -cpu argument, and doesn't know anything about other architectures. Let's make this explicit rather than leaving ex. qemu ppc64 to throw an error about -cpu qemu64 Reviewed-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NCole Robinson <crobinso@redhat.com>
-
由 Cole Robinson 提交于
Certain XML features that aren't in the <cpu> block map to -cpu flags on the qemu cli. If one of these is specified but the user didn't explicitly pass an XML <cpu> model, we need to format a default model on the command line. The current code handles this by sprinkling this default cpu handling among all the different flag string formatting. Instead, switch it to do this just once. This alters some test output slightly: the previous code would write the default -cpu in some cases when no flags were actually added, so the output was redundant. Reviewed-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NCole Robinson <crobinso@redhat.com>
-
由 Nikolay Shirokovskiy 提交于
Disk serial schema has extra '.+' allowed characters in comparison with check in code. Looks like there is no reason for that as qemu allows any character AFAIK for serial. This discrepancy is originated in commit id '85d15b51' where the ability to add serial was added. Alter the disk-serial test to add a disk with all the possible characters listed as the serial value.
-
- 02 8月, 2017 2 次提交
-
-
由 Michal Privoznik 提交于
https://bugzilla.redhat.com/show_bug.cgi?id=1462653 Just like I've added support for setting rx_queue_size (in c56cdf25 and friends), qemu just gained support for setting tx ring size. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Martin Kletzander 提交于
Since the introduction of shmem, there was a split of preparation code from the formatting code from qemuBuildCommandLine() into qemuProcessPrepareDomain(). Let's fix shmem in this regard, so that we can slowly get to a cleaner codebase. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 27 7月, 2017 1 次提交
-
-
由 Pavel Hrdina 提交于
If a domain name contains a '=' and the unix socket path is auto-generated or socket path provided by user contains '=' QEMU is unable to properly parse the command line. In order to make it work we need to use the new command line syntax for VNC if it's available, otherwise we can use the old syntax. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1352529Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 25 7月, 2017 1 次提交
-
-
由 Andrea Bolognani 提交于
The original name didn't hint at the fact that PHBs are a pSeries-specific concept. Suggested-by: NPeter Krempa <pkrempa@redhat.com> Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 24 7月, 2017 3 次提交
-
-
由 Peter Krempa 提交于
Currently, @port is type of string. Well, that's overkill and waste of memory. Port is always an integer. Use it as such. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Peter Krempa 提交于
Since we now set the default ports when parsing disks, it's not necessary to have default port numbers encoded in the command line generator.
-
由 Peter Krempa 提交于
Move it to virstring.c and improve it to parse and validate ports. New name is virStringParsePort.
-
- 22 7月, 2017 1 次提交
-
-
由 Andrea Bolognani 提交于
The call to qemuBuildDeviceAddressStr() happens no matter what, so we can move it to the outer possible scope inside the function. We can also move the call to virBufferAsprintf() after all the checks have been performed, where it makes more sense. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 21 7月, 2017 1 次提交
-
-
由 Shivaprasad G Bhat 提交于
This patch addresses the same aspects on PPC the bug 1103314 addressed on x86. PCI expander bus creates multiple primary PCI busses, where each of these busses can be assigned a specific NUMA affinity, which, on x86 is advertised through ACPI on a per-bus basis. For SPAPR, a PHB's NUMA affinities are assigned on a per-PHB basis, and there is no mechanism for advertising NUMA affinities to a guest on a per-bus basis. So, even if qemu-ppc manages to get some sort of multi-bus topology working using PXB, there is no way to expose the affinities of these busses to the guest. It can only be exposed on a per-PHB/per-domain basis. So patch enables NUMA node tag in pci-root controller on PPC. The way to set the NUMA node is through the numa_node option of spapr-pci-host-bridge device. However for the implicit PHB, the only way to set the numa_node is from the -global option. The -global option applies to all the PHBs unless explicitly specified with the option on the respective PHB of CLI. The default PHB has the emulated devices only, so the patch prevents setting the NUMA node for the default PHB. Signed-off-by: NShivaprasad G Bhat <sbhat@linux.vnet.ibm.com> Reviewed-by: NAndrea Bolognani <abologna@redhat.com>
-
- 15 7月, 2017 4 次提交
-
-
由 Andrea Bolognani 提交于
Additional PHBs (pci-root controllers) will be created for the guest using the spapr-pci-host-bridge QEMU device, if available; the implicit default PHB, while present in the guest configuration, will be skipped. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1431193Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NLaine Stump <laine@laine.org>
-
由 Andrea Bolognani 提交于
Usually, a controller with alias 'x' will create a bus with the same name; however, the bus created by a PHBs with alias 'x' will be named 'x.0' instead, so we need to account for that. As an exception to the exception, the implicit PHB that's added automatically to every pSeries guest creates the 'pci.0' bus. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NLaine Stump <laine@laine.org>
-
由 Andrea Bolognani 提交于
Moving the check and rewriting it this way doesn't alter the current behavior, but will allow us to special-case pci-root down the line. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NLaine Stump <laine@laine.org>
-
由 Andrea Bolognani 提交于
We will soon need to be able to return a NULL pointer without the caller considering that an error: to make it possible, change the return type to int and use an out parameter for the string instead. Add some documentation for the function as well. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NLaine Stump <laine@laine.org>
-
- 14 7月, 2017 3 次提交
-
-
由 Peter Krempa 提交于
Rename it to qemuBlockStorageSourceGetBackendProps and refactor it to return the JSON object instead of filling a pointer since now it's always expected to return data.
-
由 Peter Krempa 提交于
Pure code movement except for the tweaks necessary for cross-usage.
-
由 Peter Krempa 提交于
Add logic which will call qemuGetDriveSourceProps only in cases where we need the JSON representation. This will allow qemuGetDriveSourceProps to generate the JSON representation for all possible disk sources.
-