- 21 4月, 2017 1 次提交
-
-
由 Martin Kletzander 提交于
We are currently parsing only rx/frames/max because that's the only value that makes sense for us. The tun device just added support for this one and the others are only supported by hardware devices which we don't need to worry about as the only way we'd pass those to the domain is using <hostdev/> or <interface type='hostdev'/>. And in those cases the guest can modify the settings itself. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 20 4月, 2017 1 次提交
-
-
由 Pavel Hrdina 提交于
So far there is probably no change that is allowed to be done by the VIR_DOMAIN_DEF_PARSE_ABI_UPDATE flag that would break guest ABI but this may change in the future. This introduces new VIR_DOMAIN_DEF_PARSE_ABI_UPDATE_MIGRATION which should be used only for ABI updates that are "safe" for persistent migration. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 13 4月, 2017 3 次提交
-
-
由 Ján Tomko 提交于
Make adding subelements easier.
-
由 Wang King 提交于
Assigning value 0 to @nboards in success path, that stored value is not used.
-
由 Peter Krempa 提交于
The property is necessary also for the disk using the source (e.g. cdrom) which needs to be kept readonly. Commit '462c4b66' was a bit too aggressive in this aspect, since the readonly flag is set only while parsing.
-
- 03 4月, 2017 2 次提交
-
-
由 Michal Privoznik 提交于
Currently, if we want to zero out disk source (e,g, due to startupPolicy when starting up a domain) we use virDomainDiskSetSource(disk, NULL). This works well for file based storage (storage type file, dir, or block). But it doesn't work at all for other types like volume and network. So imagine that you have a domain that has a CDROM configured which source is a volume from an inactive pool. Because it is startupPolicy='optional', the CDROM is empty when the domain starts. However, the source element is not cleared out in the status XML and thus when the daemon restarts and tries to reconnect to the domain it refreshes the disks (which fails - the storage pool is still not running) and thus the domain is killed. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Michal Privoznik 提交于
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 28 3月, 2017 1 次提交
-
-
由 Jiri Denemark 提交于
The frequency is documented and formatted as an attribute of the <timer> element rather than a nested <frequency> element expected by the parser. Luckily enough, timer frequency has not been used by any driver so far. And users were not able to set it in the XML either. Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
-
- 27 3月, 2017 6 次提交
-
-
由 Laine Stump 提交于
This is the maximum for many reasons, for starters because index == bus number, and a controller's bus number is 8 bits. This incidentally resolves: https://bugzilla.redhat.com/1329090
-
由 Erik Skultety 提交于
This merely introduces virDomainHostdevMatchSubsysMediatedDev method that is supposed to check whether device being cold-plugged does not already exist in the domain configuration. Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
由 Erik Skultety 提交于
A mediated device will be identified by a UUID (with 'model' now being a mandatory <hostdev> attribute to represent the mediated device API) of the user pre-created mediated device. We also need to make sure that if user explicitly provides a guest address for a mdev device, the address type will be matching the device API supported on that specific mediated device and error out with an incorrect XML message. The resulting device XML: <devices> <hostdev mode='subsystem' type='mdev' model='vfio-pci'> <source> <address uuid='c2177883-f1bb-47f0-914d-32a22e3a8804'> </source> </hostdev> </devices> Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
由 Erik Skultety 提交于
Just to make the code a bit cleaner, move hostdev specific post parse code to its own function just in case it grows in the future. Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
由 Erik Skultety 提交于
Just a tiny wrapper over the SCSI def clearing logic to drop some if-else branches from a switch, mainly because extending the switch in the future would render the current code with branching less readable. Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
由 Erik Skultety 提交于
Enforce virDomainHostdevSubsysType checking during compilation. Again, one of a few spots in our code where we should enforce the typecast to the enum type, thus not forgetting to update *all* switch occurrences dealing with the give enum. Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
- 17 3月, 2017 2 次提交
-
-
由 Jiri Denemark 提交于
The attribute can be used to request a specific way of checking whether the virtual CPU matches created by the hypervisor matches the specification in domain XML. Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
-
由 Andrea Bolognani 提交于
QEMU 2.9 introduces the pcie-root-port device, which is a generic version of the existing ioh3420 device. Make the new device available to libvirt users.
-
- 15 3月, 2017 3 次提交
-
-
由 Michal Privoznik 提交于
For NVDIMM devices it is optionally possible to specify the size of internal storage for namespaces. Namespaces are a feature that allows users to partition the NVDIMM for different uses. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Michal Privoznik 提交于
Now that NVDIMM has found its way into libvirt, users might want to fine tune some settings for each module separately. One such setting is 'share=on|off' for the memory-backend-file object. This setting - just like its name suggest already - enables sharing the nvdimm module with other applications. Under the hood it controls whether qemu mmaps() the file as MAP_PRIVATE or MAP_SHARED. Yet again, we have such config knob in domain XML, but it's just an attribute to numa <cell/>. This does not give fine enough tuning on per-memdevice basis so we need to have the attribute for each device too. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Michal Privoznik 提交于
NVDIMM is new type of memory introduced into QEMU 2.6. The idea is that we have a Non-Volatile memory module that keeps the data persistent across domain reboots. At the domain XML level, we already have some representation of 'dimm' modules. Long story short, NVDIMM will utilize the existing <memory/> element that lives under <devices/> by adding a new attribute 'nvdimm' to the existing @model and introduce a new <path/> element for <source/> while reusing other fields. The resulting XML would appear as: <memory model='nvdimm'> <source> <path>/tmp/nvdimm</path> </source> <target> <size unit='KiB'>523264</size> <node>0</node> </target> <address type='dimm' slot='0'/> </memory> So far, this is just a XML parser/formatter extension. QEMU driver implementation is in the next commit. For more info on NVDIMM visit the following web page: http://pmem.io/Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 12 3月, 2017 1 次提交
-
-
由 Fabian Freyer 提交于
bhyve supports 'gop' video device that allows clients to connect to VMs using VNC clients. This commit adds support for that to the bhyve driver: - Introducr 'gop' video device type - Add capabilities probing for the 'fbuf' device that's responsible for graphics - Update command builder routines to let users configure domain's VNC via gop graphics. Signed-off-by: NRoman Bogorodskiy <bogorodskiy@gmail.com>
-
- 10 3月, 2017 1 次提交
-
-
由 Pavel Hrdina 提交于
This reverts commit c96bd78e. So our code is one big mess and we modify domain definition while building qemu_command line and our hotplug code share only part of the parsing and command line building code. Let's revert that change because to fix it properly would require refactor and move a lot of things. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1430275
-
- 09 3月, 2017 2 次提交
-
-
由 Pavel Hrdina 提交于
We should skip <listen type='socket'/> only if the 'socket' path is specified because if there is no 'socket' path we need to keep that element in migratable XML. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1366088Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
When libvirtd is started we call qemuDomainRecheckInternalPaths to detect whether a domain has VNC socket path generated by libvirt based on option from qemu.conf. However if we are parsing status XML for running domain the existing socket path can be generated also if the config XML uses the new <listen type='socket'/> element without specifying any socket. The current code doesn't make difference how the socket was generated and always marks it as "fromConfig". We need to store the "autoGenerated" value in the status XML in order to preserve that information. The difference between "fromConfig" and "autoGenerated" is important for migration, because if the socket is based on "fromConfig" we don't print it into the migratable XML and we assume that user has properly configured qemu.conf on both hosts. However if the socket is based on "autoGenerated" it means that a new feature was used and therefore we need to leave the socket in migratable XML to make sure that if this feature is not supported on destination the migration will fail. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 23 2月, 2017 2 次提交
-
-
由 Daniel P. Berrange 提交于
In GCC 7 there is a new warning triggered when a switch case has a conditional statement (eg if ... else...) and some of the code paths fallthrough to the next switch statement. e.g. conf/domain_conf.c: In function 'virDomainChrEquals': conf/domain_conf.c:14926:12: error: this statement may fall through [-Werror=implicit-fallthrough=] if (src->targetTypeAttr != tgt->targetTypeAttr) ^ conf/domain_conf.c:14928:5: note: here case VIR_DOMAIN_CHR_DEVICE_TYPE_CONSOLE: ^~~~ conf/domain_conf.c: In function 'virDomainChrDefFormat': conf/domain_conf.c:22143:12: error: this statement may fall through [-Werror=implicit-fallthrough=] if (def->targetTypeAttr) { ^ conf/domain_conf.c:22151:5: note: here default: ^~~~~~~ GCC introduced a __attribute__((fallthrough)) to let you indicate that this is intentionale behaviour rather than a bug. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Andrea Bolognani 提交于
When switching over the values in the virDomainControllerModelPCI enumeration, make sure the proper cast is in place so that the compiler can warn us when the coverage is not exaustive. For the same reason, remove the 'default' case from one of the existing switch statements.
-
- 22 2月, 2017 1 次提交
-
-
由 Michal Privoznik 提交于
Our virSomeEnumTypeFromString() functions return either the value of item from the enum or -1 on error. Usually however the value 0 means 'this value is not set in the domain XML, use some sensible default'. Therefore, we don't accept corresponding string in domain XML, for instance: <memoryBacking> <source mode="none"/> <access mode="default"/> <allocation mode="none"/> </memoryBacking> should be rejected as invalid XML. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 21 2月, 2017 7 次提交
-
-
由 Daniel P. Berrange 提交于
The niothreadids struct field is size_t, so must use %zu not %lu with printf. While they're identical on some platforms, on others they are different, causing warnings conf/domain_conf.c: In function 'virDomainDefCheckABIStabilityFlags': conf/domain_conf.c:19575:26: error: format '%lu' expects argument of type 'long unsigned int', but argument 7 has type 'size_t {aka unsigned int}' [-Werror=format=] _("Target domain iothreads count %lu does not " ^ conf/domain_conf.c: In function 'virDomainDefFormatInternal': conf/domain_conf.c:23915:46: error: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t {aka unsigned int}' [-Werror=format=] virBufferAsprintf(buf, "<iothreads>%lu</iothreads>\n", ^ Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
This will ensure that IOThreads are properly validated while a domain is defined. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 17 2月, 2017 1 次提交
-
-
由 Marc-André Lureau 提交于
Add a new attribute 'rendernode' to <gl> spice element. Give it to QEMU if qemu supports it (queued for 2.9). Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 10 2月, 2017 1 次提交
-
-
由 Marc Hartmayer 提交于
If virDomainChrSourceDefNew(xmlopt) fails, it will lead to free()ing the uninitialized pointer bus. The fix for this is to initialize bus with NULL. Signed-off-by: NMarc Hartmayer <mhartmay@linux.vnet.ibm.com> Reviewed-by: NBoris Fiuczynski <fiuczy@linux.vnet.ibm.com> Reviewed-by: NBjoern Walk <bwalk@linux.vnet.ibm.com>
-
- 09 2月, 2017 1 次提交
-
-
由 Jaroslav Safka 提交于
This part introduces new xml elements for file based memorybacking support and their parsing. (It allows vhost-user to be used without hugepages.) New xml elements: <memoryBacking> <source type="file|anonymous"/> <access mode="shared|private"/> <allocation mode="immediate|ondemand"/> </memoryBacking>
-
- 01 2月, 2017 1 次提交
-
-
由 Martin Kletzander 提交于
That function sets disk->blkdeviotune sensibly. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 27 1月, 2017 1 次提交
-
-
由 Pavel Hrdina 提交于
The issue is that if this graphics definition is provided: <graphics type='vnc' port='0'/> it's parsed as: <graphics type='vnc' autoport='no'> <listen type='address'/> </graphics> but if the resulting XML is parsed again the output is: <graphics type='vnc' port='-1' autoport='yes'> <listen type='address'/> </graphics> and this should not happen. The XML have to always remain the same after it was already parsed by libvirt. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1383039Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 26 1月, 2017 1 次提交
-
-
由 Michal Privoznik 提交于
So far we allow to set MTU for libvirt networks. However, not all domain interfaces have to be plugged into a libvirt network and even if they are, they might want to have a different MTU (e.g. for testing purposes). Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 25 1月, 2017 1 次提交
-
-
由 Michal Privoznik 提交于
We use @ret to hold the actual return value of the function we are currently in. To hold a return value of a function called we use different variables: @rv, @rc, etc. Honour this naming scheme in virDomainNetDefParseXML too. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-