From 68313a1c68f787478bbdc5afaa3f24da1ac23f71 Mon Sep 17 00:00:00 2001 From: Jarod Wilson Date: Aug 24 2009 21:33:36 +0000 Subject: - Add support for newer sockets, processors and pcie slot types --- diff --git a/dmidecode-add-hewlett-packard-to-dmioem.patch b/dmidecode-add-hewlett-packard-to-dmioem.patch new file mode 100644 index 0000000..e1dab91 --- /dev/null +++ b/dmidecode-add-hewlett-packard-to-dmioem.patch @@ -0,0 +1,11 @@ +--- dmidecode/dmioem.c~ 2008/10/28 09:41:07 1.9 ++++ dmidecode/dmioem.c 2009/07/27 12:07:39 1.10 +@@ -41,7 +41,7 @@ + */ + void dmi_set_vendor(const char *s) + { +- if (strcmp(s, "HP") == 0) ++ if (strcmp(s, "HP") == 0 || strcmp(s, "Hewlett-Packard") == 0) + dmi_vendor = VENDOR_HP; + } + diff --git a/dmidecode-add-socket-lga1366.patch b/dmidecode-add-socket-lga1366.patch new file mode 100644 index 0000000..ee86ddf --- /dev/null +++ b/dmidecode-add-socket-lga1366.patch @@ -0,0 +1,16 @@ +--- dmidecode/dmidecode.c~ 2009/06/19 11:55:35 1.142 ++++ dmidecode/dmidecode.c 2009/07/27 12:20:01 1.143 +@@ -1042,10 +1042,11 @@ + "Socket LGA775", + "Socket S1", + "Socket AM2", +- "Socket F (1207)" /* 0x18 */ ++ "Socket F (1207)", ++ "Socket LGA1366" /* 0x19 */ + }; + +- if (code >= 0x01 && code <= 0x18) ++ if (code >= 0x01 && code <= 0x19) + return upgrade[code - 0x01]; + return out_of_spec; + } diff --git a/dmidecode-pcie-v2-id.patch b/dmidecode-pcie-v2-id.patch new file mode 100644 index 0000000..a127ea1 --- /dev/null +++ b/dmidecode-pcie-v2-id.patch @@ -0,0 +1,23 @@ +--- dmidecode-2.10/dmidecode.c~ 2009-08-24 16:09:42.228443932 -0400 ++++ dmidecode-2.10/dmidecode.c 2009-08-24 16:23:50.480316768 -0400 +@@ -1541,12 +1541,18 @@ static const char *dmi_slot_type(u8 code + "PCI Express x2", + "PCI Express x4", + "PCI Express x8", +- "PCI Express x16" /* 0xAA */ ++ "PCI Express x16", /* 0xAA */ ++ "PCI Express Gen 2", ++ "PCI Express Gen 2 x1", ++ "PCI Express Gen 2 x2", ++ "PCI Express Gen 2 x4", ++ "PCI Express Gen 2 x8", ++ "PCI Express Gen 2 x16", /* 0xB0 */ + }; + + if (code >= 0x01 && code <= 0x13) + return type[code - 0x01]; +- if (code >= 0xA0 && code <= 0xAA) ++ if (code >= 0xA0 && code <= 0xB0) + return type_0xA0[code - 0xA0]; + return out_of_spec; + } diff --git a/dmidecode-recognize-more-memory.patch b/dmidecode-recognize-more-memory.patch new file mode 100644 index 0000000..19d18d7 --- /dev/null +++ b/dmidecode-recognize-more-memory.patch @@ -0,0 +1,11 @@ +--- dmidecode/dmidecode.c~ 2009/04/30 08:19:37 1.141 ++++ dmidecode/dmidecode.c 2009/06/19 11:55:35 1.142 +@@ -2007,7 +2007,7 @@ + + static void dmi_memory_array_capacity(u32 code) + { +- if (code == 0x8000000) ++ if (code == 0x80000000) + printf(" Unknown"); + else + { diff --git a/dmidecode-smbios-2.6.1-additions.patch b/dmidecode-smbios-2.6.1-additions.patch new file mode 100644 index 0000000..70050ab --- /dev/null +++ b/dmidecode-smbios-2.6.1-additions.patch @@ -0,0 +1,87 @@ +--- dmidecode-2.10/dmidecode.c~ 2009-08-24 17:09:16.724316584 -0400 ++++ dmidecode-2.10/dmidecode.c 2009-08-24 17:09:58.299317081 -0400 +@@ -361,7 +361,7 @@ static void dmi_system_uuid(const u8 *p, + + static const char *dmi_system_wake_up_type(u8 code) + { +- /* 3.3.2.1 */ ++ /* 3.3.2.2 */ + static const char *type[] = { + "Reserved", /* 0x00 */ + "Other", +@@ -719,6 +719,12 @@ static const char *dmi_processor_family( + { 0xA9, "Quad-Core Xeon 5400" }, /* From CIM_Processor.Family */ + { 0xAA, "Quad-Core Xeon" }, /* From CIM_Processor.Family */ + ++ { 0xAB, "Dual-Core Xeon 5200" }, ++ { 0xAC, "Dual-Core Xeon 7200" }, ++ { 0xAD, "Quad-Core Xeon 7300" }, ++ { 0xAE, "Quad-Core Xeon 7400" }, ++ { 0xAF, "Multi-Core Xeon 7400" }, ++ + { 0xB0, "Pentium III Xeon" }, + { 0xB1, "Pentium III Speedstep" }, + { 0xB2, "Pentium 4" }, +@@ -741,6 +747,8 @@ static const char *dmi_processor_family( + { 0xC3, "Core 2 Extreme Mobile" }, /* From CIM_Processor.Family */ + { 0xC4, "Core 2 Duo Mobile" }, /* From CIM_Processor.Family */ + { 0xC5, "Core 2 Solo Mobile" }, /* From CIM_Processor.Family */ ++ { 0xC6, "Core i7" }, ++ { 0xC7, "Dual-Core Celeron" }, + + { 0xC8, "IBM390" }, + { 0xC9, "G4" }, +@@ -753,6 +761,17 @@ static const char *dmi_processor_family( + { 0xD4, "C7" }, + { 0xD5, "Eden" }, + ++ { 0xD6, "Multi-Core Xeon" }, ++ { 0xD7, "Dual-Core Xeon 3xxx" }, ++ { 0xD8, "Quad-Core Xeon 3xxx" }, ++ ++ { 0xDA, "Dual-Core Xeon 5xxx" }, ++ { 0xDB, "Quad-Core Xeon 5xxx" }, ++ ++ { 0xDD, "Dual-Core Xeon 7xxx" }, ++ { 0xDD, "Quad-Core Xeon 7xxx" }, ++ { 0xDD, "Multi-Core Xeon 7xxx" }, ++ + { 0xE6, "Embedded Opteron Quad-Core" }, /* From CIM_Processor.Family */ + { 0xE7, "Phenom Triple-Core" }, /* From CIM_Processor.Family */ + { 0xE8, "Turion Ultra Dual-Core Mobile" }, /* From CIM_Processor.Family */ +@@ -1383,10 +1402,15 @@ static const char *dmi_cache_associativi + "4-way Set-associative", + "Fully Associative", + "8-way Set-associative", +- "16-way Set-associative" /* 0x08 */ ++ "16-way Set-associative" ++ "12-way Set-associative" ++ "24-way Set-associative" ++ "32-way Set-associative" ++ "48-way Set-associative" ++ "64-way Set-associative" /* 0x0D */ + }; + +- if (code >= 0x01 && code <= 0x08) ++ if (code >= 0x01 && code <= 0x0D) + return type[code - 0x01]; + return out_of_spec; + } +@@ -2126,10 +2150,15 @@ static const char *dmi_memory_device_typ + "RDRAM", + "DDR", + "DDR2", +- "DDR2 FB-DIMM" /* 0x14 */ ++ "DDR2 FB-DIMM", ++ "Reserved", ++ "Reserved", ++ "Reserved", ++ "DDR3", ++ "FBD2", /* 0x19 */ + }; + +- if (code >= 0x01 && code <= 0x14) ++ if (code >= 0x01 && code <= 0x19) + return type[code - 0x01]; + return out_of_spec; + } diff --git a/dmidecode-warn-on-unsupported-smbios-version.patch b/dmidecode-warn-on-unsupported-smbios-version.patch new file mode 100644 index 0000000..896c29f --- /dev/null +++ b/dmidecode-warn-on-unsupported-smbios-version.patch @@ -0,0 +1,25 @@ +--- dmidecode/dmidecode.c~ 2008/11/14 10:27:31 1.140 ++++ dmidecode/dmidecode.c 2009/04/30 08:19:37 1.141 +@@ -66,6 +66,8 @@ + #define out_of_spec "" + static const char *bad_index = ""; + ++#define SUPPORTED_SMBIOS_VER 0x0206 ++ + /* + * Type-independant Stuff + */ +@@ -4005,6 +4007,13 @@ + u8 *data; + int i = 0; + ++ if (ver > SUPPORTED_SMBIOS_VER) ++ { ++ printf("# SMBIOS implementations newer than version %u.%u are not\n" ++ "# fully supported by this version of dmidecode.\n", ++ SUPPORTED_SMBIOS_VER >> 8, SUPPORTED_SMBIOS_VER & 0xFF); ++ } ++ + if (opt.flags & FLAG_DUMP_BIN) + { + dmi_table_dump(base, len, devmem); diff --git a/dmidecode.spec b/dmidecode.spec index e20d8c0..8248fe2 100644 --- a/dmidecode.spec +++ b/dmidecode.spec @@ -1,11 +1,17 @@ Summary: Tool to analyse BIOS DMI data Name: dmidecode Version: 2.10 -Release: %(R="$Revision: 1.36 $"; RR="${R##: }"; echo ${RR%%?})%{?dist}.2 +Release: %(R="$Revision: 1.37 $"; RR="${R##: }"; echo ${RR%%?})%{?dist} Epoch: 1 Group: System Environment/Base License: GPLv2+ Source0: dmidecode-%{version}.tar.bz2 +Patch0: dmidecode-add-hewlett-packard-to-dmioem.patch +Patch1: dmidecode-recognize-more-memory.patch +Patch2: dmidecode-add-socket-lga1366.patch +Patch3: dmidecode-warn-on-unsupported-smbios-version.patch +Patch4: dmidecode-pcie-v2-id.patch +Patch5: dmidecode-smbios-2.6.1-additions.patch URL: http://www.nongnu.org/dmidecode/ Buildroot: %{_tmppath}/%{name}-%{version}-root BuildPreReq: /usr/bin/aclocal /usr/bin/automake /usr/bin/autoconf @@ -25,6 +31,12 @@ I/O ports (e.g. serial, parallel, USB). %prep %setup -q +%patch0 -p1 +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 %build make CFLAGS="$RPM_OPT_FLAGS" @@ -48,6 +60,9 @@ rm -rf $RPM_BUILD_ROOT %{_mandir}/man8/* %changelog +* Mon Aug 24 2009 Jarod Wilson - 1:2.10-1.38 +- Add support for newer sockets, processors and pcie slot types + * Fri Jul 24 2009 Fedora Release Engineering - 1:2.10-1.36.2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild