- 08 2月, 2019 40 次提交
-
-
由 Nikolay Shirokovskiy 提交于
Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Nikolay Shirokovskiy 提交于
Stream server error is not propagated if thread does not have the buck. In case we have the buck we are ok due to the code added in [1]. Let's check for stream error on all paths. Now we don't need to raise error in virNetClientCallDispatchStream. Old code reported error only if the first message in wait queue awaits reply. It is odd as depends on wait queue situation. For example if we have only TX message in queue and in one iteration loop both send the message and receive error then thread sending TX message did not receive the error. Next if we have RX message (first) and TX message (second) in queue and in one iteration loop both send the TX message and receive error then thread sending TX message received error. In short it was inconsistent. Let's report error whenever we received it and for every type of message as it makes sense to report errors as early as possible. [1] 16c6e2b4: Fix propagation of RPC errors from streams Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Nikolay Shirokovskiy 提交于
Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com> Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Nikolay Shirokovskiy 提交于
In next patches we'll add stream state checks to this function that applicable to all call paths. This is handy place because we hold client lock here. Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Nikolay Shirokovskiy 提交于
Stream abort/finish can hang because we can receive abort message from server and yet sent abort/finish message to server. The latter will not be answered ever because after server sends abort message it forgets the stream and messages for unknown stream are simply ignored. We check for stream error at the very beginning of remoteStreamFinish/remoteStreamAbort but stream error can be set after the check in another thread operating on stream. Let's check for stream error under client lock similar to what's done in [1]. [1] 833b901c: stream: Check for stream EOF Signed-off-by: NNikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
-
由 Andrea Bolognani 提交于
These functions do mostly the same things, and it would be preferrable if they did them in mostly the same ways. This also fixes a few violations to our code style guidelines. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
The function operates on a virDomainDef and is not tied to device address assignment in any way, so it makes more sense for it to live along with qemuDomainIs*() and the like. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
Ideally we'd make all of them static, but there are a few cases where we don't have a virDomainDef instance handy and so they are the only option. For the few ones we're forced to keep exporting, document through comments that the alternative is preferred. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
Now that we have added architecture checks to all qemuDomainIs*() functions, we no longer need to perform the same checks separately. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
There is very little overlap in the machine types available on different architectures, so broadly speaking checking the machine type is usually enough; regardless, it's better to check the architecture as well. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
We want the signatures to be consistent, and also we're going to start using the additional parameter next. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
Make sure related functions, eg. all qemuDomainIs*(), are close together instead of being sprinkled throughout both the header and implementation file, and also that all qemuDomainMachine*() functions are declared first since we're going to make a bunch of them static later on. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
While the chances of the current checks resulting in false positives are basically zero, it's still nicer to check for the full prefix instead of the prefix's prefix. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Andrea Bolognani 提交于
No need to check whether we're dealing with a pSeries guest twice within just a few lines. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
由 John Ferlan 提交于
For consistency, let's use the semicolon for all definitions. Signed-off-by: NJohn Ferlan <jferlan@redhat.com> Reviewed-by: NErik Skultety <eskultet@redhat.com>
-
由 Erik Skultety 提交于
Luckily, the new URL still points to the same location, the only change is in the document name where an escaped space (%20) was replaced by an underscore. Signed-off-by: NErik Skultety <eskultet@redhat.com> Reviewed-by: NAndrea Bolognani <abologna@redhat.com>
-
由 Peter Krempa 提交于
Avoid calling the command and fix test fallout. https://bugzilla.redhat.com/show_bug.cgi?id=1673320Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
QEMU plans to deprecate 'query-events' as it's non-extensible. Events are also described by 'query-qmp-schema' so we can use that one instead. This patch adds detection of events to virQEMUCapsProbeQMPSchemaCapabilities using the same structure declaring them for the old approach (virQEMUCapsEvents). This is possible as the name is the same in the QMP schema and our detector supports that trivially. For any complex queries virQEMUCapsQMPSchemaQueries can be used in the future. For now we still call 'query-events' and discard the result so that it's obvious that the tests pass. This will be cleaned up later. https://bugzilla.redhat.com/show_bug.cgi?id=1673320Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
The event was added by qemu commit 6f382ed226f3 released in v1.1. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
DEVICE_DELETED was added in qemu commit 0402a5d65ec00 which was released in v1.5.0. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
DO_TEST_ATTACH and DO_TEST_ATTACH_EVENT now do the same thing so we can remove the latter including the infrastructure. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Currently all supported qemu versions now have support for the DEVICE_DELETED event. This means that testing the old approach is a waste of time. Always add the QEMU_CAPS_DEVICE_DEL_EVENT capability in the hotplug test and fix existing test cases. The 'disk-virtio', 'disk-usb', 'disk-scsi', and 'disk-scsi-2' already had variants that used the event, so the non-event variants will be removed. For all other cases the QMP_DEVICE_DELETED macro is used to add the correct reply. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
This variant is unused as we create the object including capabilities with DO_TEST_ATTACH_EVENT, which is then reused. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
The event was added by qemu commit 2fdd16e239c2a2 released in v1.3.0. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Remove the uneeded attribute and return value. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
The event was added to qemu by commit 973603a813c5d60 which is contained in the 1.2.0 release. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Avoid regressions by disallowing the BLOCKDEV capability. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
QEMU accidentally exposed the id of -drive (or same value as disk serial, if provided) in one of the identifiers visible from the guest. To avoid regression in case when -blockdev will be used we need to always specify it ourselves. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
The property allows to control the guest-visible content of the vendor specific designator of the 'Device Identification' page of a SCSI device's VPD (vital product data). QEMU was leaking the id string of -drive as the value if the 'serial' of the disk was not specified. Switching to -blockdev would impose an ABI change. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Based on qemu commit 'v3.1.0-1445-ga61faa3d02'. Will allow checking for the scsi 'device_id' property. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Upcoming addition of a new field will need to make sure that SCSI disk serial is tested as well. Add a case to one of the existing tests. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
For SCSI, IDE, and AHCI cdroms the appropriate device types which select the correct media are used. In qemu there's one other code path that looks at -drive media=cdrom in the XEN pv code. Thankfully we don't support it with qemu (see qemuBuildDiskDeviceStr). All other devices ignore it as the comment states, thus we can drop that code. The test fallout is expectedly only in the test added for uncommon cdrom types. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Add full and empty cdroms on 'usb' and 'sd' bus to have test coverage. Note that this does not guarantee that qemu will accept them. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Attempting to create an empty virtio-blk drive results into: -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0xc,drive=drive-virtio-disk1,id=virtio-disk1: Device needs media, but drive is empty Attempting to eject media from virtio-blk based drive results into: error: internal error: unable to execute QEMU command 'eject': Device 'drive-virtio-disk0' is not removable Forbid configurations where users would attempt to use cdroms in virtio bus. Fix few wrong examples which are not really relevant to the tested code. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Cast disk->bus to proper type and add missing values to the enum so it's more obvious what types are supported. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
The split of ide-disk into the two separate devices was introduced by qemu commit 1f56e32a7f4b3 released in qemu v0.15. Note that when compared to the previous commit which made sure that no disk related tests were touched, in this case it's not as careful. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
The split of scsi-disk into the two separate devices was introduced by qemu commit b443ae67 released in qemu v0.15. All changes to test files are not really related to disk testing thanks to previous refactors. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
It's a subset of 'iothreads-virtio-scsi-ccw'. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Use DO_TEST_CAPS_LATEST to obtain modern results. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Peter Krempa 提交于
Rather than testing random set of flags add a case also for the oldest supported qemu. Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
-