1. 23 2月, 2016 1 次提交
    • J
      libxl: add support for rbd qdisk · fb2bd208
      Jim Fehlig 提交于
      xl/libxl already supports qemu's network-based block backends
      such as nbd and rbd. libvirt has supported configuring such
      <disk>s for long time too. This patch adds support for rbd
      disks in the libxl driver by generating a rbd device URL from
      the virDomainDiskDef object. The URL is passed to libxl via the
      pdev_path field of libxl_device_disk struct. libxl then passes
      the URL to qemu for cosumption by the rbd backend.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      fb2bd208
  2. 10 2月, 2016 1 次提交
    • J
      libxl: keepalive messages support · 5194eb95
      Joao Martins 提交于
      This patch introduces keep alive messages support for P2P migration
      and it adds two new configuration entries namely 'keepalive_interval'
      'keepalive_count' to control it. Behavior of these entries is the
      same as qemu driver thus the description is copied from there
      with just a few simplifications.
      Signed-off-by: NJoao Martins <joao.m.martins@oracle.com>
      5194eb95
  3. 04 2月, 2016 1 次提交
  4. 09 1月, 2016 1 次提交
    • J
      libxl: support vif outgoing bandwidth QoS · f988ecfb
      Jim Fehlig 提交于
      The libxl_device_nic structure supports specifying an outgoing rate
      limit based on a time interval and bytes allowed per interval. In xl
      config a rate limit is specified as "<RATE>/s@<INTERVAL>". INTERVAL
      is optional and defaults to 50ms.
      
      libvirt expresses outgoing limits by average (required), peak, burst,
      and floor attributes in units of KB/s. This patch supports the outgoing
      bandwidth limit by converting the average KB/s to bytes per interval
      based on the same default interval (50ms) used by xl.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      f988ecfb
  5. 09 12月, 2015 2 次提交
  6. 08 10月, 2015 1 次提交
    • J
      libxl: Resolve Coverity FORWARD_NULL · f84c6dd2
      John Ferlan 提交于
      Since the strtok_r call in libxlCapsInitGuests expects a non NULL first
      parameter when the third parameter is NULL, we need to check that
      the returned 'capabilities' from a libxl_get_version_info call is
      not NULL and error out if so since the code expects it.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      f84c6dd2
  7. 16 9月, 2015 2 次提交
    • J
      libxl: fix compiler error introduced by commit ba25c214 · a4604eb0
      Jim Fehlig 提交于
      libxl/libxl_conf.c: In function 'libxlDriverConfigNew':
      libxl/libxl_conf.c:1560:30: error: 'log_level' may be used uninitialized
      in this function [-Werror=maybe-uninitialized]
      a4604eb0
    • J
      libxl: open libxl log stream with libvirtd log_level · ba25c214
      Jim Fehlig 提交于
      Instead of a hardcoded DEBUG log level, use the overall
      daemon log level specified in libvirtd.conf when opening
      a log stream with libxl. libxl is very verbose when DEBUG
      log level is set, resulting in huge log files that can
      potentially fill a disk. Control of libxl verbosity should
      be placed in the administrator's hands.
      ba25c214
  8. 02 9月, 2015 1 次提交
    • J
      qemu: add udp interface support · 5c668a78
      Jonathan Toppins 提交于
      Adds a new interface type using UDP sockets, this seems only applicable
      to QEMU but have edited tree-wide to support the new interface type.
      
      The interface type required the addition of a "localaddr" (local
      address), this then maps into the following xml and qemu call.
      
      <interface type='udp'>
        <mac address='52:54:00:5c:67:56'/>
        <source address='127.0.0.1' port='11112'>
          <local address='127.0.0.1' port='22222'/>
        </source>
        <model type='virtio'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0'/>
      </interface>
      
      QEMU call:
      	-net socket,udp=127.0.0.1:11112,localaddr=127.0.0.1:22222
      
      Notice the xml "local" entry becomes the "localaddr" for the qemu call.
      
      reference:
      http://lists.gnu.org/archive/html/qemu-devel/2011-11/msg00629.htmlSigned-off-by: NJonathan Toppins <jtoppins@cumulusnetworks.com>
      Signed-off-by: NJán Tomko <jtomko@redhat.com>
      5c668a78
  9. 13 6月, 2015 1 次提交
  10. 29 5月, 2015 3 次提交
  11. 13 5月, 2015 1 次提交
  12. 05 5月, 2015 1 次提交
  13. 30 4月, 2015 1 次提交
  14. 25 4月, 2015 2 次提交
  15. 22 4月, 2015 1 次提交
  16. 21 4月, 2015 3 次提交
  17. 17 4月, 2015 1 次提交
  18. 20 3月, 2015 1 次提交
    • J
      libxl: use xenlight pkgconfig file if present · 2adba7d3
      Jim Fehlig 提交于
      xen.git commit babeca32 added a pkgconfig file for libxenlight,
      allowing libxl apps to determine the location of Xen binaries
      such as firmware blobs, device emulator, etc.
      
      This patch adds support for xenlight.pc in the libxl driver, falling
      back to the previous configure logic if not found.  It introduces
      LIBXL_FIRMWARE_DIR and LIBXL_EXECBIN_DIR to define the firmware and
      libexec_bin locations.  If xenlight.pc does not exist, the defines
      are set to the current hardcoded paths.  The capabilities'
      <emulator> and <loader> elements are updated to use the paths.
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      2adba7d3
  19. 17 3月, 2015 1 次提交
    • J
      libxl: fix regression introduced by commit 4ab8cd77 · a7d6b94a
      Jim Fehlig 提交于
      Commit 4ab8cd77 added a check requiring input devices to have
      a bus type of VIR_DOMAIN_INPUT_BUS_USB, failing to start the
      domain otherwise.  But virDomainDefParseXML adds implicit mouse
      and keyboard if a graphics device is configured.  See calls to
      virDomainDefMaybeAddInput.
      
      The regression is fixed by removing the check requiring USB input
      devices, and skipping non-USB input devices when populating USB
      'usbdevice' in libxl_domain_build_info struct.
      a7d6b94a
  20. 16 3月, 2015 1 次提交
    • P
      conf: Replace access to def->mem.max_balloon with accessor functions · 4f9907cd
      Peter Krempa 提交于
      As there are two possible approaches to define a domain's memory size -
      one used with legacy, non-NUMA VMs configured in the <memory> element
      and per-node based approach on NUMA machines - the user needs to make
      sure that both are specified correctly in the NUMA case.
      
      To avoid this burden on the user I'd like to replace the NUMA case with
      automatic totaling of the memory size. To achieve this I need to replace
      direct access to the virDomainMemtune's 'max_balloon' field with
      two separate getters depending on the desired size.
      
      The two sizes are needed as:
      1) Startup memory size doesn't include memory modules in some
      hypervisors.
      2) After startup these count as the usable memory size.
      
      Note that the comments for the functions are future aware and document
      state that will be present after a few later patches.
      4f9907cd
  21. 14 3月, 2015 1 次提交
  22. 21 2月, 2015 1 次提交
  23. 12 2月, 2015 2 次提交
  24. 03 12月, 2014 1 次提交
    • J
      Replace virNetworkFree with virObjectUnref · 121c09a9
      John Ferlan 提交于
      Since virNetworkFree will call virObjectUnref anyway, let's just use that
      directly so as to avoid the possibility that we inadvertently clear out
      a pending error message when using the public API.
      121c09a9
  25. 31 10月, 2014 2 次提交
    • J
      libxl: fix double-free of libxl_domain_build_info · 720be2eb
      Jim Fehlig 提交于
      On error, libxlMakeDomBuildInfo() frees the caller-provided
      libxl_domain_build_info struct embedded in libxl_domain_config,
      causing a segfault
      
      Program received signal SIGSEGV, Segmentation fault.
      [Switching to Thread 0x7f9c13020700 (LWP 40988)]
      (gdb) bt
      0  0x00007f9c162f95b4 in free () from /lib64/libc.so.6
      1  0x00007f9c0d0965ad in libxl_bitmap_dispose () from
         /usr/lib64/libxenlight.so.4.4
      2  0x00007f9c0d0a73bf in libxl_domain_build_info_dispose ()
         from /usr/lib64/libxenlight.so.4.4
      3  0x00007f9c0d0a7974 in libxl_domain_config_dispose () from
         /usr/lib64/libxenlight.so.4.4
      4  0x00007f9c0d2e00c5 in libxlDomainStart (driver=0x7f9c0400e4e0,
         vm=0x7f9c0412b0d0, start_paused=false, restore_fd=-1) at
         libxl/libxl_domain.c:1323
      5  0x00007f9c0d2e1d4b in libxlDomainCreateXML (conn=0x7f9c000009a0,...)
         at libxl/libxl_driver.c:660
      
      Remove the call to libxl_domain_build_info_dispose() from
      libxlMakeDomBuildInfo().  On error, callers will dispose the
      libxl_domain_config object, which in turn disposes the build info.
      720be2eb
    • J
      libxl: Support user-specified <emulator> · 1c0bf509
      Jim Fehlig 提交于
      With the introduction of the libxlDomainGetEmulatorType function,
      it is trivial to support a user-specfied <emulator> in the libxl
      driver.  This patch is based loosely on David Scott's old patch
      to do the same
      
      https://www.redhat.com/archives/libvir-list/2013-April/msg02119.htmlSigned-off-by: NJim Fehlig <jfehlig@suse.com>
      1c0bf509
  26. 11 10月, 2014 3 次提交
    • S
      libxl: Implement basic video device selection · 1298daca
      Stefan Bader 提交于
      This started as an investigation into an issue where libvirt (using the
      libxl driver) and the Xen host, like an old couple, could not agree on
      who is responsible for selecting the VNC port to use.
      
      Things usually (and a bit surprisingly) did work because, just like that
      old couple, they had the same idea on what to do by default. However it
      was possible that this ended up in a big argument.
      
      The problem is that display information exists in two different places:
      in the vfbs list and in the build info. And for launching the device model,
      only the latter is used. But that never gets initialized from libvirt. So
      Xen allows the device model to select a default port while libvirt thinks
      it has told Xen that this is done by libvirt (though the vfbs config).
      
      While fixing that, I made a stab at actually evaluating the configuration
      of the video device. So that it is now possible to at least decide between
      a Cirrus or standard VGA emulation and to modify the VRAM within certain
      limits using libvirt.
      Signed-off-by: NStefan Bader <stefan.bader@canonical.com>
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      1298daca
    • J
      libxl: Add function to determine device model type · c5a00350
      Jim Fehlig 提交于
      This patch introduces a function to detect whether the specified
      emulator is QEMU_XEN or QEMU_XEN_TRADITIONAL.  Detection is based on the
      string "Options specific to the Xen version:" in '$qemu -help' output.
      AFAIK, the only qemu containing that string in help output is the
      old Xen fork (aka qemu-dm).
      
      Note:
      QEMU_XEN means a qemu that contains support for Xen.
      
      QEMU_XEN_TRADITIONAL means Xen's old forked qemu 0.10.2
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      c5a00350
    • J
      libxl: Copy user-specified keymap to libxl build info struct · be28ae16
      Jim Fehlig 提交于
      Commit 4dfc34c3 missed copying the user-specified keymap to
      libxl_domain_build_info struct when creating a VFB device.
      Signed-off-by: NStefan Bader <stefan.bader@canonical.com>
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      be28ae16
  27. 12 9月, 2014 1 次提交
  28. 04 9月, 2014 1 次提交
    • E
      maint: use consistent if-else braces in xen and friends · fb6d6507
      Eric Blake 提交于
      I'm about to add a syntax check that enforces our documented
      HACKING style of always using matching {} on if-else statements.
      
      This patch focuses on code related to xen.
      
      * src/libxl/libxl_conf.c (libxlCapsInitGuests)
      (libxlMakeDomBuildInfo): Correct use of {}.
      * src/xen/xen_hypervisor.c (virXen_getvcpusinfo)
      (xenHypervisorMakeCapabilitiesInternal): Likewise.
      * src/xen/xend_internal.c (xenDaemonOpen)
      (xenDaemonDomainMigratePerform, xend_detect_config_version)
      (xenDaemonDetachDeviceFlags, xenDaemonDomainMigratePerform)
      (xenDaemonDomainBlockPeek): Likewise.
      * src/xenapi/xenapi_driver.c (xenapiConnectListDomains)
      (xenapiDomainLookupByUUID, xenapiDomainGetOSType): Likewise.
      * src/xenconfig/xen_common.c (xenParseCPUFeatures, xenFormatNet):
      Likewise.
      * src/xenconfig/xen_sxpr.c (xenParseSxpr, xenFormatSxprNet)
      (xenFormatSxpr): Likewise.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      fb6d6507
  29. 26 8月, 2014 1 次提交