mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-11 23:37:42 +00:00
nodedev: fix vport detection for FC HBA
Use the host number as the host number when constructing the sysfs path instead of the variable we are trying to fill. https://bugzilla.redhat.com/show_bug.cgi?id=973543 (cherry picked from commit 371c15517c919e9d7d2ea3f66e490bd49b6db384)
This commit is contained in:
parent
945dc62f21
commit
5cd988cb1a
@ -80,7 +80,7 @@ detect_scsi_host_caps(union _virNodeDevCapData *d)
|
|||||||
d->scsi_host.flags |= VIR_NODE_DEV_CAP_FLAG_HBA_VPORT_OPS;
|
d->scsi_host.flags |= VIR_NODE_DEV_CAP_FLAG_HBA_VPORT_OPS;
|
||||||
|
|
||||||
if (virReadFCHost(NULL,
|
if (virReadFCHost(NULL,
|
||||||
d->scsi_host.max_vports,
|
d->scsi_host.host,
|
||||||
"max_npiv_vports",
|
"max_npiv_vports",
|
||||||
&max_vports) < 0) {
|
&max_vports) < 0) {
|
||||||
VIR_ERROR(_("Failed to read max_npiv_vports for host%d"),
|
VIR_ERROR(_("Failed to read max_npiv_vports for host%d"),
|
||||||
@ -89,7 +89,7 @@ detect_scsi_host_caps(union _virNodeDevCapData *d)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (virReadFCHost(NULL,
|
if (virReadFCHost(NULL,
|
||||||
d->scsi_host.max_vports,
|
d->scsi_host.host,
|
||||||
"npiv_vports_inuse",
|
"npiv_vports_inuse",
|
||||||
&vports) < 0) {
|
&vports) < 0) {
|
||||||
VIR_ERROR(_("Failed to read npiv_vports_inuse for host%d"),
|
VIR_ERROR(_("Failed to read npiv_vports_inuse for host%d"),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user