From 36e7b1a9a07df9f8aa14d0048333a601bb86240c Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Oct 30 2018 04:52:11 +0000 Subject: import lm_sensors-3.4.0-6.20160601gitf9185e5.el7 --- diff --git a/SOURCES/0001-Add-detection-of-AMD-Ryzen-w-Vega-graphics.patch b/SOURCES/0001-Add-detection-of-AMD-Ryzen-w-Vega-graphics.patch new file mode 100644 index 0000000..ae3d0e3 --- /dev/null +++ b/SOURCES/0001-Add-detection-of-AMD-Ryzen-w-Vega-graphics.patch @@ -0,0 +1,27 @@ +From c874e11639b6fd4002b155f7414f54f632465ec1 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ond=C5=99ej=20Lyson=C4=9Bk?= +Date: Thu, 3 May 2018 12:41:41 +0200 +Subject: [PATCH] Add detection of AMD Ryzen w/ Vega graphics + +Kernel support was added in commit +https://github.com/torvalds/linux/commit/877d8948d0aa402fb +--- + prog/detect/sensors-detect | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/prog/detect/sensors-detect b/prog/detect/sensors-detect +index 9b399e74..0d1cbb5d 100755 +--- a/prog/detect/sensors-detect ++++ b/prog/detect/sensors-detect +@@ -2773,7 +2773,7 @@ use vars qw(@cpu_ids); + }, { + name => "AMD Family 17h thermal sensors", + driver => "k10temp", +- detect => sub { amd_pci_detect('1463') }, ++ detect => sub { amd_pci_detect('1463', '15d0') }, + }, { + name => "AMD Family 15h power sensors", + driver => "fam15h_power", +-- +2.14.3 + diff --git a/SOURCES/0001-Detect-AMD-Family-17h-thermal-sensors.patch b/SOURCES/0001-Detect-AMD-Family-17h-thermal-sensors.patch new file mode 100644 index 0000000..aa1cf4a --- /dev/null +++ b/SOURCES/0001-Detect-AMD-Family-17h-thermal-sensors.patch @@ -0,0 +1,27 @@ +From f7d7997cf41bb0e1db0fb300073b434e0ea7dcc3 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ond=C5=99ej=20Lyson=C4=9Bk?= +Date: Fri, 20 Apr 2018 16:24:24 +0200 +Subject: [PATCH] Detect AMD Family 17h thermal sensors + +--- + prog/detect/sensors-detect | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/prog/detect/sensors-detect b/prog/detect/sensors-detect +index 6013aa3..f522b95 100755 +--- a/prog/detect/sensors-detect ++++ b/prog/detect/sensors-detect +@@ -2532,6 +2532,10 @@ use vars qw(@cpu_ids); + name => "AMD Family 16h thermal sensors", + driver => "k10temp", + detect => sub { amd_pci_detect('1533', '1583') }, ++ }, { ++ name => "AMD Family 17h thermal sensors", ++ driver => "k10temp", ++ detect => sub { amd_pci_detect('1463') }, + }, { + name => "AMD Family 15h power sensors", + driver => "fam15h_power", +-- +2.14.3 + diff --git a/SOURCES/0001-Fix-a-use-after-free.patch b/SOURCES/0001-Fix-a-use-after-free.patch new file mode 100644 index 0000000..aaf80b8 --- /dev/null +++ b/SOURCES/0001-Fix-a-use-after-free.patch @@ -0,0 +1,38 @@ +From 3b548b74aeaefb41ac9eca1f2e82ae693b469345 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ond=C5=99ej=20Lyson=C4=9Bk?= +Date: Thu, 3 May 2018 17:28:52 +0200 +Subject: [PATCH] Fix a use after free() +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +The issue was reported by Coverity Scan. + +Signed-off-by: Ondřej Lysoněk +--- + prog/sensors/chips.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/prog/sensors/chips.c b/prog/sensors/chips.c +index 668f508f..01c08fa8 100644 +--- a/prog/sensors/chips.c ++++ b/prog/sensors/chips.c +@@ -48,7 +48,6 @@ void print_chip_raw(const sensors_chip_name *name) + continue; + } + printf("%s:\n", label); +- free(label); + + b = 0; + while ((sub = sensors_get_all_subfeatures(name, feature, &b))) { +@@ -64,6 +63,7 @@ void print_chip_raw(const sensors_chip_name *name) + } else + printf("(%s)\n", label); + } ++ free(label); + } + } + +-- +2.14.3 + diff --git a/SOURCES/0001-Remove-superfluous-call-to-get_input_value.patch b/SOURCES/0001-Remove-superfluous-call-to-get_input_value.patch new file mode 100644 index 0000000..6c85330 --- /dev/null +++ b/SOURCES/0001-Remove-superfluous-call-to-get_input_value.patch @@ -0,0 +1,31 @@ +From 40aa494c026c67f089a4a84c600114473e9d7787 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ond=C5=99ej=20Lyson=C4=9Bk?= +Date: Mon, 7 May 2018 13:37:26 +0200 +Subject: [PATCH] Remove superfluous call to get_input_value() +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +It is already called in the line above. +Discovered thanks to a Coverity Scan warning. + +Signed-off-by: Ondřej Lysoněk +--- + prog/sensors/chips.c | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/prog/sensors/chips.c b/prog/sensors/chips.c +index 01c08fa8..99df8264 100644 +--- a/prog/sensors/chips.c ++++ b/prog/sensors/chips.c +@@ -364,7 +364,6 @@ static void print_chip_temp(const sensors_chip_name *name, + sf = sensors_get_subfeature(name, feature, + SENSORS_SUBFEATURE_TEMP_INPUT); + if (sf && get_input_value(name, sf, &val) == 0) { +- get_input_value(name, sf, &val); + if (fahrenheit) + val = deg_ctof(val); + printf("%+6.1f%s ", val, degstr); +-- +2.14.3 + diff --git a/SPECS/lm_sensors.spec b/SPECS/lm_sensors.spec index f1eeadf..9f62095 100644 --- a/SPECS/lm_sensors.spec +++ b/SPECS/lm_sensors.spec @@ -7,10 +7,10 @@ Name: lm_sensors Version: 3.4.0 -Release: 4.%{date}git%{shortcommit}%{?dist} +Release: 6.%{date}git%{shortcommit}%{?dist} Summary: Hardware monitoring tools Group: Applications/System -License: LGPLv2+ and GPLv3+ and GPLv2+ and Verbatim and Public domain +License: LGPLv2+ and GPLv3+ and GPLv2+ and Verbatim and Public Domain #URL: http://www.lm-sensors.org/ URL: http://github.com/groeck/lm-sensors/ @@ -27,6 +27,14 @@ Source4: lm_sensors-modprobe-r Patch0: lm_sensors-3.3.4-lm_sensors-service-modprobe-warnings.patch Patch1: lm_sensors-3.4.0-fix-systemd-paths.patch Patch2: lm_sensors-3.4.0-alternative-architectures-warning.patch +# Upstream patch: +Patch3: 0001-Detect-AMD-Family-17h-thermal-sensors.patch +# Upstream patch: +Patch4: 0001-Add-detection-of-AMD-Ryzen-w-Vega-graphics.patch +# Upstream patch: +Patch5: 0001-Fix-a-use-after-free.patch +# Upstream patch: +Patch6: 0001-Remove-superfluous-call-to-get_input_value.patch %ifarch %{ix86} x86_64 Requires: /usr/sbin/dmidecode @@ -75,6 +83,10 @@ database, and warns of sensor alarms. %patch0 -p1 %patch1 -p1 %patch2 -p1 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 +%patch6 -p1 mv prog/init/README prog/init/README.initscripts chmod -x prog/init/fancontrol.init @@ -186,6 +198,18 @@ fi %changelog +* Mon Apr 23 2018 Ondřej Lysoněk - 3.4.0-6.20160601gitf9185e5 +- Fix License field capitalization +- Resolves: rhbz#1577175 +- Add detection of AMD Ryzen w/ Vega graphics +- Resolves: rhbz#1569542 +- Fix issues found by Coverity Scan +- Resolves: rhbz#1578007 + +* Fri Apr 20 2018 Ondřej Lysoněk - 3.4.0-5.20160601gitf9185e5 +- Detect AMD Family 17h thermal sensors +- Resolves: rhbz#1569542 + * Tue Aug 23 2016 Martin Sehnoutka - 3.4.0-4.20160601gitf9185e5 - Print warning message when running on an alternative architecture. - Resolves: #1362664