提交 a7fea19f 编写于 作者: J John Ferlan

qemu: Introduce helper qemuDomainStorageUpdatePhysical

Currently just a shim to call virStorageSourceUpdateBlockPhysicalSize
Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
上级 732af77c
......@@ -11610,6 +11610,14 @@ qemuDomainStorageCloseStat(virStorageSourcePtr src,
}
static int
qemuDomainStorageUpdatePhysical(virStorageSourcePtr src,
bool report)
{
return virStorageSourceUpdateBlockPhysicalSize(src, report);
}
/**
* @driver: qemu driver data
* @cfg: driver configuration data
......@@ -11833,7 +11841,7 @@ qemuDomainGetBlockInfo(virDomainPtr dom,
if (entry->physical) {
info->physical = entry->physical;
} else {
if (virStorageSourceUpdateBlockPhysicalSize(disk->src, true) < 0)
if (qemuDomainStorageUpdatePhysical(disk->src, true) < 0)
goto endjob;
info->physical = disk->src->physical;
......@@ -19437,7 +19445,7 @@ qemuDomainGetStatsOneBlock(virQEMUDriverPtr driver,
QEMU_ADD_BLOCK_PARAM_ULL(record, maxparams, block_idx,
"physical", entry->physical);
} else {
if (virStorageSourceUpdateBlockPhysicalSize(src, false) == 0) {
if (qemuDomainStorageUpdatePhysical(src, false) == 0) {
QEMU_ADD_BLOCK_PARAM_ULL(record, maxparams, block_idx,
"physical", src->physical);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册