1. 21 5月, 2015 1 次提交
  2. 20 5月, 2015 5 次提交
  3. 19 5月, 2015 5 次提交
    • M
      qemu: Fix numatune nodeset reporting · 9deb96f9
      Martin Kletzander 提交于
      Since af2a1f05,
      qemuDomainGetNumaParameters() returns invalid value for a running
      guest.  The problem is that it is getting the information from cgroups,
      but the parent cgroup is being left alone since the mentioned commit.
      Since the running guest's XML is in sync with cgroups, there is no need
      to look into cgroups (unless someone changes the configuration behind
      libvirt's back).  Returning the info from the definition fixes a bug and
      is also a cleanup.
      
      Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1221047Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
      9deb96f9
    • J
      xenconfig: fix spice mousemode and copypaste · a5b55bd9
      Jim Fehlig 提交于
      From xl.cfg950 man page:
      
      spiceagent_mouse=BOOLEAN
      Whether SPICE agent is used for client mouse mode. The default is
      true (1) (turn on)
      
      spicevdagent=BOOLEAN
      Enables spice vdagent. The Spice vdagent is an optional component for
      enhancing user experience and performing guest-oriented management
      tasks. Its features includes: client mouse mode (no need to grab
      mouse by client, no mouse lag), automatic adjustment of screen
      resolution, copy and paste (text and image) between client and domU.
      It also requires vdagent service installed on domU o.s. to work.
      The default is 0.
      
      spice_clipboard_sharing=BOOLEAN
      Enables Spice clipboard sharing (copy/paste). It requires spicevdagent
      enabled. The default is false (0).
      
      So if spiceagent_mouse is enabled (client mouse mode) or
      spice_clipboard_sharing is enabled, spicevdagent must be enabled.
      Along with this change, s/spicedvagent/spicevdagent, set
      spiceagent_mouse correctly, and add a test for these spice
      features.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      a5b55bd9
    • J
      xenconfig: fix spicepasswd handling · a460295f
      Jim Fehlig 提交于
      The logic related to spicedisable_ticketing and spicepasswd was
      inverted.  As per man xl.cfg(5), 'spicedisable_ticketing = 1'
      means no passwd is required.  On the other hand, a passwd is
      required if 'spicedisable_ticketing = 0'.  Fix the logic and
      produce and error if 'spicedisable_ticketing = 0' but spicepasswd
      is not provided.  Also fix the spice cfg test file.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      a460295f
    • J
      xenconfig: format spice listenAddr when formating ports · e21b1180
      Jim Fehlig 提交于
      Move formating of spice listenAddr to the section of code
      where spice ports are formatted.  It is more logical to
      format address and ports together.  Account for the change
      in spice cfg test file by moving 'spicehost'.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      e21b1180
    • J
      xenconfig: use local variable for graphics def · 096b39c9
      Jim Fehlig 提交于
      'graphics->' is a bit easier to read and type, and makes for
      shorter lines than 'def->graphics[0]->'.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      096b39c9
  4. 18 5月, 2015 12 次提交
  5. 16 5月, 2015 7 次提交
    • J
      libxl: provide impl for nodeGetSecurityModel · 99a42f3c
      Jim Fehlig 提交于
      Currently, the libxl driver does not support any security drivers.
      When the qemu driver has no security driver configued,
      nodeGetSecurityModel succeeds but returns an empty virSecurityModel
      object.  Do the same in the libxl driver instead of reporting
      
      this function is not supported by the connection driver:
      virNodeGetSecurityModel
      99a42f3c
    • L
      qemu: log error when domain has an unsupported IDE controller · eadd757c
      Laine Stump 提交于
      We have previously effectively ignored all <controller type='ide'>
      elements in a domain definition.
      
      On the i440fx-based machinetypes there is an IDE controller that is
      included in the chipset and can't be removed (which is the ide
      controller with index='0'>), so it makes sense to ignore that one
      controller. However, if an i440fx domain definition has a 2nd
      controller, nothing catches this error (unless you also have a disk
      attached to it, in which case qemu will complain that you're trying to
      use the ide controller named "ide1", which doesn't exist), and if any
      other type of domain has even a single controller defined, it will be
      incorrectly ignored.
      
      Ignoring a bogus controller definition isn't such a big problem, as
      long as an error is logged when any disk is attached to that
      non-existent controller. But in the case of q35-based machinetypes,
      the hardcoded id ("alias" in libvirt terms) of its builtin SATA
      controller is "ide", which happens to be the same id as the builtin
      IDE controller on i440fx machinetypes. So libvirt creates a
      commandline believing that it is connecting the disk to the builtin
      (but actually nonexistent) IDE controller, qemu thinks that libvirt
      wanted that disk connected to the builtin SATA controller, and
      everybody is happy.
      
      Until you try to connect a 2nd disk to the IDE controller. Then qemu
      will complain that you're trying to set unit=1 on a controller that
      requires unit=0 (SATA controllers are organized differently than IDE
      controllers).
      
      After this patch, if a domain has an IDE controller defined for a
      machinetype that has no IDE controllers, libvirt will log an error
      about the controller itself as it is building the qemu commandline
      (rather than a (possible) error from qemu about disks attached to that
      controller). This is done by adding IDE to the list of controller
      types that are handled in the loop that creates controller command
      strings in qemuBuildCommandline() (previously it would *always* skip
      IDE controllers). Then qemuBuildControllerDevStr() is modified to log
      an appropriate error in the case of IDE controllers.
      
      In the future, if we add support for extra IDE controllers (piix3-ide
      and/or piix4-ide) we can just add it into the IDE case in
      qemuBuildControllerDevStr(). For now, nobody seems anxious to add
      extra support for an aging and very slow controller, when there are so
      many better options available.
      
      Resolves:
      
      https://bugzilla.redhat.com/show_bug.cgi?id=1176071 (Fedora)
      eadd757c
    • L
      qemu: clean up qemuBuildCommandline loop that builds controller args · b8f345b4
      Laine Stump 提交于
      Reorganize the loop that builds controller args to remove unnecessary
      duplicated code and superfluous else clauses. No functional change.
      b8f345b4
    • L
      qemu: remove test for allowing ide controller in s390, rename usb tests · 548ba430
      Laine Stump 提交于
      Back in 2013, commit 877bc089 added in some tests that made sure no
      error was generated on a domain definition that had an automatically
      added usb controller if that domain didn't have a PCI bus to attach
      the usb controller to. This was done because, at that time, libvirt
      was automatically adding a usb controller to *any* domain definition
      that didn't have one.  Along with permitting the controller, two
      s390-specific tests were added to ensure this behavior was maintained
      - one with <controller type='usb' model='none'/> and another (called
      "s390-piix-controllers") that had both usb and ide controllers, but
      nothing attached to them.
      
      Then in February of this year, commit 09ab9dcc eliminated the annoying
      auto-adding of a usb device for s390 and s390x machines, stating:
      
       "Since s390 does not support usb the default creation of a usb
        controller for a domain should not occur."
      
      Although, as verified here, the s390 doesn't support usb, and usb
      controllers aren't currently added to s390 domain definitions
      automatically, there are likely still some domain definitions in the
      wild that have a usb controller (which was added *by libvirt*, not by
      the user), so we will keep the tests verifying that behavior for
      now. But this patch changes the names of the tests to reflect that
      they don't actually contain a valid s390 config; this way future
      developers won't propagate the incorrect idea that an s390 virtual
      machine can have a USB (or IDE) bus.
      
      In the case of the IDE controller, though, libvirt has never
      automatically added an IDE controller unless a user added an IDE disk
      (which itself would have caused an error), and we specifically *do*
      want to begin generating an error when someone tries to add an IDE
      controller to a domain that can't support one. For that reason, while
      renaming the sz390-piix-controllers patch, this patch removes the
      <controller type='ide'...> from it (otherwise the upcoming patch would
      break make check)
      548ba430
    • L
      qemu: use controller alias when constructing device/controller args · 0260506c
      Laine Stump 提交于
      This makes sure that that the commandlines generated for devices and
      controller devices are all using the alias that has been set in the
      controller's object as the id of the controller, rather than
      hardcoding a printf (or worse, encoding exceptions to the standard
      ${controller}${index} into the logic)
      
      Since this "fixes" the controller name used for the sata controller,
      the commandline arg for the sata controller in the sata test case had
      to be adjusted to be "sata0" instead of "ahci0". All other tests
      remain unchanged, verifying that the patch causes no other functional
      change.
      
      Because the function that finds a controller alias based on a device
      def requires a pointer to the full domainDef in order to get the list
      of controllers, the arglist of a few functions had to have this added.
      0260506c
    • L
      qemu: fix exceptions in qemuAssignDeviceControllerAlias · 75cd7d9b
      Laine Stump 提交于
      There are a few extra exceptions that weren't being accounted for when
      creating the alias for a controller. This resulted in 1) incorrect
      status XML, and 2) exceptions/printfs of what *should* have been
      directly available in the controller alias when constructing device
      commandline arguments:
      
      1) The primary (and only) IDE controller on a 440FX machinetype is
      hardcoded to be "ide" in qemu.
      
      2) The primary SATA controller on a 440FX machinetype is also
      hardcoded to be "ide" in qemu.
      
      3) On machinetypes that don't support multiple PCI buses, the PCI bus
      is hardcoded in qemu to have the name "pci".
      
      4) The first usb master controller is "usb", all others are the normal
      "usb%d". (note that usb controllers that are not a "master" will have
      the same index, and thus alias, as the master).
      
      We needed to pass in the full domainDef and qemuCaps in order to
      properly make the decisions about these exceptions.
      75cd7d9b
    • L
      conf: utility to return alias of a controller based on type/index · a3dfaf12
      Laine Stump 提交于
      Because there are multiple potential reasons for an error, this
      function logs any errors before returning NULL (since the caller won't
      have the information needed to determine which was the reason for
      failure).
      a3dfaf12
  6. 15 5月, 2015 5 次提交
  7. 14 5月, 2015 5 次提交