1. 23 10月, 2013 1 次提交
    • M
      python: Fix Create*WithFiles filefd passing · 713a4f4b
      Marian Neagul 提交于
      Commit d76227be added functions virDomainCreateWithFiles and
      virDomainCreateXMLWithFiles, but there was a little piece missing in
      python bindings.  This patch fixes proper passing of file descriptors
      in the overwrites of these functions.
      713a4f4b
  2. 18 7月, 2013 2 次提交
    • J
      Add VIR_DOMAIN_EVENT_ID_DEVICE_REMOVED event · 4421e257
      Jiri Denemark 提交于
      4421e257
    • D
      Introduce new domain create APIs to pass pre-opened FDs to LXC · d76227be
      Daniel P. Berrange 提交于
      With container based virt, it is useful to be able to pass
      pre-opened file descriptors to the container init process.
      This allows for containers to be auto-activated from incoming
      socket connections, passing the active socket into the container.
      
      To do this, introduce a pair of new APIs, virDomainCreateXMLWithFiles
      and virDomainCreateWithFiles, which accept an array of file
      descriptors. For the LXC driver, UNIX file descriptor passing
      will be used to send them to libvirtd, which will them pass
      them down to libvirt_lxc, which will then pass them to the container
      init process.
      
      This will only be implemented for LXC right now, but the design
      is generic enough it could work with other hypervisors, hence
      I suggest adding this to libvirt.so, rather than libvirt-lxc.so
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      d76227be
  3. 15 7月, 2013 1 次提交
    • G
      python: return dictionary without value in case of no blockjob · 0f9e67bf
      Guannan Ren 提交于
      Currently, when there is no blockjob, dom.blockJobInfo('vda')
      still reports error because it doesn't distinguish return value 0 from -1.
      libvirt.libvirtError: virDomainGetBlockJobInfo() failed
      
      virDomainGetBlockJobInfo() API return value:
       -1 in case of failure, 0 when nothing found, 1 found.
      
      And use PyDict_SetItemString instead of PyDict_SetItem when key is
      of string type. PyDict_SetItemString increments key/value reference
      count, so call Py_DECREF() for value. For key, we don't need to
      do this, because PyDict_SetItemString will handle it internally.
      0f9e67bf
  4. 11 7月, 2013 1 次提交
  5. 10 7月, 2013 1 次提交
  6. 25 6月, 2013 1 次提交
  7. 28 5月, 2013 1 次提交
    • E
      syntax: prefer space after semicolon in for loop · 146ba114
      Eric Blake 提交于
      I noticed several unusual spacings in for loops, and decided to
      fix them up.  See the next commit for the syntax check that found
      all of these.
      
      * examples/domsuspend/suspend.c (main): Fix spacing.
      * python/libvirt-override.c: Likewise.
      * src/conf/interface_conf.c: Likewise.
      * src/security/virt-aa-helper.c: Likewise.
      * src/util/virconf.c: Likewise.
      * src/util/virhook.c: Likewise.
      * src/util/virlog.c: Likewise.
      * src/util/virsocketaddr.c: Likewise.
      * src/util/virsysinfo.c: Likewise.
      * src/util/viruuid.c: Likewise.
      * src/vbox/vbox_tmpl.c: Likewise.
      * src/xen/xen_hypervisor.c: Likewise.
      * tools/virsh-domain-monitor.c (vshDomainStateToString): Drop
      default case, to let compiler check us.
      * tools/virsh-domain.c (vshDomainVcpuStateToString): Likewise.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      146ba114
  8. 21 5月, 2013 1 次提交
  9. 10 5月, 2013 1 次提交
  10. 02 5月, 2013 1 次提交
    • M
      virutil: Move string related functions to virstring.c · 7c9a2d88
      Michal Privoznik 提交于
      The source code base needs to be adapted as well. Some files
      include virutil.h just for the string related functions (here,
      the include is substituted to match the new file), some include
      virutil.h without any need (here, the include is removed), and
      some require both.
      7c9a2d88
  11. 20 4月, 2013 1 次提交
    • E
      docs: fix usage of 'onto' · 1bf25ba2
      Eric Blake 提交于
      http://www.uhv.edu/ac/newsletters/writing/grammartip2009.07.01.htm
      (and several other sites) give hints that 'onto' is best used if
      you can also add 'up' just before it and still make sense. In many
      cases in the code base, we really want the two-word form, or even
      a simplification to just 'on' or 'to'.
      
      * docs/hacking.html.in: Use correct 'on to'.
      * python/libvirt-override.c: Likewise.
      * src/lxc/lxc_controller.c: Likewise.
      * src/util/virpci.c: Likewise.
      * daemon/THREADS.txt: Use simpler 'on'.
      * docs/formatdomain.html.in: Better usage.
      * docs/internals/rpc.html.in: Likewise.
      * src/conf/domain_event.c: Likewise.
      * src/rpc/virnetclient.c: Likewise.
      * tests/qemumonitortestutils.c: Likewise.
      * HACKING: Regenerate.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      1bf25ba2
  12. 18 4月, 2013 1 次提交
  13. 21 3月, 2013 1 次提交
    • P
      python: Fix emulatorpin API bindings · d395c811
      Peter Krempa 提交于
      The addition of emulator pinning APIs didn't think of doing the right
      job with python APIs for them. The default generator produced unusable
      code for this.
      
      This patch switches to proper code as in the case of domain Vcpu pining.
      This change can be classified as a python API-breaker but in the state
      the code was before I doubt anyone was able to use it successfully.
      d395c811
  14. 23 2月, 2013 2 次提交
  15. 18 1月, 2013 1 次提交
  16. 17 1月, 2013 1 次提交
  17. 21 12月, 2012 2 次提交
  18. 04 12月, 2012 2 次提交
  19. 16 11月, 2012 1 次提交
  20. 02 11月, 2012 1 次提交
  21. 26 10月, 2012 2 次提交
  22. 15 10月, 2012 1 次提交
    • M
      Add support for SUSPEND_DISK event · 7ba5defb
      Martin Kletzander 提交于
      This patch adds support for SUSPEND_DISK event; both lifecycle and
      separated.  The support is added for QEMU, machines are changed to
      PMSUSPENDED, but as QEMU sends SHUTDOWN afterwards, the state changes
      to shut-off.  This and much more needs to be done in order for libvirt
      to work with transient devices, wake-ups etc.  This patch is not
      aiming for that functionality.
      7ba5defb
  23. 08 10月, 2012 1 次提交
    • G
      python: cleanup vcpu related binding APIs · 2832663f
      Guannan Ren 提交于
      libvirt_virDomainGetVcpus: add error handling, return -1 instead of None
      libvirt_virDomainPinVcpu and libvirt_virDomainPinVcpuFlags:
        check the type of argument
        make use of libvirt_boolUnwrap
      
        Set bitmap according to these values which are contained in given
        argument of vcpu tuple and turn off these bit corresponding to
        missing vcpus in argument tuple
      
        The original way ignored the error info from PyTuple_GetItem
        if index is out of range.
        "IndexError: tuple index out of range"
        The error message will only be raised on next command in interactive mode.
      2832663f
  24. 17 9月, 2012 4 次提交
    • O
      node_memory: Expose the APIs to Python bindings · 4c4c80df
      Osier Yang 提交于
      * python/libvirt-override-api.xml: (Add document to describe
        the APIs).
      * python/libvirt-override.c: (Implement the API wrappers manually)
      4c4c80df
    • O
      list: Expose virConnectListAllSecrets to Python binding · 473ee27e
      Osier Yang 提交于
      The implementation is done manually as the generator does not support
      wrapping lists of C pointers into Python objects.
      
      python/libvirt-override-api.xml: Document
      
      python/libvirt-override-virConnect.py: Implementation for listAllSecrets.
      
      python/libvirt-override.c: Implementation for the wrapper.
      473ee27e
    • O
      list: Expose virConnectListAllNWFilters to Python binding · f4c1efaa
      Osier Yang 提交于
      The implementation is done manually as the generator does not support
      wrapping lists of C pointers into Python objects.
      
      python/libvirt-override-api.xml: Document
      
      python/libvirt-override-virConnect.py:
        * Implementation for listAllNWFilters.
      
      python/libvirt-override.c: Implementation for the wrapper.
      f4c1efaa
    • O
      list: Expose virConnectListAllNodeDevices to Python binding · a3676b6c
      Osier Yang 提交于
      The implementation is done manually as the generator does not support
      wrapping lists of C pointers into Python objects.
      
      python/libvirt-override-api.xml: Document
      
      python/libvirt-override-virConnect.py:
        * Implementation for listAllNodeDevices.
      
      python/libvirt-override.c: Implementation for the wrapper.
      a3676b6c
  25. 12 9月, 2012 2 次提交
  26. 11 9月, 2012 4 次提交
  27. 10 9月, 2012 1 次提交
    • O
      list: Expose virStoragePoolListAllVolumes to Python binding · fa2e35a3
      Osier Yang 提交于
      The implementation is done manually as the generator does not support
      wrapping lists of C pointers into Python objects.
      
      python/libvirt-override-api.xml: Document
      
      python/libvirt-override-virStoragePool.py:
        * New file, includes implementation of listAllVolumes.
      
      python/libvirt-override.c: Implementation for the wrapper.
      fa2e35a3
  28. 07 9月, 2012 1 次提交
    • J
      Fix PMSuspend and PMWakeup events · afab4824
      Jiri Denemark 提交于
      The unused reason parameter of PM{Suspend,Wakeup} event callbacks was
      completely ignored in lot of places and those events were not actually
      working at all.
      afab4824