virPCIDeviceGetName;
virPCIDeviceGetRemoveSlot;
virPCIDeviceGetReprobe;
+virPCIDeviceGetStubDriverName;
virPCIDeviceGetStubDriverType;
virPCIDeviceGetUnbindFromStub;
virPCIDeviceGetUsedBy;
virPCIDeviceSetManaged;
virPCIDeviceSetRemoveSlot;
virPCIDeviceSetReprobe;
+virPCIDeviceSetStubDriverName;
virPCIDeviceSetStubDriverType;
virPCIDeviceSetUnbindFromStub;
virPCIDeviceSetUsedBy;
bool managed;
virPCIStubDriver stubDriverType;
+ char *stubDriverName; /* if blank, use default for type */
/* used by reattach function */
bool unbind_from_stub;
copy->path = g_strdup(dev->path);
copy->used_by_drvname = g_strdup(dev->used_by_drvname);
copy->used_by_domname = g_strdup(dev->used_by_domname);
+ copy->stubDriverName = g_strdup(dev->stubDriverName);
return copy;
}
g_free(dev->path);
g_free(dev->used_by_drvname);
g_free(dev->used_by_domname);
+ g_free(dev->stubDriverName);
g_free(dev);
}
return dev->stubDriverType;
}
+void
+virPCIDeviceSetStubDriverName(virPCIDevice *dev,
+ const char *driverName)
+{
+ g_free(dev->stubDriverName);
+ dev->stubDriverName = g_strdup(driverName);
+}
+
+const char *
+virPCIDeviceGetStubDriverName(virPCIDevice *dev)
+{
+ return dev->stubDriverName;
+}
+
bool
virPCIDeviceGetUnbindFromStub(virPCIDevice *dev)
{
void virPCIDeviceSetStubDriverType(virPCIDevice *dev,
virPCIStubDriver driverType);
virPCIStubDriver virPCIDeviceGetStubDriverType(virPCIDevice *dev);
+void virPCIDeviceSetStubDriverName(virPCIDevice *dev,
+ const char *driverName);
+const char *virPCIDeviceGetStubDriverName(virPCIDevice *dev);
virPCIDeviceAddress *virPCIDeviceGetAddress(virPCIDevice *dev);
int virPCIDeviceSetUsedBy(virPCIDevice *dev,
const char *drv_name,