[PATCH] scsi: Fix construction of sysfs device path

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The device bus value was used instead of the device target when
building the sysfs device path. Trivial.

Signed-off-by: Viktor Mihajlovski <mihajlov@xxxxxxxxxxxxxxxxxx>
---
Should probably go into the 1.0.6 maintenance branch as well.

 src/util/virscsi.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/virscsi.c b/src/util/virscsi.c
index 4870307..726121b 100644
--- a/src/util/virscsi.c
+++ b/src/util/virscsi.c
@@ -218,7 +218,7 @@ virSCSIDeviceNew(const char *adapter,
         goto cleanup;
 
     if (virAsprintf(&dev->name, "%d:%d:%d:%d", dev->adapter,
-                    dev->bus, dev->bus, dev->unit) < 0 ||
+                    dev->bus, dev->target, dev->unit) < 0 ||
         virAsprintf(&dev->sg_path, "/dev/%s", sg) < 0) {
         virReportOOMError();
         goto cleanup;
-- 
1.7.9.5

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]