1. 21 5月, 2010 2 次提交
  2. 19 5月, 2010 2 次提交
    • J
      maint: more VIR_WARN corrections: now manually · acd981e3
      Jim Meyering 提交于
      * po/POTFILES.in: Remove src/util/logging.c and src/util/uuid.c.
      * src/phyp/phyp_driver.c (phypUUIDTable_ReadFile): Correct more
      VIR_WARN uses, now manually.
      (phypUUIDTable_Init, phypUUIDTable_Pull): Likewise.
      acd981e3
    • J
      maint: use VIR_WARN0("...") rather than VIR_WARN("%s", "...") · 3f76a993
      Jim Meyering 提交于
      Run this command:
        git grep -l 'VIR_WARN("%s", "'|xargs perl -pi -e \
          's/VIR_WARN\("%s", "/VIR_WARN0("/'
      * src/phyp/phyp_driver.c (phypDomainGetInfo): Perform the above.
      (phypDomainCreateAndStart, phypUUIDTable_ReadFile): Likewise.
      3f76a993
  3. 07 5月, 2010 1 次提交
    • E
      build: update gnulib · 062a25f0
      Eric Blake 提交于
      81 patches to gnulib, picks up several new syntax checks.
      
      * .gnulib: Update to latest.
      * .x-sc_prohibit_always_true_header_tests: New file.
      * bootstrap.conf (gnulib_modules): Add sched.
      * src/util/processinfo.c (includes): <sched.h> is now guaranteed.
      * src/network/bridge_driver.c (includes): Drop useless
      <strings.h>.
      * src/openvz/openvz_conf.c (includes): Likewise.
      * src/openvz/openvz_driver.c (includes): Likewise.
      * src/phyp/phyp_driver.c (includes): Likewise.
      * src/qemu/qemu_driver.c (includes): Likewise.
      * src/uml/uml_driver.c (includes): Likewise.
      062a25f0
  4. 30 4月, 2010 1 次提交
    • D
      Internal driver API infrastructure for virDomainGetBlockInfo · 46bad512
      Daniel P. Berrange 提交于
      This defines the internal driver API and stubs out each driver
      
      * src/driver.h: Define virDrvDomainGetBlockInfo signature
      * src/libvirt.c, src/libvirt_public.syms: Glue public API to drivers
      * src/esx/esx_driver.c, src/lxc/lxc_driver.c, src/opennebula/one_driver.c,
        src/openvz/openvz_driver.c, src/phyp/phyp_driver.c,
        src/test/test_driver.c, src/uml/uml_driver.c, src/vbox/vbox_tmpl.c,
        src/xen/xen_driver.c, src/xenapi/xenapi_driver.c: Stub out driver
      46bad512
  5. 07 4月, 2010 1 次提交
  6. 06 4月, 2010 1 次提交
  7. 05 4月, 2010 1 次提交
  8. 04 4月, 2010 1 次提交
    • D
      Add managed save API entry points · 15c647a9
      Daniel Veillard 提交于
      virDomainManagedSave() is to be run on a running domain. Once the call
      complete, as in virDomainSave() the domain is stopped upon completion,
      but there is no restore counterpart as any order to start the domain
      from the API would load the state from the managed file, similary if
      the domain is autostarted when libvirtd starts.
      Once a domain has restarted his managed save image is destroyed,
      basically managed save image can only exist for a stopped domain,
      for a running domain that would be by definition outdated data.
      
      * include/libvirt/libvirt.h.in src/libvirt.c src/libvirt_public.syms:
        adds the new entry points virDomainManagedSave(),
        virDomainHasManagedSaveImage() and virDomainManagedSaveRemove()
      * src/driver.h src/esx/esx_driver.c src/lxc/lxc_driver.c
        src/opennebula/one_driver.c  src/openvz/openvz_driver.c
        src/phyp/phyp_driver.c src/qemu/qemu_driver.c src/vbox/vbox_tmpl.c
        src/remote/remote_driver.c src/test/test_driver.c src/uml/uml_driver.c
        src/xen/xen_driver.c: add corresponding new internal drivers entry
        points
      15c647a9
  9. 26 3月, 2010 2 次提交
    • D
      Introduce a new virDomainUpdateDeviceFlags public API · 46a2ea36
      Daniel P. Berrange 提交于
      The current virDomainAttachDevice API can be (ab)used to change
      the media of an existing CDROM/Floppy device. Going forward there
      will be more devices that can be configured on the fly and overloading
      virDomainAttachDevice for this is not too pleasant. This patch adds
      a new virDomainUpdateDeviceFlags() explicitly just for modifying
      existing devices.
      
      * include/libvirt/libvirt.h.in: Add virDomainUpdateDeviceFlags
      * src/driver.h: Internal API for virDomainUpdateDeviceFlags
      * src/libvirt.c, src/libvirt_public.syms: Glue public API to
        driver API
      * src/esx/esx_driver.c, src/lxc/lxc_driver.c, src/opennebula/one_driver.c,
        src/openvz/openvz_driver.c, src/phyp/phyp_driver.c, src/qemu/qemu_driver.c,
        src/remote/remote_driver.c, src/test/test_driver.c, src/uml/uml_driver.c,
        src/vbox/vbox_tmpl.c, src/xen/xen_driver.c, src/xenapi/xenapi_driver.c: Add
        stubs for new driver entry point
      46a2ea36
    • D
      Introduce a new public API for domain events · 44457238
      Daniel P. Berrange 提交于
      The current API for domain events has a number of problems
      
       - Only allows for domain lifecycle change events
       - Does not allow the same callback to be registered multiple times
       - Does not allow filtering of events to a specific domain
      
      This introduces a new more general purpose domain events API
      
        typedef enum {
           VIR_DOMAIN_EVENT_ID_LIFECYCLE = 0,       /* virConnectDomainEventCallback */
            ...more events later..
        }
      
        int virConnectDomainEventRegisterAny(virConnectPtr conn,
                                             virDomainPtr dom, /* Optional, to filter */
                                             int eventID,
                                             virConnectDomainEventGenericCallback cb,
                                             void *opaque,
                                             virFreeCallback freecb);
      
        int virConnectDomainEventDeregisterAny(virConnectPtr conn,
                                               int callbackID);
      
      Since different event types can received different data in the callback,
      the API is defined with a generic callback. Specific events will each
      have a custom signature for their callback. Thus when registering an
      event it is neccessary to cast the callback to the generic signature
      
      eg
      
        int myDomainEventCallback(virConnectPtr conn,
                                  virDomainPtr dom,
                                  int event,
                                  int detail,
                                  void *opaque)
        {
          ...
        }
      
        virConnectDomainEventRegisterAny(conn, NULL,
                                         VIR_DOMAIN_EVENT_ID_LIFECYCLE,
                                         VIR_DOMAIN_EVENT_CALLBACK(myDomainEventCallback)
                                         NULL, NULL);
      
      The VIR_DOMAIN_EVENT_CALLBACK() macro simply does a "bad" cast
      to the generic signature
      
      * include/libvirt/libvirt.h.in: Define new APIs for registering
        domain events
      * src/driver.h: Internal driver entry points for new events APIs
      * src/libvirt.c: Wire up public API to driver API for events APIs
      * src/libvirt_public.syms: Export new APIs
      * src/esx/esx_driver.c, src/lxc/lxc_driver.c, src/opennebula/one_driver.c,
        src/openvz/openvz_driver.c, src/phyp/phyp_driver.c,
        src/qemu/qemu_driver.c, src/remote/remote_driver.c,
        src/test/test_driver.c, src/uml/uml_driver.c,
        src/vbox/vbox_tmpl.c, src/xen/xen_driver.c,
        src/xenapi/xenapi_driver.c: Stub out new API entries
      44457238
  10. 20 3月, 2010 1 次提交
  11. 17 3月, 2010 1 次提交
  12. 08 3月, 2010 1 次提交
    • E
      build: consistently use C99 varargs macros · 2e56fb2b
      Eric Blake 提交于
      Prior to this patch, there was an inconsistent mix between GNU and C99.
      
      For consistency, and potential portability to other compilers, stick
      with the C99 vararg macro syntax.
      
      * src/conf/cpu_conf.c (virCPUReportError): Use C99 rather than GNU
        vararg macro syntax.
      * src/conf/domain_conf.c (virDomainReportError): Likewise.
      * src/conf/domain_event.c (eventReportError): Likewise.
      * src/conf/interface_conf.c (virInterfaceReportError): Likewise.
      * src/conf/network_conf.c (virNetworkReportError): Likewise.
      * src/conf/node_device_conf.h (virNodeDeviceReportError): Likewise.
      * src/conf/secret_conf.h (virSecretReportError): Likewise.
      * src/conf/storage_conf.h (virStorageReportError): Likewise.
      * src/esx/esx_device_monitor.c (ESX_ERROR): Use C99 rather than
        GNU vararg macro syntax.
      * src/esx/esx_driver.c (ESX_ERROR): Likewise.
      * src/esx/esx_interface_driver.c (ESX_ERROR): Likewise.
      * src/esx/esx_network_driver.c (ESX_ERROR): Likewise.
      * src/esx/esx_secret_driver.c (ESX_ERROR): Likewise.
      * src/esx/esx_storage_driver.c (ESX_ERROR): Likewise.
      * src/esx/esx_util.c (ESX_ERROR): Likewise.
      * src/esx/esx_vi.c (ESX_VI_ERROR): Likewise.
      * src/esx/esx_vi_methods.c (ESX_VI_ERROR): Likewise.
      * src/esx/esx_vi_types.c (ESX_VI_ERROR): Likewise.
      * src/esx/esx_vmx.c (ESX_ERROR): Likewise.
      * src/util/hostusb.c (usbReportError): Use C99 rather than GNU
        vararg macro syntax.
      * src/util/json.c (virJSONError): Likewise.
      * src/util/macvtap.c (ReportError): Likewise.
      * src/util/pci.c (pciReportError): Likewise.
      * src/util/stats_linux.c (virStatsError): Likewise.
      * src/util/util.c (virUtilError): Likewise.
      * src/util/xml.c (virXMLError): Likewise.
      * src/xen/proxy_internal.c (virProxyError): Use C99 rather than
        GNU vararg macro syntax.
      * src/xen/sexpr.c (virSexprError): Likewise.
      * src/xen/xen_driver.c (xenUnifiedError): Likewise.
      * src/xen/xen_hypervisor.c (virXenError): Likewise.
      * src/xen/xen_inotify.c (virXenInotifyError): Likewise.
      * src/xen/xend_internal.c (virXendError): Likewise.
      * src/xen/xm_internal.c (xenXMError): Likewise.
      * src/xen/xs_internal.c (virXenStoreError): Likewise.
      * src/cpu/cpu.h (virCPUReportError): Use C99 rather than GNU
        vararg macro syntax.
      * src/datatypes.c (virLibConnError): Likewise.
      * src/interface/netcf_driver.c (interfaceReportError): Likewise.
      * src/libvirt.c (virLibStreamError): Likewise.
      * src/lxc/lxc_conf.h (lxcError): Likewise.
      * src/network/bridge_driver.c (networkReportError): Likewise.
      * src/nodeinfo.c (nodeReportError): Likewise.
      * src/opennebula/one_conf.h (oneError): Likewise.
      * src/openvz/openvz_conf.h (openvzError): Likewise.
      * src/phyp/phyp_driver.c (PHYP_ERROR): Likewise.
      * src/qemu/qemu_conf.h (qemuReportError): Likewise.
      * src/remote/remote_driver.c (errorf): Likewise.
      * src/security/security_driver.h (virSecurityReportError): Likewise.
      * src/test/test_driver.c (testError): Likewise.
      * src/uml/uml_conf.h (umlReportError): Likewise.
      * src/vbox/vbox_driver.c (vboxError): Likewise.
      * src/vbox/vbox_tmpl.c (vboxError): Likewise.
      2e56fb2b
  13. 03 3月, 2010 2 次提交
    • D
      Wire up internal entry points for virDomainAbortJob API · 0d8aa35f
      Daniel P. Berrange 提交于
      This provides the internal glue for the driver API
      
      * src/driver.h: Internal API contract
      * src/libvirt.c, src/libvirt_public.syms: Connect public API
        to driver API
      * src/esx/esx_driver.c, src/lxc/lxc_driver.c, src/opennebula/one_driver.c,
        src/openvz/openvz_driver.c, src/phyp/phyp_driver.c,
        src/qemu/qemu_driver.c, src/remote/remote_driver.c,
        src/test/test_driver.c src/uml/uml_driver.c, src/vbox/vbox_tmpl.c,
        src/xen/xen_driver.c: Stub out entry points
      0d8aa35f
    • D
      Stub out internal driver entry points for job processing · 92bd859a
      Daniel P. Berrange 提交于
      The internal glue layer for the new pubic API
      
      * src/driver.h: Define internal driver API contract
      * src/libvirt.c, src/libvirt_public.syms: Wire up public
        API to internal driver API
      * src/esx/esx_driver.c, src/lxc/lxc_driver.c, src/opennebula/one_driver.c,
        src/openvz/openvz_driver.c, src/phyp/phyp_driver.c,
        src/qemu/qemu_driver.c, src/remote/remote_driver.c,
        src/test/test_driver.c, src/uml/uml_driver.c, src/vbox/vbox_tmpl.c,
        src/xen/xen_driver.c: Stub new entry point
      92bd859a
  14. 02 3月, 2010 1 次提交
  15. 12 2月, 2010 1 次提交
  16. 10 2月, 2010 1 次提交
  17. 09 2月, 2010 3 次提交
  18. 20 12月, 2009 1 次提交
    • A
      Add new API virDomainMemoryStats to header and drivers · 3a701313
      Adam Litke 提交于
      Set up the types for the domainMemoryStats function and insert it into the
      virDriver structure definition.  Because of static initializers, update
      every driver and set the new field to NULL.
      
      * include/libvirt/libvirt.h.in: new API
      * src/driver.h src/*/*_driver.c src/vbox/vbox_tmpl.c: add the new
        entry to the driver structure
      * python/generator.py: fix compiler errors, the actual python binding is
        implemented later
      3a701313
  19. 18 12月, 2009 1 次提交
    • J
      Adds the internal driver API · 16e4084a
      Jiri Denemark 提交于
      * src/driver.h: add an extra entry point in the structure
      * src/esx/esx_driver.c src/lxc/lxc_driver.c src/opennebula/one_driver.c
        src/openvz/openvz_driver.c src/phyp/phyp_driver.c src/qemu/qemu_driver.c
        src/remote/remote_driver.c src/test/test_driver.c src/uml/uml_driver.c
        src/vbox/vbox_tmpl.c src/xen/xen_driver.c: add NULL entry points for
        all drivers
      16e4084a
  20. 10 12月, 2009 1 次提交
    • M
      Add virBufferFreeAndReset() and replace free() · 1b9d0744
      Matthias Bolte 提交于
      Replace free(virBufferContentAndReset()) with virBufferFreeAndReset().
      Update documentation and replace all remaining calls to free() with
      calls to VIR_FREE(). Also add missing calls to virBufferFreeAndReset()
      and virReportOOMError() in OOM error cases.
      1b9d0744
  21. 08 12月, 2009 1 次提交
  22. 12 11月, 2009 1 次提交
    • C
      Add virConnectGetLibvirtVersion API · ce4c0bf5
      Cole Robinson 提交于
      There is currently no way to determine the libvirt version of a remote
      libvirtd we are connected to. This is a useful piece of data to enable
      feature detection.
      ce4c0bf5
  23. 11 11月, 2009 4 次提交
    • E
      phyp: too much timeout when polling socket · 49169367
      Eduardo Otubo 提交于
      * src/phyp/phyp_driver.c: a 10s timeout on socket availability was way
        too long, reduced to 1ms
      49169367
    • E
      phyp: Reorder keyboard_interactive label in openSSHSession() · a32c43d6
      Eduardo Otubo 提交于
      Finish changes intended to be part of commit
      6c708023
      a32c43d6
    • D
      Implmentation of new APIs to checking state/persistence of objects · cabc2cc9
      Daniel P. Berrange 提交于
      This implements the virConnectIsSecure, virConnectIsEncrypted,
      virDomainIsPersistent, virDomainIsActive, virNetworkIsActive,
      virNetworkIsPersistent, virStoragePoolIsActive,
      virStoragePoolIsPersistent, virInterfaceIsActive APIs in
      (nearly) all drivers. Exceptions are:
      
       phyp: missing domainIsActive/Persistent
       esx: missing domainIsPersistent
       opennebula: missing domainIsActive/Persistent
      
      * src/remote/remote_protocol.x: Define remote wire ABI for newly
        added APIs.
      * daemon/remote_dispatch*.h: Re-generated from remote_protocol.x
      * src/esx/esx_driver.c, src/lxc/lxc_driver.c, src/network/bridge_driver.c,
        src/opennebula/one_driver.c, src/openvz/openvz_conf.c,
        src/openvz/openvz_driver.c, src/phyp/phyp_driver.c,
        src/remote/remote_driver.c, src/storage/storage_driver.c,
        src/test/test_driver.c, src/uml/uml_driver.c, src/vbox/vbox_tmpl.c,
        src/xen/xen_driver.c, src/xen/xen_driver.h, src/xen/xen_inotify.c,
        src/xen/xen_inotify.h: Implement all the new APIs where possible
      cabc2cc9
    • D
      New APIs for checking some object properties · c04498b3
      Daniel P. Berrange 提交于
      Introduce a number of new APIs to  expose some boolean properties
      of objects, which cannot otherwise reliably determined, nor are
      aspects of the XML configuration.
      
       * virDomainIsActive: Checking virDomainGetID is not reliable
         since it is not possible to distinguish between error condition
         and inactive domain for ID of -1.
       * virDomainIsPersistent: Check whether a persistent config exists
         for the domain
      
       * virNetworkIsActive: Check whether the network is active
       * virNetworkIsPersistent: Check whether a persistent config exists
         for the network
      
       * virStoragePoolIsActive: Check whether the storage pool is active
       * virStoragePoolIsPersistent: Check whether a persistent config exists
         for the storage pool
      
       * virInterfaceIsActive: Check whether the host interface is active
      
       * virConnectIsSecure: whether the communication channel to the
         hypervisor is secure
       * virConnectIsEncrypted: whether any network based commnunication
         channels are encrypted
      
      NB, a channel can be secure, even if not encrypted, eg if it does
      not involve the network, like a UNIX socket, or pipe.
      
       * include/libvirt/libvirt.h.in: Define public API
       * src/driver.h: Define internal driver API
       * src/libvirt.c: Implement public API entry point
       * src/libvirt_public.syms: Export API symbols
       * src/esx/esx_driver.c, src/lxc/lxc_driver.c,
         src/interface/netcf_driver.c, src/network/bridge_driver.c,
         src/opennebula/one_driver.c, src/openvz/openvz_driver.c,
         src/phyp/phyp_driver.c, src/qemu/qemu_driver.c,
         src/remote/remote_driver.c, src/test/test_driver.c,
         src/uml/uml_driver.c, src/vbox/vbox_tmpl.c,
         src/xen/xen_driver.c: Stub out driver tables
      c04498b3
  24. 10 11月, 2009 2 次提交
  25. 07 11月, 2009 6 次提交