1. 05 10月, 2017 3 次提交
  2. 04 10月, 2017 1 次提交
    • L
      qemu: Support multiqueue virtio-blk · abca72fa
      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>
      abca72fa
  3. 28 9月, 2017 1 次提交
    • J
      qemu: Introduce qemuDomainPrepareDiskSource · 5c09486c
      John Ferlan 提交于
      Introduce a function to setup any TLS needs for a disk source.
      
      If there's a configuration or other error setting up the disk source
      for TLS, then cause the domain startup to fail.
      
      For VxHS, follow the chardevTLS model where if the src->haveTLS hasn't
      been configured, then take the system/global cfg->haveTLS setting for
      the storage source *and* mark that we've done so via the tlsFromConfig
      setting in storage source.
      
      Next, if we are using TLS, then generate an alias into a virStorageSource
      'tlsAlias' field that will be used to create the TLS object and added to
      the disk object in order to link the two together for QEMU.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      5c09486c
  4. 27 9月, 2017 1 次提交
    • P
      qemu: domain: Extract common clearing of VM private data · 3685e2dd
      Peter Krempa 提交于
      VM private data is cleared when the VM is turned off and also when the
      VM object is being freed. Some of the clearing code was duplicated.
      Extract it to a separate function.
      
      This also removes the now unnecessary function
      qemuDomainClearPrivatePaths.
      3685e2dd
  5. 21 9月, 2017 1 次提交
  6. 14 9月, 2017 1 次提交
    • P
      qemu: Remove support for legacy block jobs · 2350d101
      Peter Krempa 提交于
      Block job QMP commands with underscores rather than dashes were never
      released in upstream qemu, (they were added, but modified in the same
      release [1]), but a certain distro managed to backport the version in the
      middle.
      
      The change also slightly modified semantics for the abort command, which
      made us have a lot of code which was only ever present in certain
      downstream distros.
      
      Clean the upstream code from the legacy cruft and support only the
      upstream implementations.
      
      [1] See qemu commit v1.0-2176-gdb58f9c060
      Reviewed-by: NEric Blake <eblake@redhat.com>
      2350d101
  7. 13 9月, 2017 1 次提交
    • J
      qemu: Clean up qemuDomainSecretPrepare · 23706c17
      John Ferlan 提交于
      No need to pass a @driver parameter since all that's done is deref
      the @cfg especially since the only caller can just pass an already
      referenced @cfg.
      
      Also, looks like commit id '0298531b' at one time had a different
      name for the API, so I took the liberty of fixing the comments too
      since I would already be updating them for the @cfg variable.
      23706c17
  8. 07 9月, 2017 6 次提交
  9. 29 8月, 2017 1 次提交
  10. 25 7月, 2017 2 次提交
  11. 10 7月, 2017 1 次提交
    • P
      qemu: domain: Use vcpu 'node-id' property and pass it back to qemu · ccac4465
      Peter Krempa 提交于
      vcpu properties gathered from query-hotpluggable cpus need to be passed
      back to qemu. As qemu did not use the node-id property until now and
      libvirt forgot to pass it back properly (it was parsed but not passed
      around) we did not honor this.
      
      This patch adds node-id to the structures where it was missing and
      passes it around as necessary.
      
      The test data was generated with a VM with following config:
          <numa>
            <cell id='0' cpus='0,2,4,6' memory='512000' unit='KiB'/>
            <cell id='1' cpus='1,3,5,7' memory='512000' unit='KiB'/>
          </numa>
      
      Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1452053
      ccac4465
  12. 16 6月, 2017 1 次提交
  13. 14 6月, 2017 1 次提交
  14. 07 6月, 2017 6 次提交
  15. 05 6月, 2017 1 次提交
  16. 27 4月, 2017 1 次提交
  17. 18 4月, 2017 1 次提交
    • P
      qemu: refactor qemuDomainMachine* functions · ac97658d
      Pavel Hrdina 提交于
      Introduce new wrapper functions without *Machine* in the function
      name that take the whole virDomainDef structure as argument and
      call the existing functions with *Machine* in the function name.
      
      Change the arguments of existing functions to *machine* and *arch*
      because they don't need the whole virDomainDef structure and they
      could be used in places where we don't have virDomainDef.
      Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
      ac97658d
  18. 10 4月, 2017 1 次提交
  19. 28 3月, 2017 1 次提交
    • A
      qemu: Remove qemuDomainRequiresMemLock() · 1f7661af
      Andrea Bolognani 提交于
      Instead of having a separate function, we can simply return
      zero from the existing qemuDomainGetMemLockLimitBytes() to
      signal the caller that the memory locking limit doesn't need
      to be set for the guest.
      
      Having a single function instead of two makes it less likely
      that we will use the wrong value, which is exactly what
      happened when we started applying the limit that was meant
      for VFIO-using guests to <memoryBacking><locked>-using
      guests.
      1f7661af
  20. 27 3月, 2017 5 次提交
  21. 25 3月, 2017 1 次提交
    • J
      qemu: Set up the migration TLS objects for target · 1a6b6d9a
      John Ferlan 提交于
      If the migration flags indicate this migration will be using TLS,
      then set up the destination during the prepare phase once the target
      domain has been started to add the TLS objects to perform the migration.
      
      This will create at least an "-object tls-creds-x509,endpoint=server,..."
      for TLS credentials and potentially an "-object secret,..." to handle the
      passphrase response to access the TLS credentials. The alias/id used for
      the TLS objects will contain "libvirt_migrate".
      
      Once the objects are created, the code will set the "tls-creds" and
      "tls-hostname" migration parameters to signify usage of TLS.
      
      During the Finish phase we'll be sure to attempt to clear the
      migration parameters and delete those objects (whether or not they
      were created). We'll also perform the same reset during recovery
      if we've reached FINISH3.
      
      If the migration isn't using TLS, then be sure to check if the
      migration parameters exist and clear them if so.
      1a6b6d9a
  22. 16 3月, 2017 1 次提交
  23. 10 3月, 2017 1 次提交
    • M
      qemuProcessHandleMonitorEOF: Disable namespace for domain · e915942b
      Michal Privoznik 提交于
      https://bugzilla.redhat.com/show_bug.cgi?id=1430634
      
      If a qemu process has died, we get EOF on its monitor. At this
      point, since qemu process was the only one running in the
      namespace kernel has already cleaned the namespace up. Any
      attempt of ours to enter it has to fail.
      
      This really happened in the bug linked above. We've tried to
      attach a disk to qemu and while we were in the monitor talking to
      qemu it just died. Therefore our code tried to do some roll back
      (e.g. deny the device in cgroups again, restore labels, etc.).
      However, during the roll back (esp. when restoring labels) we
      still thought that domain has a namespace. So we used secdriver's
      transactions. This failed as there is no namespace to enter.
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      e915942b