File dmidecode-add-slot-characteristics2-from-smbios-3.4.0.patch of Package dmidecode.17692

From: Prabhakar pujeri <prabhakar.pujeri@gmail.com>
Date: Mon, 19 Oct 2020 15:04:30 +0200
Subject: Add new slot characteristics2 from SMBIOS spec 3.4.0
Git-commit: 4304d3aca801534ae0e4ebab5e4b4cef0c866315
Patch-mainline: yes
References: bsc#1174257

* The bit to indicate PCIe surprise removal support.
* The bit to indicate Flexbus CXL 1.0 version.
* The bit to indicate Flexbus CXL 2.0 version.
---
 dmidecode.c |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

--- a/dmidecode.c
+++ b/dmidecode.c
@@ -2000,7 +2000,10 @@ static void dmi_slot_characteristics(u8
 		"PME signal is supported", /* 0 */
 		"Hot-plug devices are supported",
 		"SMBus signal is supported",
-		"PCIe slot bifurcation is supported" /* 3 */
+		"PCIe slot bifurcation is supported",
+		"Async/surprise removal is supported",
+		"Flexbus slot, CXL 1.0 capable",
+		"Flexbus slot, CXL 2.0 capable" /* 6 */
 	};
 
 	if (code1 & (1 << 0))
@@ -2015,7 +2018,7 @@ static void dmi_slot_characteristics(u8
 		for (i = 1; i <= 7; i++)
 			if (code1 & (1 << i))
 				printf("%s%s\n", prefix, characteristics1[i - 1]);
-		for (i = 0; i <= 3; i++)
+		for (i = 0; i <= 6; i++)
 			if (code2 & (1 << i))
 				printf("%s%s\n", prefix, characteristics2[i]);
 	}
openSUSE Build Service is sponsored by