|
|
99c025 |
From 028f6b229a138211d17bb32b8668dc73e6724464 Mon Sep 17 00:00:00 2001
|
|
|
99c025 |
From: Lyonel Vincent <lyonel@ezix.org>
|
|
|
99c025 |
Date: Thu, 14 Jun 2018 19:17:26 +0200
|
|
|
99c025 |
Subject: [PATCH 1/8] merge Github PR #40 and #41
|
|
|
99c025 |
|
|
|
99c025 |
Properly handle scsi device type 0x14 (== 20) to add ZBC and ZAC host
|
|
|
99c025 |
managed zoned block devices to the "disk" class. While at it, also add
|
|
|
99c025 |
in scsi_type() the missing type name string for the device
|
|
|
99c025 |
type 0xe (== 14).
|
|
|
99c025 |
|
|
|
99c025 |
---
|
|
|
99c025 |
lshw.spec.in | 2 +-
|
|
|
99c025 |
src/core/scsi.cc | 8 +++++++-
|
|
|
99c025 |
2 files changed, 8 insertions(+), 2 deletions(-)
|
|
|
99c025 |
|
|
|
99c025 |
diff --git a/lshw.spec.in b/lshw.spec.in
|
|
|
99c025 |
index c597379c3bc8..f7f88b323ce9 100644
|
|
|
99c025 |
--- a/lshw.spec.in
|
|
|
99c025 |
+++ b/lshw.spec.in
|
|
|
99c025 |
@@ -12,7 +12,7 @@ Group: Applications/System
|
|
|
99c025 |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
99c025 |
|
|
|
99c025 |
%description
|
|
|
99c025 |
-lshw (Hardware Lister) is a small tool to provide detailed informaton on
|
|
|
99c025 |
+lshw (Hardware Lister) is a small tool to provide detailed information on
|
|
|
99c025 |
the hardware configuration of the machine. It can report exact memory
|
|
|
99c025 |
configuration, firmware version, mainboard configuration, CPU version
|
|
|
99c025 |
and speed, cache configuration, bus speed, etc. on DMI-capable x86s
|
|
|
99c025 |
diff --git a/src/core/scsi.cc b/src/core/scsi.cc
|
|
|
99c025 |
index 75061c0fb195..4992c889dd12 100644
|
|
|
99c025 |
--- a/src/core/scsi.cc
|
|
|
99c025 |
+++ b/src/core/scsi.cc
|
|
|
99c025 |
@@ -260,6 +260,10 @@ static const char *scsi_type(int type)
|
|
|
99c025 |
return "Medium Changer";
|
|
|
99c025 |
case 0xd:
|
|
|
99c025 |
return "Enclosure";
|
|
|
99c025 |
+ case 0xe:
|
|
|
99c025 |
+ return "Simplified direct-access device";
|
|
|
99c025 |
+ case 0x14:
|
|
|
99c025 |
+ return "Host managed zoned block device";
|
|
|
99c025 |
default:
|
|
|
99c025 |
return "";
|
|
|
99c025 |
}
|
|
|
99c025 |
@@ -706,6 +710,7 @@ static void scan_sg(hwNode & n)
|
|
|
99c025 |
{
|
|
|
99c025 |
case 0:
|
|
|
99c025 |
case 14:
|
|
|
99c025 |
+ case 20:
|
|
|
99c025 |
device = hwNode("disk", hw::disk);
|
|
|
99c025 |
break;
|
|
|
99c025 |
case 1:
|
|
|
99c025 |
@@ -752,7 +757,8 @@ static void scan_sg(hwNode & n)
|
|
|
99c025 |
}
|
|
|
99c025 |
if ((m_id.scsi_type == 4) || (m_id.scsi_type == 5))
|
|
|
99c025 |
scan_cdrom(device);
|
|
|
99c025 |
- if ((m_id.scsi_type == 0) || (m_id.scsi_type == 7) || (m_id.scsi_type == 14))
|
|
|
99c025 |
+ if ((m_id.scsi_type == 0) || (m_id.scsi_type == 7) ||
|
|
|
99c025 |
+ (m_id.scsi_type == 14) || (m_id.scsi_type == 20))
|
|
|
99c025 |
scan_disk(device);
|
|
|
99c025 |
|
|
|
99c025 |
if (!adapter_businfo.empty())
|
|
|
99c025 |
--
|
|
|
99c025 |
2.17.1
|
|
|
99c025 |
|