1. 24 1月, 2020 1 次提交
    • D
      qemu: fixing auto-detecting binary in domain capabilities · 6d786f95
      Daniel P. Berrangé 提交于
      The virConnectGetDomainCapabilities API accepts either a binary path
      to the emulator, or desired guest arch. If guest arch is not given,
      then the host arch is assumed.
      
      In the case where the binary is not given, the code tried to find the
      emulator binary in the existing list of cached emulator capabilities.
      This is not valid since we switched to lazy population of the cache in:
      
        commit 3dd91af0
        Author: Daniel P. Berrangé <berrange@redhat.com>
        Date:   Mon Dec 2 13:04:26 2019 +0000
      
          qemu: stop creating capabilities at driver startup
      
      As a result of this change, if there are no persistent guests defined
      using the requested guest architecture, virConnectGetDomainCapabilities
      will fail to find an emulator binary.
      
      The solution is to stop relying on the cached capabilities to find the
      binary and instead use the same logic we use to pick default a binary
      per arch when populating capabilities.
      Tested-by: NBoris Fiuczynski <fiuczy@linux.ibm.com>
      Tested-by: NRichard W.M. Jones <rjones@redhat.com>
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      6d786f95
  2. 23 1月, 2020 1 次提交
  3. 17 1月, 2020 1 次提交
  4. 16 1月, 2020 1 次提交
  5. 13 1月, 2020 1 次提交
  6. 07 1月, 2020 1 次提交
  7. 24 12月, 2019 3 次提交
  8. 17 12月, 2019 1 次提交
  9. 10 12月, 2019 1 次提交
  10. 09 12月, 2019 8 次提交
  11. 03 12月, 2019 2 次提交
  12. 26 11月, 2019 1 次提交
    • M
      qemu_capabilities: Use proper free function for caps->cpuModels · 9b1d53d4
      Michal Privoznik 提交于
      The cpuModels member of _virQEMUCapsAccel struct is not a
      virObject but regular struct with a free function defined:
      qemuMonitorCPUDefsFree(). Use that when clearing parent structure
      instead of virObjectUnref() to avoid a memleak:
      
      ==212322== 57,275 (48 direct, 57,227 indirect) bytes in 3 blocks are definitely lost in loss record 623 of 627
      ==212322==    at 0x4838B86: calloc (vg_replace_malloc.c:762)
      ==212322==    by 0x554A158: g_malloc0 (in /usr/lib64/libglib-2.0.so.0.6000.6)
      ==212322==    by 0x17B14BF5: qemuMonitorCPUDefsNew (qemu_monitor.c:3587)
      ==212322==    by 0x17B27BA7: qemuMonitorJSONGetCPUDefinitions (qemu_monitor_json.c:5616)
      ==212322==    by 0x17B14B0B: qemuMonitorGetCPUDefinitions (qemu_monitor.c:3559)
      ==212322==    by 0x17A6AFBB: virQEMUCapsFetchCPUDefinitions (qemu_capabilities.c:2571)
      ==212322==    by 0x17A6B2CC: virQEMUCapsProbeQMPCPUDefinitions (qemu_capabilities.c:2629)
      ==212322==    by 0x17A70C00: virQEMUCapsInitQMPMonitorTCG (qemu_capabilities.c:4769)
      ==212322==    by 0x17A70DDF: virQEMUCapsInitQMPSingle (qemu_capabilities.c:4820)
      ==212322==    by 0x17A70E99: virQEMUCapsInitQMP (qemu_capabilities.c:4848)
      ==212322==    by 0x17A71044: virQEMUCapsNewForBinaryInternal (qemu_capabilities.c:4891)
      ==212322==    by 0x17A7119C: virQEMUCapsNewData (qemu_capabilities.c:4923)
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      Reviewed-by: NJiri Denemark <jdenemar@redhat.com>
      9b1d53d4
  13. 22 11月, 2019 5 次提交
  14. 21 11月, 2019 13 次提交