]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
tools/power turbostat: Fix build with musl
authorCalvin Owens <calvin@wbinvd.org>
Fri, 13 Jun 2025 16:54:23 +0000 (09:54 -0700)
committerLen Brown <len.brown@intel.com>
Fri, 8 Aug 2025 20:05:53 +0000 (16:05 -0400)
turbostat.c: In function 'parse_int_file':
    turbostat.c:5567:19: error: 'PATH_MAX' undeclared (first use in this function)
     5567 |         char path[PATH_MAX];
          |                   ^~~~~~~~

    turbostat.c: In function 'probe_graphics':
    turbostat.c:6787:19: error: 'PATH_MAX' undeclared (first use in this function)
     6787 |         char path[PATH_MAX];
          |                   ^~~~~~~~

Signed-off-by: Calvin Owens <calvin@wbinvd.org>
Reviewed-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
tools/power/x86/turbostat/turbostat.c

index 4056b7e26a0f9c02a495a7e5827f60bfa2589515..778aee48c6e6b5b1d4cac4244a99fd3538fc3ee3 100644 (file)
@@ -67,6 +67,7 @@
 #include <stdbool.h>
 #include <assert.h>
 #include <linux/kernel.h>
+#include <limits.h>
 
 #define UNUSED(x) (void)(x)