1. 21 12月, 2010 3 次提交
    • E
      tests: avoid spurious failure of nodeinfotest · bb11c553
      Eric Blake 提交于
      When running 'make check' under a multi-cpu Dom0 xen machine,
      nodeinfotest had a spurious failure it was reading from
      /sys/devices/system/cpu, but xen has no notion of topology.  The test
      was intended to be isolated from reading any real system files; the
      regression was introduced in Mar 2010 with commit aa2f6f96.
      
      Fix things by allowing an early exit for the testsuite.
      
      * src/nodeinfo.c (linuxNodeInfoCPUPopulate): Add parameter.
      (nodeGetInfo): Adjust caller.
      * tests/nodeinfotest.c (linuxTestCompareFiles): Likewise.
      bb11c553
    • E
      build: allow older libselinux again · 8e2b26db
      Eric Blake 提交于
      * configure.ac (with_selinux): Check for <selinux/label.h>.
      * src/security/security_selinux.c (getContext): New function.
      (SELinuxRestoreSecurityFileLabel): Use it to restore compilation
      when using older libselinux.
      8e2b26db
    • W
      build: fix typo that broke 'make dist' · 4c6f6892
      Wen Congyang 提交于
      * src/Makefile.am (VMWARE_DRIVER_SOURCES): Fix vmware_driver.h.
      Signed-off-by: NWen Congyang <wency@cn.fujitsu.com>
      4c6f6892
  2. 20 12月, 2010 1 次提交
    • P
      bridge_driver: avoid double call to VIR_FREE · ed039abc
      Paweł Krześniak 提交于
      While not technically a double free (since VIR_FREE NULLs the
      pointer), this is unnecessary extra code.
      
      This crept in when the function was converted from virRun to virCommand.
      
      The AUTHORS file has also been updated.
      ed039abc
  3. 18 12月, 2010 8 次提交
  4. 17 12月, 2010 10 次提交
    • D
      Move QEMU hotplug helper code out of the QEMU driver · acabd9d0
      Daniel P. Berrange 提交于
      The QEMU driver file is far too large. Move all the hotplug
      helper code out into a separate file. No functional change.
      
      * src/qemu/qemu_hotplug.c, src/qemu/qemu_hotplug.h,
        src/Makefile.am: Add hotplug helper file
      * src/qemu/qemu_driver.c: Delete hotplug code
      acabd9d0
    • D
      Move QEMU domain lock / job helper code to separate file · 679d628c
      Daniel P. Berrange 提交于
      To allow the APIs to be used from separate files, move the domain
      lock / job helper code into qemu_domain.c
      
      * src/qemu/qemu_domain.c, src/qemu/qemu_domain.h: Add domain lock
        / job code
      * src/qemu/qemu_driver.c: Remove domain lock / job code
      679d628c
    • D
      Move QEMU driver lock helpers to a separate file · 22f4cb85
      Daniel P. Berrange 提交于
      To allow their use from other source files, move qemuDriverLock
      and qemuDriverUnlock to qemu_conf.h and make them non-static
      
      * src/qemu/qemu_conf.c, src/qemu/qemu_conf.h: Add qemuDriverLock
        qemuDriverUnlock
      * src/qemu/qemu_driver.c: Remove qemuDriverLock and qemuDriverUnlock
      22f4cb85
    • D
      Move QEMU hostdev helper code out of the QEMU driver · 01abc8a1
      Daniel P. Berrange 提交于
      The QEMU driver file is far too large. Move all the hostdev
      helper code out into a separate file. No functional change.
      
      * src/qemu/qemu_hostdev.c, src/qemu/qemu_hostdev.h,
        src/Makefile.am: Add hostdev helper file
      * src/qemu/qemu_driver.c: Delete hostdev code
      01abc8a1
    • D
      Move QEMU cgroup helper code out of the QEMU driver · 52271cfc
      Daniel P. Berrange 提交于
      The QEMU driver file is far too large. Move all the cgroup
      helper code out into a separate file. No functional change.
      
      * src/qemu/qemu_cgroup.c, src/qemu/qemu_cgroup.h,
        src/Makefile.am: Add cgroup helper file
      * src/qemu/qemu_driver.c: Delete cgroup code
      52271cfc
    • D
      Move QEMU audit helper code out of the QEMU driver · 1aecb634
      Daniel P. Berrange 提交于
      The QEMU driver file is far too large. Move all the audit
      helper code out into a separate file. No functional change.
      
      * src/qemu/qemu_audit.c, src/qemu/qemu_audit.h,
        src/Makefile.am: Add audit helper file
      * src/qemu/qemu_driver.c: Delete audit code
      1aecb634
    • D
      Move QEMU private data & namespace code into separate file · df4aabaf
      Daniel P. Berrange 提交于
      Move the code for handling the QEMU virDomainObjPtr private
      data, and custom XML namespace into a separate file
      
      * src/qemu/qemu_domain.c, src/qemu/qemu_domain.h: New file
        for private data & namespace code
      * src/qemu/qemu_driver.c, src/qemu/qemu_driver.h: Remove
        private data & namespace code
      * src/qemu/qemu_driver.h, src/qemu/qemu_command.h: Update
        includes
      * src/Makefile.am: Add src/qemu/qemu_domain.c
      df4aabaf
    • D
      Move QEMU command line management into a separate file · 0f2e4b9c
      Daniel P. Berrange 提交于
      The qemu_conf.c code is doing three jobs, driver config file
      loading, QEMU capabilities management and QEMU command line
      management. Move the command line code into its own file
      
      * src/qemu/qemu_command.c, src/qemu/qemu_command.h: New
        command line management code
      * src/qemu/qemu_conf.c, src/qemu/qemu_conf.h: Delete command
        line code
      * src/qemu/qemu_conf.h, src/qemu_conf.c: Adapt for API renames
      * src/Makefile.am: add src/qemu/qemu_command.c
      * src/qemu/qemu_monitor_json.c, src/qemu/qemu_monitor_text.c: Add
        import of qemu_command.h
      0f2e4b9c
    • D
      Move QEMU capabilities management into a separate file · d8ae147d
      Daniel P. Berrange 提交于
      The qemu_conf.c code is doing three jobs, driver config file
      loading, QEMU capabilities management and QEMU command line
      management. Move the capabilities code into its own file
      
      * src/qemu/qemu_capabilities.c, src/qemu/qemu_capabilities.h: New
        capabilities management code
      * src/qemu/qemu_conf.c, src/qemu/qemu_conf.h: Delete capabilities
        code
      * src/qemu/qemu_conf.h: Adapt for API renames
      * src/Makefile.am: add src/qemu/qemu_capabilities.c
      d8ae147d
    • E
      maint: doc fix · 02b4d34a
      Eric Blake 提交于
      * src/libvirt.c: Avoid duplicate word.
      02b4d34a
  5. 14 12月, 2010 15 次提交
    • H
      Add a new function doStartCPUs · 226f4054
      Hu Tao 提交于
      226f4054
    • H
      Add a new function doStopCPUs · fa139130
      Hu Tao 提交于
      fa139130
    • H
      54c68333
    • J
      cpu: Unify CPUID data structures · 8806c0db
      Jiri Denemark 提交于
      So far, CPUID data were stored in two different data structures. First
      of them was a structure allowing direct access for CPUID data according
      to function number and the second was a plain array of struct
      cpuX86cpuid. This was a silly design which resulted in converting data
      from one type to the other and back again or implementing similar
      functionality for both data structures.
      
      The patch leaves only the direct access structure. This makes the code
      both smaller and more maintainable since operations on different objects
      can use common low-level operations.
      
      All 57 tests for cpu subsystem still pass after this rewrite.
      8806c0db
    • J
      util: Fix logical error in virReportSystemErrorFull · 4262ff45
      Jiri Denemark 提交于
      4262ff45
    • J
      util: Fix error message in __virExec · 5b2c9f92
      Jiri Denemark 提交于
      Remove superfluous ": %s" suffix from the error message.
      5b2c9f92
    • M
      esx: Add support for storage volume cloning · e3fb2908
      Matthias Bolte 提交于
      e3fb2908
    • E
      selinux: avoid memory overhead of matchpathcon · 6679943f
      Eric Blake 提交于
      https://bugzilla.redhat.com/show_bug.cgi?id=658657
      
      * src/security/security_selinux.c
      (SELinuxRestoreSecurityFileLabel): Use selabel_lookup instead of
      matchpathcon.
      Suggested by Daniel Walsh.
      6679943f
    • E
      daemon, threads: plug a memory leak · 6e9a29c8
      Eric Blake 提交于
      * daemon/libvirtd.c (qemudStartWorker, qemudStartEventLoop): Avoid
      leaking pthread_attr resources.
      * src/util/threads-pthread.c (virThreadCreate): Likewise.
      6e9a29c8
    • E
      sysinfo: convert to virCommand · 3ce483af
      Eric Blake 提交于
      * src/util/sysinfo.c (virSysinfoRead): Use virCommand instead of
      virExec.
      3ce483af
    • E
      sysinfo: formatting cleanups · 046ca3f4
      Eric Blake 提交于
      * src/util/sysinfo.c: Indentation and () fixups.
      046ca3f4
    • E
      build: allow mingw compilation with virCommand · 3fbc30d9
      Eric Blake 提交于
      Allows compilation, but no creation of child processes yet.  Take it
      one step at a time.
      
      * src/util/util.c (virExecWithHook) [WIN32]: New dummy function.
      * src/libvirt_private.syms: Export it.
      3fbc30d9
    • E
      build: update gnulib for pipe on mingw · 65c0f17a
      Eric Blake 提交于
      * .gnulib: Update to latest.
      * bootstrap.conf (gnulib_modules): Import pipe-posix and waitpid
      for mingw.
      * src/remote/remote_driver.c (pipe) [WIN32]: Drop dead macro.
      * daemon/event.c (pipe) [WIN32]: Drop dead function.
      65c0f17a
    • O
      qemu: Introduce two new job types · 5faf88fe
      Osier Yang 提交于
      Currently, all of domain "save/dump/managed save/migration"
      use the same function "qemudDomainWaitForMigrationComplete"
      to wait the job finished, but the error messages are all
      about "migration", e.g. when a domain saving job is canceled
      by user, "migration was cancled by client" will be throwed as
      an error message, which will be confused for user.
      
      As a solution, intoduce two new job types(QEMU_JOB_SAVE,
      QEMU_JOB_DUMP), and set "priv->jobActive" to "QEMU_JOB_SAVE"
      before saving, to "QEMU_JOB_DUMP" before dumping, so that we
      could get the real job type in
      "qemudDomainWaitForMigrationComplete", and give more clear
      message further.
      
      And as It's not important to figure out what's the exact job
      is in the DEBUG and WARN log, also we don't need translated
      string in logs, simply repace "migration" with "job" in some
      statements.
      
      * src/qemu/qemu_driver.c
      5faf88fe
    • R
      802.1Qbh: Add support for IFLA_VF_MAC · 013c000a
      Roopa Prabhu 提交于
      Current code does not pass VM mac address to a 802.1Qbh direct attach
      interface using IFLA_VF_MAC.  This patch adds support in macvtap code to
      send IFLA_VF_MAC netlink request during port profile association on a
      802.1Qbh interface.
      
      Stefan Cc'ed for comments because this patch changes a condition for
      802.1Qbg
      
      802.1Qbh support for IFLA_VF_MAC in enic driver has been posted and is
      pending acceptance at http://marc.info/?l=linux-netdev&m=129185244410557&w=2
      013c000a
  6. 11 12月, 2010 3 次提交
    • E
      command: ease use with virBuffer, and fix qemu leak · e8d05c97
      Eric Blake 提交于
      * src/util/command.h (virCommandAddArgBuffer)
      (virCommandAddEnvBuffer): New prototypes.
      * src/util/command.c (virCommandAddArgBuffer)
      (virCommandAddEnvBuffer): Implement them.
      * src/libvirt_private.syms (command.h): Export them.
      * src/qemu/qemu_conf.c (qemudBuildCommandLine): Use them, plugging
      a memory leak on rbd_hosts in the process.
      e8d05c97
    • E
      conf: plug memory leaks · 20eb73e9
      Eric Blake 提交于
      * src/conf/domain_conf.c (virDomainGraphicsDefParseXML)
      (virDomainDeviceVirtioSerialAddressParseXML)
      (virDomainDiskDefFree): Free various leaks.
      20eb73e9
    • E
      virExec: avoid undefined behavior · c3568ec2
      Eric Blake 提交于
      * src/util/util.c (__virExec): Don't use FD_ISSET on out-of-bounds fd.
      c3568ec2