1
0
mirror of https://github.com/ARM-software/devlib.git synced 2025-01-30 17:50:46 +00:00

modules/sched: Use correct permissions to read debugfs

Use target.list_directory(as_root=target.is_rooted) instead of doing it
as a normal user for paths in /sys/kernel/debug. Since this
list_directory() call can be used with multiple path, we do not force
as_root=True but we increase the chance of it working.
This commit is contained in:
Douglas Raillard 2022-04-05 12:39:45 +01:00 committed by Marc Bonnici
parent a65189f028
commit f6bbd2c187

View File

@ -329,7 +329,7 @@ class SchedProcFSData(SchedProcFSNode):
except TargetStableError:
return False
cpus = target.list_directory(path)
cpus = target.list_directory(path, as_root=target.is_rooted)
if not cpus:
return False