Hello community, here is the log from the commit of package hwinfo for openSUSE:Factory checked in at 2015-09-24 07:18:18 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/hwinfo (Old) and /work/SRC/openSUSE:Factory/.hwinfo.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "hwinfo" Changes: -------- --- /work/SRC/openSUSE:Factory/hwinfo/hwinfo.changes 2015-08-29 20:02:05.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.hwinfo.new/hwinfo.changes 2015-09-24 07:18:20.000000000 +0200 @@ -1,0 +2,6 @@ +Thu Sep 17 11:21:47 UTC 2015 - [email protected] + +- adjust disk device info gathering after nvme driver change (bsc#943008) +- 21.21 + +------------------------------------------------------------------- Old: ---- hwinfo-21.20.tar.xz New: ---- hwinfo-21.21.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ hwinfo.spec ++++++ --- /var/tmp/diff_new_pack.IjP5ZW/_old 2015-09-24 07:18:21.000000000 +0200 +++ /var/tmp/diff_new_pack.IjP5ZW/_new 2015-09-24 07:18:21.000000000 +0200 @@ -36,7 +36,7 @@ Group: Hardware/Other # Until migration to github this should be correct url Url: http://gitorious.org/opensuse/hwinfo -Version: 21.20 +Version: 21.21 Release: 0 Source: %{name}-%{version}.tar.xz BuildRoot: %{_tmppath}/%{name}-%{version}-build ++++++ hwinfo-21.20.tar.xz -> hwinfo-21.21.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hwinfo-21.20/VERSION new/hwinfo-21.21/VERSION --- old/hwinfo-21.20/VERSION 2015-08-27 14:10:17.000000000 +0200 +++ new/hwinfo-21.21/VERSION 2015-09-17 13:20:32.000000000 +0200 @@ -1 +1 @@ -21.20 +21.21 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hwinfo-21.20/changelog new/hwinfo-21.21/changelog --- old/hwinfo-21.20/changelog 2015-08-27 14:10:17.000000000 +0200 +++ new/hwinfo-21.21/changelog 2015-09-17 13:20:32.000000000 +0200 @@ -1,3 +1,6 @@ +2015-09-17: 21.21 + - adjust disk device info gathering after nvme driver change (bsc #943008) + 2015-08-27: 21.20 - added some comments - updated pci id data from http://pci-ids.ucw.cz diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hwinfo-21.20/src/hd/block.c new/hwinfo-21.21/src/hd/block.c --- old/hwinfo-21.20/src/hd/block.c 2015-08-27 14:10:17.000000000 +0200 +++ new/hwinfo-21.21/src/hd/block.c 2015-09-17 13:20:32.000000000 +0200 @@ -274,6 +274,7 @@ if(!strcmp(bus_name, "ide")) hd->bus.id = bus_ide; else if(!strcmp(bus_name, "scsi")) hd->bus.id = bus_scsi; else if(!strcmp(bus_name, "pci")) hd->bus.id = bus_pci; + else if(!strcmp(bus_name, "nvme")) hd->bus.id = bus_pci; } hd->sysfs_bus_id = new_str(bus_id); @@ -332,7 +333,25 @@ add_ide_sysfs_info(hd_data, hd); } else if(hd->bus.id == bus_scsi || hd->bus.id == bus_pci) { - add_scsi_sysfs_info(hd_data, hd, sf_dev); + /* + * In case there's no data in the 'device' subdir but in + * 'device/device', try one level deeper (for some capricious + * drivers). + */ + if( + !get_sysfs_attr_by_path(sf_dev, "vendor") && + get_sysfs_attr_by_path(sf_dev, "device/vendor") + ) { + char *x_dev = NULL; + + str_printf(&x_dev, 0, "%s/device", sf_dev); + add_scsi_sysfs_info(hd_data, hd, x_dev); + + free_mem(x_dev); + } + else { + add_scsi_sysfs_info(hd_data, hd, sf_dev); + } } else { add_other_sysfs_info(hd_data, hd);
