aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorTianyu Li <tianyu.li@arm.com>2023-08-29 07:59:12 +0000
committerDamjan Marion <dmarion@0xa5.net>2023-09-13 12:15:53 +0000
commit4585bb121b4acfab2f34237f1d0e9ea6077110c0 (patch)
treed8b83f38c6ae4c04e8c88af5cf37e21f210bb0dc /src/plugins
parent986ca97311daef6faf3d53f3fd3ab90390f17a36 (diff)
perfmon: fix perf_user_access_enabled type
perf_user_access_enabled is defined as u8, clib_sysfs_read format type is %u, this is for unsigned int, change type from u8 to u32. Type: fix Fixes: 268d7be66b8b ("perfmon: enable perfmon plugin for Arm") Signed-off-by: Tianyu Li <tianyu.li@arm.com> Change-Id: I48ec00605e496d185370e77d894d7852d6d22124
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/perfmon/arm/events.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/perfmon/arm/events.c b/src/plugins/perfmon/arm/events.c
index bf73ad6e896..f2406b3ea05 100644
--- a/src/plugins/perfmon/arm/events.c
+++ b/src/plugins/perfmon/arm/events.c
@@ -75,7 +75,7 @@ arm_init (vlib_main_t *vm, perfmon_source_t *src)
- if the file exists and is 0, user access needs to be granted
with 'sudo sysctl kernel/perf_user_access=1'
*/
- u8 perf_user_access_enabled;
+ u32 perf_user_access_enabled;
char *path = "/proc/sys/kernel/perf_user_access";
err = clib_sysfs_read (path, "%u", &perf_user_access_enabled);
if (err)