- 11 6月, 2013 1 次提交
-
-
由 Jiri Denemark 提交于
Avoid leaking virDomainDef if Prepare phase fails before it gets to qemuMigrationPrepareAny.
-
- 10 6月, 2013 1 次提交
-
-
由 Peter Krempa 提交于
This patch fixes changes done in commit 29c1e913 that was pushed without implementing review feedback. The flag introduced by the patch is changed to VIR_DOMAIN_VCPU_GUEST and documentation makes the difference between regular hotplug and this new functionality more explicit. The virsh options that enable the use of the new flag are changed to "--guest" and the documentation is fixed too.
-
- 07 6月, 2013 4 次提交
-
-
由 Michal Privoznik 提交于
Currently, there's a path to use the ncpuinfo variable uninitialized, which leads to a compiler warning: qemu/qemu_driver.c: In function 'qemuDomainGetVcpusFlags': qemu/qemu_driver.c:4573:9: error: 'ncpuinfo' may be used uninitialized in this function [-Werror=maybe-uninitialized] for (i = 0; i < ncpuinfo; i++) { ^
-
由 Peter Krempa 提交于
This patch adds support for agent-based cpu disabling and enabling to qemuDomainSetVcpusFlags() API.
-
由 Peter Krempa 提交于
This patch implements the VIR_DOMAIN_VCPU_AGENT flag for the qemuDomainGetVcpusFlags() libvirt API implementation.
-
由 Peter Krempa 提交于
The 'online' parameter has only two possible values. Use a bool for it.
-
- 06 6月, 2013 1 次提交
-
-
由 Ján Tomko 提交于
Found with 'git grep "= 1"'.
-
- 05 6月, 2013 1 次提交
-
-
由 Guannan Ren 提交于
The work was done at the time of snapshot xmlstring parsing if (offline && def->memory && def->memory != VIR_DOMAIN_SNAPSHOT_LOCATION_NONE) { virReportError(...); }
-
- 03 6月, 2013 1 次提交
-
-
由 Peter Krempa 提交于
The code for arbitrary guest agent passthrough was horribly broken since introduction. Fix it to correctly report errors.
-
- 31 5月, 2013 3 次提交
-
-
由 Peter Krempa 提交于
If snapshot creation failed for example due to invalid use of the "REUSE_EXTERNAL" flag, libvirt killed access to the original image file instead of the new image file. On machines with selinux this kills the whole VM as the selinux context is enforced immediately. * qemu_driver.c:qemuDomainSnapshotUndoSingleDiskActive(): - Kill access to the new image file instead of the old one. Partially resolves: https://bugzilla.redhat.com/show_bug.cgi?id=906639
-
由 Peter Krempa 提交于
After deleting "WithDriver" from the async job function the code was unaligned.
-
由 Eric Blake 提交于
This is a recurring problem for cygwin :) For example, see commit 23a4df88. qemu/qemu_driver.c: In function 'qemuStateInitialize': qemu/qemu_driver.c:691:13: error: format '%d' expects type 'int', but argument 8 has type 'uid_t' [-Wformat] * src/qemu/qemu_driver.c (qemuStateInitialize): Add casts. * daemon/remote.c (remoteDispatchAuthList): Likewise. Signed-off-by: NEric Blake <eblake@redhat.com>
-
- 24 5月, 2013 1 次提交
-
-
由 Martin Kletzander 提交于
Function qemuDomainSetBlockIoTune() was checking QEMU capabilities even when !(flags & VIR_DOMAIN_AFFECT_LIVE) and the domain was shutoff, resulting in the following problem: virsh # domstate asdf; blkdeviotune asdf vda --write-bytes-sec 100 shut off error: Unable to change block I/O throttle error: unsupported configuration: block I/O throttling not supported with this QEMU binary Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=965016
-
- 23 5月, 2013 1 次提交
-
-
由 Michal Privoznik 提交于
-
- 21 5月, 2013 1 次提交
-
-
由 Osier Yang 提交于
-
- 20 5月, 2013 1 次提交
-
-
由 Osier Yang 提交于
Since 0d70656a, it starts to access the sysfs files to build the qemu command line (by virSCSIDeviceGetSgName, which is to find out the scsi generic device name by adpater:bus:target:unit), there is no way to work around, qemu wants to see the scsi generic device like "/dev/sg6" anyway. And there might be other places which need to access sysfs files when building qemu command line in future. Instead of increasing the arguments of qemuBuildCommandLine, this introduces a new callback for qemuBuildCommandLine, and thus tests can register their own callbacks for sysfs test input files accessing. * src/qemu/qemu_command.h: (New callback struct qemuBuildCommandLineCallbacks; extern buildCommandLineCallbacks) * src/qemu/qemu_command.c: (wire up the callback struct) * src/qemu/qemu_driver.c: (Use the new syntax of qemuBuildCommandLine) * src/qemu/qemu_hotplug.c: Likewise * src/qemu/qemu_process.c: Likewise * tests/testutilsqemu.[ch]: (Helper testSCSIDeviceGetSgName; callback struct testCallbacks;) * tests/qemuxml2argvtest.c: (Use testCallbacks) * src/tests/qemuxmlnstest.c: (Like above)
-
- 17 5月, 2013 3 次提交
-
-
由 Martin Kletzander 提交于
Commit 632f78ca introduced a regression which causes schedinfo being unable to set some parameters. When migrating to priv->cgroup there was missing variable left out and due to passed NULL to underlying function, the setting failed. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=963592
-
由 Osier Yang 提交于
Just like what previous patches do, it refactors qemuSetUnprivSGIO to take the virDomainDeviceDefPtr as argument instead.
-
由 Osier Yang 提交于
This changes the helpers qemu{Add,Remove}SharedDisk into qemu{Add,Remove}SharedDevice, as most of the code in the helpers can be reused for scsi host device. To track the shared scsi host device, first it finds out the device path (e.g. /dev/s[dr]*) which is mapped to the sg device, and use device ID of the found device path (/dev/s[dr]*) as the hash key. This is because of the device ID is not unique between between /dev/s[dr]* and /dev/sg*, e.g. % sg_map /dev/sg0 /dev/sda /dev/sg1 /dev/sr0 % ls -l /dev/sda brw-rw----. 1 root disk 8, 0 May 2 19:26 /dev/sda %ls -l /dev/sg0 crw-rw----. 1 root disk 21, 0 May 2 19:26 /dev/sg0
-
- 16 5月, 2013 1 次提交
-
-
由 Osier Yang 提交于
"Shared disk" is not only the thing we should care about after "scsi hostdev" is introduced. A same scsi device can be used as "disk" for one domain, and as "scsi hostdev" for another domain at the same time. That's why this patch renames qemu_driver->sharedDisks. Related functions and structs are also renamed.
-
- 15 5月, 2013 2 次提交
-
-
由 John Ferlan 提交于
-
由 Martin Kletzander 提交于
Adding a VNC WebSocket support for QEMU driver. This functionality is in upstream qemu from commit described as v1.3.0-982-g7536ee4, so the capability is being recognized based on QEMU version for now.
-
- 13 5月, 2013 1 次提交
-
-
由 Han Cheng 提交于
Although virtio-scsi supports SCSI PR (Persistent Reservations), the device on host may do not support it. To avoid losing data, Just like PCI and USB pass through devices, only one live guest is allowed per SCSI host pass through device." Signed-off-by: NHan Cheng <hanc.fnst@cn.fujitsu.com>
-
- 11 5月, 2013 2 次提交
-
-
由 Daniel P. Berrange 提交于
It is possible to build a kernel without swap cgroup controls present. This causes a fatal error when querying memory parameters. Treat missing swap controls as meaning "unlimited". The fatal error remains if the user tries to actually change the limit. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Laine Stump 提交于
This resolves: https://bugzilla.redhat.com/show_bug.cgi?id=851411 https://bugzilla.redhat.com/show_bug.cgi?id=955500 The first problem was that virFileOpenAs was returning fd (-1) in one of the error cases rather than ret (-errno), so the caller thought that the error was EPERM rather than ENOENT. The second problem was that some log messages in the general purpose qemuOpenFile() function would always say "Failed to create" even if the caller hadn't included O_CREAT (i.e. they were trying to open an existing file). This fixes virFileOpenAs to jump down to the error return (which returns ret instead of fd) in the previously mentioned incorrect failure case of virFileOpenAs(), removes all error logging from virFileOpenAs() (since the callers report it), and modifies qemuOpenFile to appropriately use "open" or "create" in its log messages. NB: I seriously considered removing logging from all callers of virFileOpenAs(), but there is at least one case where the caller doesn't want virFileOpenAs() to log any errors, because it's just going to try again (qemuOpenFile()). We can't simply make a silent variation of virFileOpenAs() though, because qemuOpenFile() can't make the decision about whether or not it wants to retry until after virFileOpenAs() has already returned an error code. Likewise, I also considered changing virFileOpenAs() to return -1 with errno set on return, and may still do that, but only as a separate patch, as it obscures the intent of this patch too much.
-
- 09 5月, 2013 1 次提交
-
-
由 Ján Tomko 提交于
The controller element supports non-disk controller types too. https://bugzilla.redhat.com/show_bug.cgi?id=960958
-
- 08 5月, 2013 5 次提交
-
-
由 Daniel P. Berrange 提交于
The LXC, QEMU, and LibXL drivers have all merged their handling of the attach/update/modify device APIs into one large 'xxxxDomainModifyDeviceFlags' which then does a 'switch()' based on the actual API being invoked. While this saves some lines of code, it is not really all that significant in the context of the driver API impls as a whole. This merger of the handling of different APIs creates pain when wanting to automated analysis of the code and do things which are specific to individual APIs. The slight duplication of code from unmerged the API impls, is preferrable to allow for easier automated analysis. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Currently the parsing of XML is pushed down into the various migration helper APIs. This makes it difficult to insert the correct access control checks, since one helper API services many public APIs. Pull the parsing of XML up to the top level of the QEMU driver APIs
-
由 Daniel P. Berrange 提交于
The individual hypervisor drivers were directly referencing APIs in virnodesuspend.c in their virDriverPtr struct. Separate these methods, so there is always a wrapper in the hypervisor driver. This allows the unused virConnectPtr args to be removed from the virnodesuspend.c file. Again this will ensure that ACL checks will only be performed on invocations that are directly associated with public API usage. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
The individual hypervisor drivers were directly referencing APIs in src/nodeinfo.c in their virDriverPtr struct. Separate these methods, so there is always a wrapper in the hypervisor driver. This allows the unused virConnectPtr args to be removed from the nodeinfo.c file. Again this will ensure that ACL checks will only be performed on invocations that are directly associated with public API usage. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Currently the virGetHostname() API has a bogus virConnectPtr parameter. This is because virtualization drivers directly reference this API in their virDriverPtr tables, tieing its API design to the public virConnectGetHostname API design. This also causes problems for access control checks since these must only be done for invocations from the public API, not internal invocation. Remove the bogus virConnectPtr parameter, and make each hypervisor driver provide a dedicated function for the driver API impl. This will allow access control checks to be easily inserted later. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 07 5月, 2013 1 次提交
-
-
由 Peter Krempa 提交于
When attempting to generate the native command line from an XML file that uses graphics port auto allocation, the generated commandline wouldn't be valid. This patch adds fake autoallocation of ports as done when starting the actual machine.
-
- 02 5月, 2013 2 次提交
-
-
由 Michal Privoznik 提交于
The source code base needs to be adapted as well. Some files include virutil.h just for the string related functions (here, the include is substituted to match the new file), some include virutil.h without any need (here, the include is removed), and some require both.
-
由 Laine Stump 提交于
virPCIDeviceReattach and virPCIDeviceUnbindFromStub (called by virPCIDeviceReattach) had previously required the name of the stub driver as input. This is unnecessary, because the name of the driver the device is currently bound to can be found by looking at the link: /sys/bus/pci/dddd:bb:ss.ff/driver Instead of requiring that the name of the expected stub driver name and only unbinding if that one name is matched, we no longer take a driver name in the arglist for either of these functions. virPCIDeviceUnbindFromStub just compares the name of the currently bound driver to a list of "well known" stubs (right now contains "pci-stub" and "vfio-pci" for qemu, and "pciback" for xen), and only performs the unbind if it's one of those devices. This allows virsh nodedevice-reattach to work properly across a libvirtd restart, and fixes a couple of cases where we were erroneously still hard-coding "pci-stub" as the drive name. For some unknown reason, virPCIDeviceReattach had been calling modprobe on the stub driver prior to unbinding the device. This was problematic because we no longer know the name of the stub driver in that function. However, it is pointless to probe for the stub driver at that time anyway - because the device is bound to the stub driver, we are guaranteed that it is already loaded, and so that call to modprobe has been removed.
-
- 30 4月, 2013 1 次提交
-
-
由 Ján Tomko 提交于
This adds addresses to domxml-to-native output and chooses the correct virtio devices for ccw and s390 machines. https://bugzilla.redhat.com/show_bug.cgi?id=957077
-
- 26 4月, 2013 1 次提交
-
-
由 Laine Stump 提交于
The differences from virNodeDeviceDettach are very minor: 1) Check that the flags are 0. 2) Set the virPCIDevice's stubDriver according to the driverName that is passed in. 3) Call virPCIDeviceDetach with a NULL stubDriver, indicating it should get the name of the stub driver from the virPCIDevice object.
-
- 25 4月, 2013 1 次提交
-
-
由 Wido den Hollander 提交于
This for example prohibits you to use iotune for Ceph or Sheepdog devices. Signed-off-by: NWido den Hollander <wido@widodh.nl>
-
- 24 4月, 2013 2 次提交
-
-
由 Daniel P. Berrange 提交于
Ensure that all drivers implementing public APIs use a naming convention for their implementation that matches the public API name. eg for the public API virDomainCreate make sure QEMU uses qemuDomainCreate and not qemuDomainStart Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Ensure that the driver struct field names match the public API names. For an API virXXXX we must have a driver struct field xXXXX. ie strip the leading 'vir' and lowercase any leading uppercase letters. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 23 4月, 2013 1 次提交
-
-
由 Peter Krempa 提交于
Refactoring done in 19c6ad9a didn't correctly take into account the order cgroup limit modification needs to be done in. This resulted into errors when decreasing the limits. The operations need to take place in this order: decrease hard limit change swap hard limit or change swap hard limit increase hard limit This patch also fixes the check if the hard_limit is less than swap_hard_limit to print better error messages. For this purpose I introduced a helper function virCompareLimitUlong to compare limit values where value of 0 is equal to unlimited. Additionally the check is now applied also when the user does not provide all of the tunables through the API and in that case the currently set values are used. This patch resolves: https://bugzilla.redhat.com/show_bug.cgi?id=950478
-