commit 57ca7abd48f9fc499bbf56864e8eeebdac58f3b8
Author: Arkadiusz Miśkiewicz <[email protected]>
Date:   Fri Nov 7 10:52:48 2014 +0100

    - rel 2; new cpu/memory support

 dmidecode-2.12-smbios_fix.patch | 86 +++++++++++++++++++++++++++++++++++++++++
 dmidecode.spec                  |  4 +-
 2 files changed, 89 insertions(+), 1 deletion(-)
---
diff --git a/dmidecode.spec b/dmidecode.spec
index e95ca8f..5aec597 100644
--- a/dmidecode.spec
+++ b/dmidecode.spec
@@ -2,11 +2,12 @@ Summary:      A tool for dumping a computer's DMI table 
contents
 Summary(pl.UTF-8):     Narzędzie do zrzucania zawartości tabeli DMI komputera
 Name:          dmidecode
 Version:       2.12
-Release:       1
+Release:       2
 License:       GPL v2+
 Group:         Applications/System
 Source0:       
http://savannah.nongnu.org/download/dmidecode/%{name}-%{version}.tar.bz2
 # Source0-md5: a406f3cbb27736491698697beeddb781
+Patch0:                dmidecode-2.12-smbios_fix.patch
 URL:           http://www.nongnu.org/dmidecode/
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -25,6 +26,7 @@ BIOS-u.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %{__make} \
diff --git a/dmidecode-2.12-smbios_fix.patch b/dmidecode-2.12-smbios_fix.patch
new file mode 100644
index 0000000..f39205d
--- /dev/null
+++ b/dmidecode-2.12-smbios_fix.patch
@@ -0,0 +1,86 @@
+diff -up dmidecode-2.12/CHANGELOG.smbios_fix dmidecode-2.12/CHANGELOG
+--- dmidecode-2.12/CHANGELOG.smbios_fix        2013-05-09 09:44:35.668592078 
+0200
++++ dmidecode-2.12/CHANGELOG   2013-05-09 09:44:44.742610559 +0200
+@@ -1,3 +1,10 @@
++2013-04-24  Jean Delvare  <[email protected]>
++
++      * dmidecode.c: Strip trailig zeroes from memory voltage values
++        (DMI type 17).
++      * dmidecode.c: Fix support for new processor upgrade types (DMI
++        type 4) and new memory device type (DMI type 17.)
++
+ 2013-04-17  Anton Arapov  <[email protected]>
+ 
+       Update to support SMBIOS specification version 2.8.0.
+diff -up dmidecode-2.12/dmidecode.c.smbios_fix dmidecode-2.12/dmidecode.c
+--- dmidecode-2.12/dmidecode.c.smbios_fix      2013-05-09 09:44:26.404573273 
+0200
++++ dmidecode-2.12/dmidecode.c 2013-05-09 09:44:44.745610565 +0200
+@@ -69,7 +69,7 @@
+ #define out_of_spec "<OUT OF SPEC>"
+ static const char *bad_index = "<BAD INDEX>";
+ 
+-#define SUPPORTED_SMBIOS_VER 0x0207
++#define SUPPORTED_SMBIOS_VER 0x0208
+ 
+ /*
+  * Type-independant Stuff
+@@ -712,7 +712,6 @@ static const char *dmi_processor_family(
+               { 0x3D, "Opteron 6200" },
+               { 0x3E, "Opteron 4200" },
+               { 0x3F, "FX" },
+-
+               { 0x40, "MIPS" },
+               { 0x41, "MIPS R4000" },
+               { 0x42, "MIPS R4200" },
+@@ -729,7 +728,6 @@ static const char *dmi_processor_family(
+               { 0x4D, "Opteron 6300" },
+               { 0x4E, "Opteron 3300" },
+               { 0x4F, "FirePro" },
+-
+               { 0x50, "SPARC" },
+               { 0x51, "SuperSPARC" },
+               { 0x52, "MicroSPARC II" },
+@@ -1176,7 +1174,7 @@ static const char *dmi_processor_upgrade
+               "Socket LGA1356-3" /* 0x2C */
+       };
+ 
+-      if (code >= 0x01 && code <= 0x2A)
++      if (code >= 0x01 && code <= 0x2C)
+               return upgrade[code - 0x01];
+       return out_of_spec;
+ }
+@@ -2236,7 +2234,7 @@ static void dmi_memory_voltage_value(u16
+       if (code == 0)
+               printf(" Unknown");
+       else
+-              printf(" %.3f V", (float)(i16)code / 1000);
++              printf(code % 100 ? " %g V" : " %.1f V", (float)code / 1000);
+ }
+ 
+ static const char *dmi_memory_device_form_factor(u8 code)
+@@ -2338,7 +2336,7 @@ static void dmi_memory_device_type_detai
+       {
+               int i;
+ 
+-              for (i = 1; i <= 14; i++)
++              for (i = 1; i <= 15; i++)
+                       if (code & (1 << i))
+                               printf(" %s", detail[i - 1]);
+       }
+@@ -3657,13 +3655,13 @@ static void dmi_decode(const struct dmi_
+                       dmi_memory_device_speed(WORD(data + 0x20));
+                       printf("\n");
+                       if (h->length < 0x28) break;
+-                      printf("\tMinimum voltage: ");
++                      printf("\tMinimum Voltage: ");
+                       dmi_memory_voltage_value(WORD(data + 0x22));
+                       printf("\n");
+-                      printf("\tMaximum voltage: ");
++                      printf("\tMaximum Voltage: ");
+                       dmi_memory_voltage_value(WORD(data + 0x24));
+                       printf("\n");
+-                      printf("\tConfigured voltage: ");
++                      printf("\tConfigured Voltage: ");
+                       dmi_memory_voltage_value(WORD(data + 0x26));
+                       printf("\n");
+                       break;
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/dmidecode.git/commitdiff/57ca7abd48f9fc499bbf56864e8eeebdac58f3b8

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to