1. 15 11月, 2016 2 次提交
    • L
      qemu: assign e1000e network devices to PCIe slots when appropriate · 9dfe733e
      Laine Stump 提交于
      The e1000e is an emulated network device based on the Intel 82574,
      present in qemu 2.7.0 and later. Among other differences from the
      e1000, it presents itself as a PCIe device rather than legacy PCI. In
      order to get it assigned to a PCIe controller, this patch updates the
      flags setting for network devices when the model name is "e1000e".
      
      (Note that for some reason libvirt has never validated the network
      device model names other than to check that there are no dangerous
      characters in them. That should probably change, but is the subject of
      another patch.)
      
      Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1343094
      9dfe733e
    • L
      qemu: assign virtio devices to PCIe slot when appropriate · c7fc151e
      Laine Stump 提交于
      libvirt previously assigned nearly all devices to a "hotpluggable"
      legacy PCI slot even on machines with a PCIe root bus (and even though
      most such machines don't even support hotplug on legacy PCI slots!)
      Forcing all devices onto legacy PCI slots means that the domain will
      need a dmi-to-pci-bridge (to convert from PCIe to legacy PCI) and a
      pci-bridge (to provide hotpluggable legacy PCI slots which, again,
      usually aren't hotpluggable anyway).
      
      To help reduce the need for these legacy controllers, this patch tries
      to assign virtio-1.0-capable devices to PCIe slots whenever possible,
      by setting appropriate connectFlags in
      virDomainCalculateDevicePCIConnectFlags(). Happily, when that function
      was written (just a few commits ago) it was created with a
      "virtioFlags" argument, set by both of its callers, which is the
      proper connectFlags to set for any virtio-*-pci device - depending on
      the arch/machinetype of the domain, and whether or not the qemu binary
      supports virtio-1.0, that flag will have either been set to PCI or
      PCIe. This patch merely enables the functionality by setting the flags
      for the device to whatever is in virtioFlags if the device is a
      virtio-*-pci device.
      
      NB: the first virtio video device will be placed directly on bus 0
      slot 1 rather than on a pcie-root-port due to the override for primary
      video devices in qemuDomainValidateDevicePCISlotsQ35(). Whether or not
      to change that is a topic of discussion, but this patch doesn't change
      that particular behavior.
      
      NB2: since the slot must be hotpluggable, and pcie-root (the PCIe root
      complex) does *not* support hotplug, this means that suitable
      controllers must also be in the config (i.e. either pcie-root-port, or
      pcie-downstream-port). For now, libvirt doesn't add those
      automatically, so if you put virtio devices in a config for a qemu
      that has PCIe-capable virtio devices, you'll need to add extra
      pcie-root-ports yourself. That requirement will be eliminated in a
      future patch, but for now, it's simple to do this:
      
         <controller type='pci' model='pcie-root-port'/>
         <controller type='pci' model='pcie-root-port'/>
         <controller type='pci' model='pcie-root-port'/>
         ...
      
      Partially Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1330024
      c7fc151e
  2. 11 11月, 2016 3 次提交
  3. 10 11月, 2016 1 次提交
  4. 09 11月, 2016 12 次提交
  5. 04 11月, 2016 1 次提交
  6. 03 11月, 2016 2 次提交
  7. 02 11月, 2016 4 次提交
  8. 26 10月, 2016 7 次提交
    • G
      qemu: Add support for using AES secret for SCSI hotplug · 0701abcb
      Gema Gomez 提交于
      Support for virtio disks was added in commit id 'fceeeda2', but not for
      SCSI drives. Add the secret for the server when hotplugging a SCSI drive.
      No need to make any adjustments for unplug since that's handled during
      the qemuDomainDetachDiskDevice call to qemuDomainRemoveDiskDevice in
      the qemuDomainDetachDeviceDiskLive switch.
      
      Added a test to/for the command line processing to show the command line
      options when adding a SCSI drive for the guest.
      0701abcb
    • J
      qemu: Add secret object hotplug for TCP chardev TLS · 8550e858
      John Ferlan 提交于
      https://bugzilla.redhat.com/show_bug.cgi?id=1300776
      
      Complete the implementation of support for TLS encryption on
      chardev TCP transports by adding the hotplug ability of a secret
      to generate the passwordid for the TLS object for chrdev, RNG,
      and redirdev.
      
      Fix up the order of object removal on failure to be the inverse
      of the attempted attach (for redirdev, chr, rng) - for each the
      tls object was being removed before the chardev backend.
      
      Likewise, add the ability to hot unplug that secret object as well
      and be sure the order of unplug matches that inverse order of plug.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      8550e858
    • J
      qemu: Add a secret object to/for a char source dev · daf5c651
      John Ferlan 提交于
      Add the secret object so the 'passwordid=' can be added if the command line
      if there's a secret defined in/on the host for TCP chardev TLS objects.
      
      Preparation for the secret involves adding the secinfo to the char source
      device prior to command line processing. There are multiple possibilities
      for TCP chardev source backend usage.
      
      Add test for at least a serial chardev as an example.
      daf5c651
    • J
      qemu: Add the length options to the iotune command line · 2db108c7
      John Ferlan 提交于
      Add in the block I/O throttling length/duration parameter to the command
      line if supported. If not supported, fail command creation.
      
      Add the xml2argvtest for testing.
      2db108c7
    • J
      conf: Add support for blkiotune "_length" options · 8dcf3559
      John Ferlan 提交于
      Modify _virDomainBlockIoTuneInfo and rng schema to support the _length
      options for bps/iops throttling values. Document the new values.
      8dcf3559
    • J
      qemu: Add length for bps/iops throttling parameters to driver · 223438a2
      John Ferlan 提交于
      Add support for a duration/length for the bps/iops and friends.
      
      Modify the API in order to add the "blkdeviotune." specific definitions
      for the iotune throttling duration/length options
      
          total_bytes_sec_max_length
          write_bytes_sec_max_length
          read_bytes_sec_max_length
          total_iops_sec_max_length
          write_iops_sec_max_length
          read_iops_sec_max_length
      223438a2
    • J
      caps: Add new capability for the bps/iops throttling length · d379552b
      John Ferlan 提交于
      Add the capability to detect if the qemu binary can support the feature
      to use bps-max-length and friends.
      d379552b
  9. 25 10月, 2016 1 次提交
  10. 24 10月, 2016 1 次提交
    • P
      domain: Add optional 'tls' attribute for TCP chardev · 0298531b
      Pavel Hrdina 提交于
      Add an optional "tls='yes|no'" attribute for a TCP chardev.
      
      For QEMU, this will allow for disabling the host config setting of the
      'chardev_tls' for a domain chardev channel by setting the value to "no" or
      to attempt to use a host TLS environment when setting the value to "yes"
      when the host config 'chardev_tls' setting is disabled, but a TLS environment
      is configured via either the host config 'chardev_tls_x509_cert_dir' or
      'default_tls_x509_cert_dir'
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
      0298531b
  11. 22 10月, 2016 1 次提交
  12. 18 10月, 2016 2 次提交
    • P
      qemu: always generate the same alias for tls-creds-x509 object · df93b5f5
      Pavel Hrdina 提交于
      There was inconsistency between alias used to create tls-creds-x509
      object and alias used to link that object to chardev while hotpluging.
      Hotplug ends with this error:
      
        error: Failed to detach device from channel-tcp.xml
        error: internal error: unable to execute QEMU command 'chardev-add':
        No TLS credentials with id 'objcharchannel3_tls0'
      
      In XML we have for example alias "serial0", but on qemu command line we
      generate "charserial0".
      
      The issue was that code, that creates QMP command to hotplug chardev
      devices uses only the second alias "charserial0" and that alias is also
      used to link the tls-creds-x509 object.
      
      This patch unifies the aliases for tls-creds-x509 to be always generated
      from "charserial0".
      Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
      df93b5f5
    • J
      qemu: Add 'verify-peer=yes' test for chardev TCP TLS · 40b6f919
      John Ferlan 提交于
      Missing the option to set verify-peer to yes
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      40b6f919
  13. 17 10月, 2016 1 次提交
    • A
      conf: Explain some code in more detail · 61e10143
      Andrea Bolognani 提交于
      The code is entirely correct, but it still managed to trip me
      up when I first ran into it because I did not realize right away
      that VIR_PCI_CONNECT_TYPES_ENDPOINT was not a single flag, but
      rather a mask including both VIR_PCI_CONNECT_TYPE_PCI_DEVICE and
      VIR_PCI_CONNECT_TYPE_PCIE_DEVICE.
      
      In order to save the next distracted traveler in PCI Address Land
      some time, document this fact with a comment. Add a test case for
      the behavior as well.
      61e10143
  14. 14 10月, 2016 2 次提交