mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-20 06:50:22 +03:00
qemu: Report disk bus as reported by agent in virDomainGetGuestInfo
KubeVirt decided to report this to the users. In order to allow them to use proper APIs expose the field as well. Resolves: https://issues.redhat.com/browse/RHEL-80688 Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
71e75ce092
commit
89a57e7fe0
@ -2999,6 +2999,7 @@ returned:
|
||||
* ``disk.<num>.serial`` - optional disk serial number
|
||||
* ``disk.<num>.alias`` - the device alias of the disk (e.g. sda)
|
||||
* ``disk.<num>.guest_alias`` - optional alias assigned to the disk
|
||||
* ``disk.<num>.guest_bus`` - bus type as reported by the guest
|
||||
|
||||
*--interface* returns:
|
||||
* ``if.count`` - the number of interfaces defined on this domain
|
||||
|
@ -13273,6 +13273,7 @@ virDomainSetVcpu(virDomainPtr domain,
|
||||
* "disk.<num>.alias" - the device alias of the disk (e.g. sda)
|
||||
* "disk.<num>.guest_alias" - optional alias assigned to the disk, on Linux
|
||||
* this is a name assigned by device mapper
|
||||
* "disk.<num>.guest_bus" - disk bus as reported by the guest OS
|
||||
*
|
||||
* VIR_DOMAIN_GUEST_INFO_HOSTNAME:
|
||||
* Returns information about the hostname of the domain. The typed
|
||||
|
@ -19278,6 +19278,15 @@ qemuAgentDiskInfoFormatParams(qemuAgentDiskInfo **info,
|
||||
param_name, diskdef->dst) < 0)
|
||||
return;
|
||||
}
|
||||
|
||||
if (address->bus_type) {
|
||||
g_snprintf(param_name, VIR_TYPED_PARAM_FIELD_LENGTH,
|
||||
"disk.%zu.guest_bus", i);
|
||||
|
||||
if (virTypedParamsAddString(params, nparams, maxparams,
|
||||
param_name, address->bus_type) < 0)
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (info[i]->alias) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user