提交 9c10c030 编写于 作者: N Nikolay Shirokovskiy 提交者: Maxim Nestratov

vz: don't show bootorder for containers

Because this is invalid xml for containers. This patch almost
reverts 7eda8369, but still skips converting vz sdk bootorder
for containers to libvirt bootorder because we use boot order
in containers for quite different purpurse.
上级 de325472
......@@ -1695,21 +1695,6 @@ prlsdkBootOrderCheck(PRL_HANDLE sdkdom, PRL_DEVICE_TYPE sdkType, int sdkIndex,
return ret;
}
static void
prlsdkConvertBootOrderCt(virDomainDefPtr def)
{
size_t i;
for (i = 0; i < def->nfss; i++) {
if (STREQ(def->fss[i]->dst, "/")) {
def->os.nBootDevs = 0;
return;
}
}
def->os.nBootDevs = 1;
def->os.bootDevs[0] = VIR_DOMAIN_BOOT_DISK;
}
static int
prlsdkConvertBootOrderVm(PRL_HANDLE sdkdom, virDomainDefPtr def)
{
......@@ -1870,12 +1855,8 @@ prlsdkLoadDomain(vzDriverPtr driver,
goto error;
/* depends on prlsdkAddDomainHardware */
if (IS_CT(def)) {
prlsdkConvertBootOrderCt(def);
} else {
if (prlsdkConvertBootOrderVm(sdkdom, def) < 0)
goto error;
}
if (!IS_CT(def) && prlsdkConvertBootOrderVm(sdkdom, def) < 0)
goto error;
pret = PrlVmCfg_GetEnvId(sdkdom, &envId);
prlsdkCheckRetGoto(pret, error);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册