1. 10 4月, 2013 1 次提交
  2. 28 3月, 2013 1 次提交
  3. 21 3月, 2013 2 次提交
  4. 20 3月, 2013 1 次提交
  5. 14 3月, 2013 1 次提交
  6. 13 3月, 2013 2 次提交
    • M
      qemu_driver: Try KVM_CAP_MAX_VCPUS only if defined · 3b94239f
      Michal Privoznik 提交于
      With our recent patch (1715c83b) we thrive to get the correct
      number of maximal VCPUs. However, we are using a constant from
      linux/kvm.h which may be not defined in every distro. Hence, we
      should guard usage of the constant with ifdef preprocessor
      directive. This was introduced in kernel:
      
          commit 8c3ba334f8588e1d5099f8602cf01897720e0eca
          Author: Sasha Levin <levinsasha928@gmail.com>
          Date:   Mon Jul 18 17:17:15 2011 +0300
      
          KVM: x86: Raise the hard VCPU count limit
      
          The patch raises the hard limit of VCPU count to 254.
      
          This will allow developers to easily work on scalability
          and will allow users to test high VCPU setups easily without
          patching the kernel.
      
          To prevent possible issues with current setups, KVM_CAP_NR_VCPUS
          now returns the recommended VCPU limit (which is still 64) - this
          should be a safe value for everybody, while a new KVM_CAP_MAX_VCPUS
          returns the hard limit which is now 254.
      
      $ git desc 8c3ba334f
      v3.1-rc7-48-g8c3ba33
      3b94239f
    • P
      virCaps: conf: start splitting out irrelevat data · 27cf98e2
      Peter Krempa 提交于
      The virCaps structure gathered a ton of irrelevant data over time that.
      The original reason is that it was propagated to the XML parser
      functions.
      
      This patch aims to create a new data structure virDomainXMLConf that
      will contain immutable data that are used by the XML parser. This will
      allow two things we need:
      
      1) Get rid of the stuff from virCaps
      
      2) Allow us to add callbacks to check and add driver specific stuff
      after domain XML is parsed.
      
      This first attempt removes pointers to private data allocation functions
      to this new structure and update all callers and function that require
      them.
      27cf98e2
  7. 12 3月, 2013 1 次提交
  8. 08 3月, 2013 1 次提交
    • M
      qemuDomainBlockStatsFlags: Guard disk lookup with a domain job · 5a791c89
      Michal Privoznik 提交于
      When there are two concurrent threads, we may dereference a NULL
      pointer, even though it has been checked before:
      
      1. Thread1: starts executing qemuDomainBlockStatsFlags() with nparams != 0.
                  It finds given disk and successfully pass check for disk->info.alias
                  not being NULL.
      2. Thread2: starts executing qemuDomainDetachDeviceFlags() on the very same
                  disk as Thread1 is working on.
      3. Thread1: gets to qemuDomainObjBeginJob() where it sets a job on a
                  domain.
      4. Thread2: also tries to set a job. However, we are not guaranteed which
                  thread wins. So assume it's Thread2 who can continue.
      5. Thread2: does the actual detach and frees disk->info.alias
      6. Thread2: quits the job
      7. Thread1: now successfully acquires the job, and accesses a NULL pointer.
      5a791c89
  9. 06 3月, 2013 1 次提交
  10. 05 3月, 2013 1 次提交
  11. 04 3月, 2013 1 次提交
  12. 28 2月, 2013 3 次提交
  13. 27 2月, 2013 1 次提交
    • D
      Fix crash changing CDROM media · 02b90972
      Daniel P. Berrange 提交于
      This change tried to fix a crash with changing CDROM media but
      failed to actually do so
      
        commit d0172d2b
        Author: Osier Yang <jyang@redhat.com>
        Date:   Tue Feb 19 20:27:45 2013 +0800
      
          qemu: Remove the shared disk entry if the operation is ejecting or updating
      
      It was still accessing disk->src, when the entire 'disk' object
      has been free'd already. Even if it weren't free'd, accessing
      the 'src' value of virDomainDiskDef is not allowed without
      first validating disk->type is file or block. Just remove the
      broken code entirely.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      02b90972
  14. 26 2月, 2013 1 次提交
  15. 23 2月, 2013 2 次提交
  16. 21 2月, 2013 9 次提交
    • J
      qemu: Turn closeCallbacks into virObjectLockable · 3898ba7f
      Jiri Denemark 提交于
      To avoid having to hold the qemu driver lock while iterating through
      close callbacks and calling them. This fixes a real deadlock when a
      domain which is being migrated from another host gets autodestoyed as a
      result of broken connection to the other host.
      3898ba7f
    • G
      qemu: fix an off-by-one error in qemuDomainGetPercpuStats · 09183163
      Guannan Ren 提交于
      The max value of number of cpus to compute(id) should not
      be equal or greater than max cpu number.
      The bug ocurrs when id value is equal to max cpu number which
      leads to the off-by-one error in the following for loop.
      
       # virsh  cpu-stats guest --start 1
       error: Failed to virDomainGetCPUStats()
      
       error: internal error cpuacct parse error
      09183163
    • J
      Remove a couple of misplaced VIR_FREE · 2bff35d5
      John Ferlan 提交于
      2bff35d5
    • M
      qemu: Run lzop with '--ignore-warn' · 0eeedf52
      Michal Privoznik 提交于
      Currently, if lzop decompression binary produces a warning, it
      doesn't exit with zero status but 2 instead. Terrifying, but
      true. However, warnings may be ignored using '--ignore-warn'
      command line argument.  Moreover, in which case, the exit status
      will be zero.
      0eeedf52
    • O
      qemu: Remove the shared disk entry if the operation is ejecting or updating · d0172d2b
      Osier Yang 提交于
      For both AttachDevice and UpdateDevice APIs, if the disk device
      is 'cdrom' or 'floppy', the operations could be ejecting, updating,
      and inserting. For either ejecting or updating, the shared disk
      entry of the original disk src has to be removed, because it's
      not useful anymore.
      
      And since the original disk def will be changed, new disk def passed
      as argument will be free'ed in qemuDomainChangeEjectableMedia, so
      we need to copy the orignal disk def before
      qemuDomainChangeEjectableMedia, to use it for qemuRemoveSharedDisk.
      d0172d2b
    • O
      qemu: Move the shared disk adding and sgio setting prior to attaching · 0db7ff59
      Osier Yang 提交于
      The disk def could be free'ed by qemuDomainChangeEjectableMedia,
      which can thus cause crash if we reference the disk pointer. On
      the other hand, we have to remove the added shared disk entry from
      the table on error codepath.
      0db7ff59
    • O
      qemu: Record names of domain which uses the shared disk in hash table · a4504ac1
      Osier Yang 提交于
      The hash entry is changed from "ref" to {ref, @domains}. With this, the
      caller can simply call qemuRemoveSharedDisk, without afraid of removing
      the entry belongs to other domains. qemuProcessStart will obviously
      benifit from it on error codepath (which calls qemuProcessStop to do
      the cleanup).
      a4504ac1
    • O
      qemu: Merge qemuCheckSharedDisk into qemuAddSharedDisk · 371df778
      Osier Yang 提交于
      Based on moving various checking into qemuAddSharedDisk, this
      avoids the caller using it in wrong ways. Also this adds two
      new checking for qemuCheckSharedDisk (disk device not 'lun'
      and kernel doesn't support unpriv_sgio simply returns 0).
      371df778
    • O
      qemu: Add checking in helpers for sgio setting · dab878a8
      Osier Yang 提交于
      This moves the various checking into the helpers, to avoid the
      callers missing the checking.
      dab878a8
  17. 19 2月, 2013 1 次提交
  18. 13 2月, 2013 1 次提交
    • D
      Remove qemuDriverLock from almost everywhere · a9e97e0c
      Daniel P. Berrange 提交于
      With the majority of fields in the virQEMUDriverPtr struct
      now immutable or self-locking, there is no need for practically
      any methods to be using the QEMU driver lock. Only a handful
      of helper APIs in qemu_conf.c now need it
      a9e97e0c
  19. 11 2月, 2013 2 次提交
  20. 08 2月, 2013 4 次提交
  21. 06 2月, 2013 3 次提交