- 26 2月, 2016 1 次提交
-
-
由 Ján Tomko 提交于
Revert commit 55e6d8cd. This fix for https://bugzilla.redhat.com/show_bug.cgi?id=1267256 unconditionally required a machine type for all machine types even though qemu is the only emulator using them. Revert it to fix persistent configs for drivers with no machine type: https://www.redhat.com/archives/libvir-list/2016-February/msg01228.html
-
- 22 2月, 2016 2 次提交
-
-
由 Martin Kletzander 提交于
Checking whether x > 0 before looping over [0..x] items doesn't make sense and multi-line body must have curly brackets around it. Best viewed with '-w'. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
由 Michal Privoznik 提交于
There's a check if a domain definition has any graphics card and if so, we iterate over each one of them. This makes no sense, because even if it has none we can still iterate over. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 19 2月, 2016 2 次提交
-
-
由 Cole Robinson 提交于
Seems like the natural fit, since we are already adding other XML bits in the PostParse routine. Previously AddImplicitControllers was only called at the end of XML parsing, meaning code that builds a DomainDef by hand had to manually call it. Now those PostParse callers get it for free. There's some test churn here; xen xm and sexpr test suite bits weren't calling this before, but now they are, so you'll see new IDE controllers. I don't think this will cause problems in practice, since the code already needs to handle these implicit controllers like in the case when a user defines their own XML.
-
由 Jiri Denemark 提交于
virDomainObjWait is designed to be called in a loop. Make sure we break the loop in case the domain dies to avoid waiting for an event which will never happen. Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
-
- 18 2月, 2016 1 次提交
-
-
由 Ján Tomko 提交于
Commit f1a89a8b allowed parsing configs from /etc/libvirt without validating the emulator capabilities. Check for the presence of os->type.machine even if the VIR_DOMAIN_DEF_PARSE_SKIP_OSTYPE_CHECKS flag is set, otherwise the daemon can crash on carelessly crafted input in the config directory. https://bugzilla.redhat.com/show_bug.cgi?id=1267256
-
- 17 2月, 2016 1 次提交
-
-
由 Andrea Bolognani 提交于
Since no value in the virGICVersion enumeration is negative, a clever enough compiler can report an error such as src/conf/domain_conf.c:15337:75: error: comparison of unsigned enum expression < 0 is always false [-Werror,-Wtautological-compare] if ((def->gic_version = virGICVersionTypeFromString(tmp)) < 0 || ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~ virGICVersionTypeFromString() can, however, return a negative value if the input string is not part of the enumeration, so we definitely need that check. Work around the problem by storing the return value in a temporary int variable.
-
- 16 2月, 2016 1 次提交
-
-
由 Andrea Bolognani 提交于
Instead of allowing any random positive number, restrict the possible values to the ones that are part of the virGICVersion enumeration.
-
- 10 2月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
Older gcc fails to see that the variable is set iff @hasPriority == true in which case the former is set a value. Initialize the value while declaring it to make the compiler shut up. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 08 2月, 2016 9 次提交
-
-
由 Peter Krempa 提交于
Similarly to previous commit change the way how iothread scheduler info is stored and clean up a lot of unnecessary code.
-
由 Peter Krempa 提交于
Due to bad design the vcpu sched element is orthogonal to the way how the data belongs to the corresponding objects. Now that vcpus are a struct that allow to store other info too, let's convert the data to the sane structure. The helpers for the conversion are made universal so that they can be reused for iothreads too. This patch also resolves https://bugzilla.redhat.com/show_bug.cgi?id=1235180 since with the correct storage approach you can't have dangling data.
-
由 Peter Krempa 提交于
virDomainDefFormatInternal is growing rather large. Extract the cputune formatter into a separate function.
-
由 Peter Krempa 提交于
Now that the pinning info is stored elsewhere we can delete all the obsolete code.
-
由 Peter Krempa 提交于
Now with the new struct the data can be stored in a much saner place.
-
由 Peter Krempa 提交于
This step can be omitted, so that drivers can decide what to do when the user requests to use default vcpu pinning.
-
由 Peter Krempa 提交于
Move the logic from virDomainDiskDefDstDuplicates into virDomainDiskDefCheckDuplicateInfo so that we don't have to loop multiple times through the array of disks. Since the original function was called in qemuBuildDriveDevStr, it was actually called for every single disk which was quite wasteful. Additionally the target uniqueness check needed to be duplicated in the disk hotplug case, since the disk was inserted into the domain definition after the device string was formatted and thus virDomainDiskDefDstDuplicates didn't do anything in that case.
-
由 Peter Krempa 提交于
We do the check on VM start, but the user could still hotplug a disk with a conflicting serial or WWN. Reuse the checker function to fix the issue.
-
由 Peter Krempa 提交于
Put it into a separate function that can be called on two disk def pointers.
-
- 05 2月, 2016 3 次提交
-
-
由 Peter Krempa 提交于
As the scheduler info elements are represented orthogonally to how it makes sense to actually store the information, the extracted code will be later used when converting between XML and internal definitions.
-
由 Peter Krempa 提交于
-
由 Daniel P. Berrange 提交于
The virDomainObjFormat and virDomainSaveStatus methods both call into virDomainDefFormat, so should be providing a non-NULL virCapsPtr instance. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 04 2月, 2016 3 次提交
-
-
由 Joao Martins 提交于
virDomainSaveConfig calls virDomainDefFormat which was setting the caps to NULL, thus keeping the old behaviour (i.e. not looking at netprefix). This patch adds the virCapsPtr to the function and allows the configuration to be saved and skipping interface names that were registered with virCapabilitiesSetNetPrefix(). Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
-
由 Joao Martins 提交于
And use the newly added caps->host.netprefix (if it exists) for interface names that match the autogenerated target names. Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
-
由 Joao Martins 提交于
And use the newly added caps->host.netprefix for free interface names that match the autogenerated target names. Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
-
- 03 2月, 2016 3 次提交
-
-
由 Ján Tomko 提交于
Do not store the return value of virDomainParseScaledValue, it was overwritten anyway. Delete the cleanup label, there is nothing to clean up.
-
由 Peter Krempa 提交于
-
由 Peter Krempa 提交于
In some cases it may be better to have a bitmap representing state of individual vcpus rather than iterating the definition. The new helper creates a bitmap representing the state from the domain definition.
-
- 28 1月, 2016 2 次提交
-
-
由 Peter Krempa 提交于
It's disallowed in the API.
-
由 Peter Krempa 提交于
They are disallowed in the pinning API and as default cpuset. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1293241
-
- 27 1月, 2016 1 次提交
-
-
由 Pavel Hrdina 提交于
The current code was a little bit odd. At first we've removed all possible implicit input devices from domain definition to add them later back if there was any graphics device defined while parsing XML description. That's not all, while formating domain definition to XML description we at first ignore any input devices with bus different to USB and VIRTIO and few lines later we add implicit input devices to XML. This seems to me as a lot of code for nothing. This patch may look to be more complicated than original approach, but this is a preferred way to modify/add driver specific stuff only in those drivers and not deal with them in common parsing/formating functions. The update is to add those implicit input devices into config XML to follow the real HW configuration visible by guest OS. There was also inconsistence between our behavior and QEMU's in the way, that in QEMU there is no way how to disable those implicit input devices for x86 architecture and they are available always, even without graphics device. This applies also to XEN hypervisor. VZ driver already does its part by putting correct implicit devices into live XML. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 14 1月, 2016 1 次提交
-
-
由 John Ferlan 提交于
Commit id '7bf3198d' neglected to initialize deflate leading to a possibility if model allocation/checks fail, then the VIR_FREE(deflate) would be erroneous. Noted by Jan Tomko.
-
- 12 1月, 2016 3 次提交
-
-
由 Dmitry Andreev 提交于
Excessive memory balloon inflation can cause invocation of OOM-killer, when Linux is under severe memory pressure. QEMU memballoon device has a feature to release some memory at the last moment before some process will be get killed by OOM-killer. Introduce a new optional balloon device attribute 'autodeflate' to enable or disable this feature.
-
由 Laine Stump 提交于
This new function will add a single controller of the given model, except the case of ich9-usb-ehci1 (the master controller for a USB2 controller set) in which case a set of related controllers will be added (EHCI1, UHCI1, UHCI2, UHCI3). These controllers will not be given PCI addresses, but should be otherwise ready to use. "-1" is allowed for controller model, and means "default for this machinetype". This matches the existing practice in qemuDomainDefPostParse(), which always adds the default controller with model = -1, and relies on the commandline builder to set a model (that is wrong, but will be fixed later).
-
由 Laine Stump 提交于
We need a virDomainDefAddController() that doesn't check for an existing controller at the same index (since USB2 controllers must be added in sets of 4 that are all at the same index), so rather than duplicating the code in virDomainDefMaybeAddController(), split it into two functions, in the process eliminating existing duplicated code that loops through the controller list by calling virDomainControllerFind(), which does the same thing).
-
- 11 1月, 2016 1 次提交
-
-
由 Martin Kletzander 提交于
This way both Domain and Device PostParse functions can act based on the flags. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 09 1月, 2016 2 次提交
-
-
由 Cole Robinson 提交于
This should be a no-op
-
由 Cole Robinson 提交于
This should be a no-op
-
- 05 1月, 2016 2 次提交
-
-
由 Dmitry Mishin 提交于
Commit id '70ffa02f' added the data.file.append option to some VIR_DOMAIN_CHR_TYPE_FILE cases in switch statements allowing the code to "fall through" for the remainder of the cases. This causes angst in code profiling tools, like Coverity since there is no break; followed by more case conditions. Adjust the logic to be more specific within each case. Signed-off-by: NDmitry Mishin <dim@virtuozzo.com>
-
由 Dmitry Mishin 提交于
For completeness, use the VIR_TRISTATE_SWITCH_ABSENT for data.file.append comparisons. Commit ids '70ffa02f' and '53a15aed' just went with the non zero comparison.
-
- 24 12月, 2015 1 次提交
-
-
由 Dmitry Mishin 提交于
Currently, there is no possibility for user to specify desired behaviour of output to file - truncate or append. This patch adds an ability to explicitly specify that user wants to preserve file's content on reopen. Signed-off-by: NDmitry Mishin <dim@virtuozzo.com>
-