1. 06 3月, 2017 1 次提交
    • J
      conf: Introduce virinterfaceobj · eabeff8e
      John Ferlan 提交于
      Move all the InterfaceObj API's into their own module virinterfaceobj
      from the interface_conf
      
      Purely code motion at this point.
      eabeff8e
  2. 04 3月, 2017 2 次提交
  3. 01 3月, 2017 1 次提交
  4. 19 2月, 2017 5 次提交
    • J
      nodedev: Rework virNodeDeviceGetParentHost · 7ad479d0
      John Ferlan 提交于
      Rework the code to perform the various searches by parent, parent_wwnn/
      parent_wwpn, parent_fabric_wwn, or vport capable in order to return the
      'parent_host' number that is vHBA capable.
      
      The former virNodeDeviceGetParentHost is renamed to add the ByParent
      on it fixes an issue where if no parent was supplied in the XML to
      create the vHBA, then virNodeDeviceFindByName was called with a NULL
      second parameter which had bad results.
      
      The reworked code will make the various calls to fetch the NPIV host
      by the passed parameter options or if none are provided find a vport
      capable NPIV HBA to perform the create. If the call is from the delete
      path, then this option won't be allowed.
      
      Each of virNodeDeviceGetParentHostBy* functions is now static, so
      remove them external definitions.
      
      A secondary benefit of this is the test_driver now can make use of
      the new API to add some new tests to test the various creation options.
      7ad479d0
    • J
      tests: Create a more realistic vHBA · 8729ce56
      John Ferlan 提交于
      Modify the code to react more like a real HBA -> vHBA creation.
      
      Currently the code would just modify the input XML definition to
      set the name to a wwpn and then modify the scsi_host capability
      entry for the defintion to change the scsi_host# and unique_id
      before adding that into the node device.
      
      This patch does things a bit better. It finds and copies a known
      existing vHBA (scsi_host11) in the node_device database and modifies
      that definition to change the name to scsi_host12 and set the wwnn/
      wwpn to what the input XML would expect before adding the def to the
      node device object list.
      
      Then rather than create a returned "dev" using the (poorly) mocked
      name - perform the lookup using the new device name.
      8729ce56
    • J
      test: Add helper to create vHBA for testNodeDeviceCreateXML · 0869d9b3
      John Ferlan 提交于
      Rather than inline the dummy creation of a vHBA to add to the node
      devices - create a helper to do that work.
      
      Also just tidy up a couple of things while at it...
      0869d9b3
    • J
      test: Add new NPIV capable HBA and a vHBA · 5c2ff641
      John Ferlan 提交于
      Predefine a second NPIV capable HBA as well as a vHBA using the first
      NPIV capable HBA. This will allow for a mechanism to perform more
      realistic create vHBA testing.
      5c2ff641
    • J
      tests: Alter test_driver HBA name/data to be closer to reality · 779e4905
      John Ferlan 提交于
      Alter "test-scsi-host-vport" to be "scsi_host1" to match the real
      environment. This is the vport capable HBA - IOW the NPIV device.
      Add more fields to scsi_host1 as well.
      
      Alter the XML being used by the objecttest to create a vHBA in order
      to match the scsi_host1 parent name and to use validateable wwnn/wwpn.
      This will allow for realistic testing.
      779e4905
  5. 17 2月, 2017 1 次提交
    • J
      nodedev: Return the parent for a virNodeDevicePtr struct · 4337bc57
      John Ferlan 提交于
      When the 'parent' was added to the virNodeDevicePtr structure
      by commit id 'e8a4ea75' the 'parent' field was not properly filled
      in when a virGetNodeDevice call was made within driver/config code.
      Only the device name was ever filled in. Fetching the parent required
      a second trip via virNodeDeviceGetParent into the node device lookup
      code was required in order to retrieve the specific parent field (and
      still the parent field was never filled in although it was free'd).
      
      Since we have the data when we initially call virGetNodeDevice from
      within driver/node_config code - let's just fill in the parent field
      as well for anyone that wants it without requiring another trip into
      the node_device lookup just to get the parent.
      
      This will allow API's such as virConnectListAllNodeDevices,
      virNodeDeviceLookupByName, and virNodeDeviceLookupSCSIHostByWWN
      to retrieve both name and parent in the returned virNodeDevicePtr.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      4337bc57
  6. 09 1月, 2017 1 次提交
  7. 08 12月, 2016 1 次提交
    • D
      test: fix screenshot API impl · 0be9cea1
      Daniel P. Berrange 提交于
      When redoing the website we deleted the libvirtLogo.png file
      not remembering that the test driver screenshot API impl
      relied on it.
      
      Rather than having the test driver use the logo as a side
      effect, give it its own dedicated image to use. This is
      installed in /usr/share/libvirt/test-screenshot.png and
      is taken from a NeXT Cube running WorldWideWeb[1]. The
      very first web browser in existance, running on the
      hardware it was originally written on.
      
      [1] https://en.wikipedia.org/wiki/WorldWideWebSigned-off-by: NDaniel P. Berrange <berrange@redhat.com>
      0be9cea1
  8. 02 12月, 2016 1 次提交
  9. 22 11月, 2016 1 次提交
  10. 15 11月, 2016 1 次提交
  11. 08 11月, 2016 2 次提交
  12. 13 10月, 2016 2 次提交
  13. 12 10月, 2016 1 次提交
  14. 26 9月, 2016 3 次提交
  15. 22 9月, 2016 1 次提交
  16. 15 9月, 2016 7 次提交
  17. 09 9月, 2016 1 次提交
  18. 29 8月, 2016 1 次提交
    • R
      tests: fix segfault in objecteventtest · 61148074
      Roman Bogorodskiy 提交于
      Test 12 from objecteventtest (createXML add event) segaults on FreeBSD
      with bus error.
      
      At some point it calls testNodeDeviceDestroy() from the test driver. And
      it fails when it tries to unlock the device in the "out:" label of this
      function.
      
      Unlocking fails because the previous step was a call to
      virNodeDeviceObjRemove from conf/node_device_conf.c. This function
      removes the given device from the device list and cleans up the object,
      including destroying of its mutex. However, it does not nullify the pointer
      that was given to it.
      
      As a result, we end up in testNodeDeviceDestroy() here:
      
       out:
          if (obj)
              virNodeDeviceObjUnlock(obj);
      
      And instead of skipping this, we try to do Unlock and fail because of
      malformed mutex.
      
      Change virNodeDeviceObjRemove to use double pointer and set pointer to
      NULL.
      61148074
  19. 02 8月, 2016 1 次提交
  20. 18 7月, 2016 4 次提交
  21. 11 7月, 2016 2 次提交