Hello community, here is the log from the commit of package cpupower for openSUSE:Factory checked in at 2018-10-17 08:42:10 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/cpupower (Old) and /work/SRC/openSUSE:Factory/.cpupower.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "cpupower" Wed Oct 17 08:42:10 2018 rev:37 rq:642281 version:4.19 Changes: -------- --- /work/SRC/openSUSE:Factory/cpupower/cpupower.changes 2018-10-08 17:46:20.014414371 +0200 +++ /work/SRC/openSUSE:Factory/.cpupower.new/cpupower.changes 2018-10-17 08:43:01.217773376 +0200 @@ -1,0 +2,6 @@ +Tue Oct 16 12:50:20 UTC 2018 - [email protected] + +- Fix static compilation and sysfs_read_file mess +A cpupower_fix_compilation_and_sysfs_read_file_mess.patch + +------------------------------------------------------------------- New: ---- cpupower_fix_compilation_and_sysfs_read_file_mess.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ cpupower.spec ++++++ --- /var/tmp/diff_new_pack.bW2X3h/_old 2018-10-17 08:43:06.989768485 +0200 +++ /var/tmp/diff_new_pack.bW2X3h/_new 2018-10-17 08:43:06.989768485 +0200 @@ -36,6 +36,7 @@ Patch1: cpupower_rapl.patch Patch2: rapl_monitor.patch Patch3: cpupower_exclude_kernel_Makefile.patch +Patch4: cpupower_fix_compilation_and_sysfs_read_file_mess.patch Patch22: turbostat_makefile_fix_asm_header.patch # Fixes bsc#1048546: @@ -88,6 +89,7 @@ %patch1 -p1 %patch2 -p1 %patch3 -p1 +%patch4 -p1 cd ../turbostat-%tsversion %patch22 -p1 ++++++ cpupower_fix_compilation_and_sysfs_read_file_mess.patch ++++++ >From [email protected] Subject: [PATCH] tools/power/cpupower: fix compilation with STATIC=true From: "Konstantin Khlebnikov" <[email protected]> To: "Shuah Khan" <[email protected]>,<[email protected]>, <[email protected]>, <[email protected]> Date: Tue, 16 Oct 2018 11:56:26 +0300 Message-ID: <153968018626.397151.17942194042449956995.stgit@buzz> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Rename duplicate sysfs_read_file into cpupower_read_sysfs and fix linking. Signed-off-by: Konstantin Khlebnikov <[email protected]> --- bench/Makefile | 2 +- lib/cpufreq.c | 2 +- lib/cpuidle.c | 2 +- lib/cpupower.c | 4 ++-- lib/cpupower_intern.h | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/bench/Makefile b/bench/Makefile index d79ab161cc75..f68b4bc55273 100644 --- a/bench/Makefile +++ b/bench/Makefile @@ -9,7 +9,7 @@ endif ifeq ($(strip $(STATIC)),true) LIBS = -L../ -L$(OUTPUT) -lm OBJS = $(OUTPUT)main.o $(OUTPUT)parse.o $(OUTPUT)system.o $(OUTPUT)benchmark.o \ - $(OUTPUT)../lib/cpufreq.o $(OUTPUT)../lib/sysfs.o + $(OUTPUT)../lib/cpufreq.o $(OUTPUT)../lib/cpupower.o else LIBS = -L../ -L$(OUTPUT) -lm -lcpupower OBJS = $(OUTPUT)main.o $(OUTPUT)parse.o $(OUTPUT)system.o $(OUTPUT)benchmark.o diff --git a/lib/cpufreq.c b/lib/cpufreq.c index 1b993fe1ce23..0c0f3e3f0d80 100644 --- a/lib/cpufreq.c +++ b/lib/cpufreq.c @@ -28,7 +28,7 @@ static unsigned int sysfs_cpufreq_read_file(unsigned int cpu, const char *fname, snprintf(path, sizeof(path), PATH_TO_CPU "cpu%u/cpufreq/%s", cpu, fname); - return sysfs_read_file(path, buf, buflen); + return cpupower_read_sysfs(path, buf, buflen); } /* helper function to write a new value to a /sys file */ diff --git a/lib/cpuidle.c b/lib/cpuidle.c index 9bd4c7655fdb..852d25462388 100644 --- a/lib/cpuidle.c +++ b/lib/cpuidle.c @@ -319,7 +319,7 @@ static unsigned int sysfs_cpuidle_read_file(const char *fname, char *buf, snprintf(path, sizeof(path), PATH_TO_CPU "cpuidle/%s", fname); - return sysfs_read_file(path, buf, buflen); + return cpupower_read_sysfs(path, buf, buflen); } diff --git a/lib/cpupower.c b/lib/cpupower.c index 9c395ec924de..9711d628b0f4 100644 --- a/lib/cpupower.c +++ b/lib/cpupower.c @@ -15,7 +15,7 @@ #include "cpupower.h" #include "cpupower_intern.h" -unsigned int sysfs_read_file(const char *path, char *buf, size_t buflen) +unsigned int cpupower_read_sysfs(const char *path, char *buf, size_t buflen) { int fd; ssize_t numread; @@ -95,7 +95,7 @@ static int sysfs_topology_read_file(unsigned int cpu, const char *fname, int *re snprintf(path, sizeof(path), PATH_TO_CPU "cpu%u/topology/%s", cpu, fname); - if (sysfs_read_file(path, linebuf, MAX_LINE_LEN) == 0) + if (cpupower_read_sysfs(path, linebuf, MAX_LINE_LEN) == 0) return -1; *result = strtol(linebuf, &endp, 0); if (endp == linebuf || errno == ERANGE) diff --git a/lib/cpupower_intern.h b/lib/cpupower_intern.h index 92affdfbe417..4887c76d23f8 100644 --- a/lib/cpupower_intern.h +++ b/lib/cpupower_intern.h @@ -3,4 +3,4 @@ #define MAX_LINE_LEN 4096 #define SYSFS_PATH_MAX 255 -unsigned int sysfs_read_file(const char *path, char *buf, size_t buflen); +unsigned int cpupower_read_sysfs(const char *path, char *buf, size_t buflen); ++++++ cpupower_rapl.patch ++++++ --- /var/tmp/diff_new_pack.bW2X3h/_old 2018-10-17 08:43:07.033768448 +0200 +++ /var/tmp/diff_new_pack.bW2X3h/_new 2018-10-17 08:43:07.033768448 +0200 @@ -75,19 +75,6 @@ - for HLANG in $(LANGUAGES); do \ rm -f $(DESTDIR)${localedir}/$$HLANG/LC_MESSAGES/cpupower.mo; \ done; -Index: cpupower-4.15/bench/Makefile -=================================================================== ---- cpupower-4.15.orig/bench/Makefile 2018-01-10 20:18:31.000000000 +0100 -+++ cpupower-4.15/bench/Makefile 2018-01-11 16:49:11.946784841 +0100 -@@ -9,7 +9,7 @@ endif - ifeq ($(strip $(STATIC)),true) - LIBS = -L../ -L$(OUTPUT) -lm - OBJS = $(OUTPUT)main.o $(OUTPUT)parse.o $(OUTPUT)system.o $(OUTPUT)benchmark.o \ -- $(OUTPUT)../lib/cpufreq.o $(OUTPUT)../lib/sysfs.o -+ $(OUTPUT)../lib/cpufreq.o $(OUTPUT)../lib/cpupower.o - else - LIBS = -L../ -L$(OUTPUT) -lm -lcpupower - OBJS = $(OUTPUT)main.o $(OUTPUT)parse.o $(OUTPUT)system.o $(OUTPUT)benchmark.o Index: cpupower-4.15/lib/powercap.c =================================================================== --- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++++ rapl_monitor.patch ++++++ --- /var/tmp/diff_new_pack.bW2X3h/_old 2018-10-17 08:43:07.041768442 +0200 +++ /var/tmp/diff_new_pack.bW2X3h/_new 2018-10-17 08:43:07.041768442 +0200 @@ -3,10 +3,10 @@ Signed-off-by: Thomas Renninger <[email protected]> -Index: cpupower-4.15/Makefile +Index: cpupower-4.19/Makefile =================================================================== ---- cpupower-4.15.orig/Makefile 2018-01-11 16:49:11.946784841 +0100 -+++ cpupower-4.15/Makefile 2018-01-11 16:49:23.619489210 +0100 +--- cpupower-4.19.orig/Makefile 2018-10-16 14:27:01.046284334 +0200 ++++ cpupower-4.19/Makefile 2018-10-16 14:27:13.675001106 +0200 @@ -139,6 +139,7 @@ UTIL_OBJS = utils/helpers/amd.o utils/h utils/idle_monitor/hsw_ext_idle.o \ utils/idle_monitor/amd_fam14h_idle.o utils/idle_monitor/cpuidle_sysfs.o \ @@ -15,11 +15,11 @@ utils/cpupower.o utils/cpufreq-info.o utils/cpufreq-set.o \ utils/cpupower-set.o utils/cpupower-info.o utils/cpuidle-info.o \ utils/cpuidle-set.o utils/powercap-info.o -Index: cpupower-4.15/utils/idle_monitor/cpupower-monitor.c +Index: cpupower-4.19/utils/idle_monitor/cpupower-monitor.c =================================================================== ---- cpupower-4.15.orig/utils/idle_monitor/cpupower-monitor.c 2018-01-10 20:18:31.000000000 +0100 -+++ cpupower-4.15/utils/idle_monitor/cpupower-monitor.c 2018-01-11 16:49:23.619489210 +0100 -@@ -454,9 +454,10 @@ int cmd_monitor(int argc, char **argv) +--- cpupower-4.19.orig/utils/idle_monitor/cpupower-monitor.c 2018-09-30 16:15:35.000000000 +0200 ++++ cpupower-4.19/utils/idle_monitor/cpupower-monitor.c 2018-10-16 14:27:01.070285696 +0200 +@@ -459,9 +459,10 @@ int cmd_monitor(int argc, char **argv) print_results(1, cpu); } @@ -33,10 +33,10 @@ cpu_topology_release(cpu_top); return 0; } -Index: cpupower-4.15/utils/idle_monitor/idle_monitors.def +Index: cpupower-4.19/utils/idle_monitor/idle_monitors.def =================================================================== ---- cpupower-4.15.orig/utils/idle_monitor/idle_monitors.def 2018-01-10 20:18:31.000000000 +0100 -+++ cpupower-4.15/utils/idle_monitor/idle_monitors.def 2018-01-11 16:49:23.619489210 +0100 +--- cpupower-4.19.orig/utils/idle_monitor/idle_monitors.def 2018-09-30 16:15:35.000000000 +0200 ++++ cpupower-4.19/utils/idle_monitor/idle_monitors.def 2018-10-16 14:27:01.070285696 +0200 @@ -4,5 +4,6 @@ DEF(intel_nhm) DEF(intel_snb) DEF(intel_hsw_ext) @@ -44,10 +44,10 @@ +DEF(rapl) #endif DEF(cpuidle_sysfs) -Index: cpupower-4.15/utils/idle_monitor/rapl_monitor.c +Index: cpupower-4.19/utils/idle_monitor/rapl_monitor.c =================================================================== --- /dev/null 1970-01-01 00:00:00.000000000 +0000 -+++ cpupower-4.15/utils/idle_monitor/rapl_monitor.c 2018-01-11 16:49:23.623489452 +0100 ++++ cpupower-4.19/utils/idle_monitor/rapl_monitor.c 2018-10-16 14:27:01.070285696 +0200 @@ -0,0 +1,141 @@ +/* + * (C) 2016 Thomas Renninger <[email protected]>
