Patch "perf python: Fix up the build on architectures without HAVE_KVM_STAT_SUPPORT" has been added to the 6.11-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    perf python: Fix up the build on architectures without HAVE_KVM_STAT_SUPPORT

to the 6.11-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     perf-python-fix-up-the-build-on-architectures-withou.patch
and it can be found in the queue-6.11 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 072a7f105b21bdfa3bdc3e5047a99f61a6a25474
Author: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx>
Date:   Wed Oct 23 16:12:57 2024 -0300

    perf python: Fix up the build on architectures without HAVE_KVM_STAT_SUPPORT
    
    [ Upstream commit 758f18158952a6287ac23679ec04c32d44ca5368 ]
    
    Noticed while building on a raspbian arm 32-bit system.
    
    There was also this other case, fixed by adding a missing util/stat.h
    with the prototypes:
    
      /tmp/tmp.MbiSHoF3dj/perf-6.12.0-rc3/tools/perf/util/python.c:1396:6: error: no previous prototype for ‘perf_stat__set_no_csv_summary’ [-Werror=missing-prototypes]
       1396 | void perf_stat__set_no_csv_summary(int set __maybe_unused)
            |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      /tmp/tmp.MbiSHoF3dj/perf-6.12.0-rc3/tools/perf/util/python.c:1400:6: error: no previous prototype for ‘perf_stat__set_big_num’ [-Werror=missing-prototypes]
       1400 | void perf_stat__set_big_num(int set __maybe_unused)
            |      ^~~~~~~~~~~~~~~~~~~~~~
      cc1: all warnings being treated as errors
    
    In other architectures this must be building due to some lucky indirect
    inclusion of that header.
    
    Fixes: 9dabf4003423c8d3 ("perf python: Switch module to linking libraries from building source")
    Reviewed-by: Ian Rogers <irogers@xxxxxxxxxx>
    Cc: Adrian Hunter <adrian.hunter@xxxxxxxxx>
    Cc: Jiri Olsa <jolsa@xxxxxxxxxx>
    Cc: Kan Liang <kan.liang@xxxxxxxxxxxxxxx>
    Cc: Namhyung Kim <namhyung@xxxxxxxxxx>
    Link: https://lore.kernel.org/lkml/ZxllAtpmEw5fg9oy@x1
    Signed-off-by: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/tools/perf/util/python.c b/tools/perf/util/python.c
index 31a223eaf8e65..ee3d43a7ba457 100644
--- a/tools/perf/util/python.c
+++ b/tools/perf/util/python.c
@@ -19,6 +19,7 @@
 #include "util/bpf-filter.h"
 #include "util/env.h"
 #include "util/kvm-stat.h"
+#include "util/stat.h"
 #include "util/kwork.h"
 #include "util/sample.h"
 #include "util/lock-contention.h"
@@ -1355,6 +1356,7 @@ PyMODINIT_FUNC PyInit_perf(void)
 
 unsigned int scripting_max_stack = PERF_MAX_STACK_DEPTH;
 
+#ifdef HAVE_KVM_STAT_SUPPORT
 bool kvm_entry_event(struct evsel *evsel __maybe_unused)
 {
 	return false;
@@ -1384,6 +1386,7 @@ void exit_event_decode_key(struct perf_kvm_stat *kvm __maybe_unused,
 			   char *decode __maybe_unused)
 {
 }
+#endif // HAVE_KVM_STAT_SUPPORT
 
 int find_scripts(char **scripts_array  __maybe_unused, char **scripts_path_array  __maybe_unused,
 		int num  __maybe_unused, int pathlen __maybe_unused)




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux