lsblk: read SCSI_IDENT_SERIAL also from udev
Addresses: https://github.com/karelzak/util-linux/issues/1143 Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
parent
72ab706502
commit
1492fb4ef2
|
@ -104,6 +104,8 @@ static struct lsblk_devprop *get_properties_by_udev(struct lsblk_device *ld)
|
||||||
if (data)
|
if (data)
|
||||||
prop->wwn = xstrdup(data);
|
prop->wwn = xstrdup(data);
|
||||||
|
|
||||||
|
data = udev_device_get_property_value(dev, "SCSI_IDENT_SERIAL"); /* sg3_utils do not use I_D prefix */
|
||||||
|
if (!data)
|
||||||
data = udev_device_get_property_value(dev, "ID_SCSI_SERIAL");
|
data = udev_device_get_property_value(dev, "ID_SCSI_SERIAL");
|
||||||
if(!data)
|
if(!data)
|
||||||
data = udev_device_get_property_value(dev, "ID_SERIAL_SHORT");
|
data = udev_device_get_property_value(dev, "ID_SERIAL_SHORT");
|
||||||
|
|
Loading…
Reference in New Issue