mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-23 13:05:27 +00:00
vz: Adapt to driver rename
In the e6d180f07fb06 commit the parallels driver was renamed to vz. However, there was a commit merged later, which was sent to the list before the rename. The other commit is 6de12b026b73. Fix all the missing renames. Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
cb005533ab
commit
84d0286ef0
@ -2885,14 +2885,20 @@ static int prlsdkAddNet(PRL_HANDLE sdkdom,
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void prlsdkDelNet(vzConnPtr privconn, virDomainNetDefPtr net)
|
||||
static int
|
||||
prlsdkDelNet(vzConnPtr privconn, virDomainNetDefPtr net)
|
||||
{
|
||||
int ret = -1;
|
||||
PRL_RESULT pret;
|
||||
PRL_HANDLE vnet = PRL_INVALID_HANDLE;
|
||||
PRL_HANDLE job = PRL_INVALID_HANDLE;
|
||||
|
||||
if (net->type != VIR_DOMAIN_NET_TYPE_BRIDGE)
|
||||
return;
|
||||
if (net->type != VIR_DOMAIN_NET_TYPE_BRIDGE) {
|
||||
virReportError(VIR_ERR_OPERATION_UNSUPPORTED,
|
||||
_("unplugging network device of type %s is not supported"),
|
||||
virDomainNetTypeToString(net->type));
|
||||
return ret;
|
||||
}
|
||||
|
||||
pret = PrlVirtNet_Create(&vnet);
|
||||
prlsdkCheckRetGoto(pret, cleanup);
|
||||
@ -2904,16 +2910,19 @@ static void prlsdkDelNet(vzConnPtr privconn, virDomainNetDefPtr net)
|
||||
if (PRL_FAILED(pret = waitJob(job)))
|
||||
goto cleanup;
|
||||
|
||||
ret = 0;
|
||||
|
||||
cleanup:
|
||||
PrlHandle_Free(vnet);
|
||||
return ret;
|
||||
}
|
||||
|
||||
int prlsdkAttachNet(virDomainObjPtr dom,
|
||||
parallelsConnPtr privconn,
|
||||
vzConnPtr privconn,
|
||||
virDomainNetDefPtr net)
|
||||
{
|
||||
int ret = -1;
|
||||
parallelsDomObjPtr privdom = dom->privateData;
|
||||
vzDomObjPtr privdom = dom->privateData;
|
||||
PRL_HANDLE job = PRL_INVALID_HANDLE;
|
||||
|
||||
if (!IS_CT(dom->def)) {
|
||||
@ -2998,11 +3007,11 @@ static int prlsdkDelNetAdapter(PRL_HANDLE sdkdom, int idx)
|
||||
}
|
||||
|
||||
int prlsdkDetachNet(virDomainObjPtr dom,
|
||||
parallelsConnPtr privconn,
|
||||
vzConnPtr privconn,
|
||||
virDomainNetDefPtr net)
|
||||
{
|
||||
int ret = -1, idx = -1;
|
||||
parallelsDomObjPtr privdom = dom->privateData;
|
||||
vzDomObjPtr privdom = dom->privateData;
|
||||
PRL_HANDLE job = PRL_INVALID_HANDLE;
|
||||
|
||||
if (!IS_CT(dom->def)) {
|
||||
|
@ -67,6 +67,6 @@ prlsdkDetachVolume(virDomainObjPtr dom, virDomainDiskDefPtr disk);
|
||||
int
|
||||
prlsdkGetBlockStats(virDomainObjPtr dom, virDomainDiskDefPtr disk, virDomainBlockStatsPtr stats);
|
||||
int
|
||||
prlsdkAttachNet(virDomainObjPtr dom, parallelsConnPtr privconn, virDomainNetDefPtr net);
|
||||
prlsdkAttachNet(virDomainObjPtr dom, vzConnPtr privconn, virDomainNetDefPtr net);
|
||||
int
|
||||
prlsdkDetachNet(virDomainObjPtr dom, parallelsConnPtr privconn, virDomainNetDefPtr net);
|
||||
prlsdkDetachNet(virDomainObjPtr dom, vzConnPtr privconn, virDomainNetDefPtr net);
|
||||
|
Loading…
x
Reference in New Issue
Block a user