diff options
author | Saravana Kannan <[email protected]> | 2020-05-21 12:17:58 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <[email protected]> | 2020-07-10 15:24:56 +0200 |
commit | 287905e68dd29873bcb7986a8290cd1e4cfde600 (patch) | |
tree | 2aea5d81358554da1110abeb3dfb34a1b25531aa /tools/perf/util/scripting-engines/trace-event-python.c | |
parent | fe940d7362e6d7a5e5086581d0462e00ba766992 (diff) |
driver core: Expose device link details in sysfs
It's helpful to be able to look at device link details from sysfs. So,
expose it in sysfs.
Say device-A is supplier of device-B. These are the additional files
this patch would create:
/sys/class/devlink/device-A:device-B/
auto_remove_on
consumer/ -> .../device-B/
runtime_pm
status
supplier/ -> .../device-A/
sync_state_only
/sys/devices/.../device-A/
consumer:device-B/ -> /sys/class/devlink/device-A:device-B/
/sys/devices/.../device-B/
supplier:device-A/ -> /sys/class/devlink/device-A:device-B/
That way:
To get a list of all the device link in the system:
ls /sys/class/devlink/
To get the consumer names and links of a device:
ls -d /sys/devices/.../device-X/consumer:*
To get the supplier names and links of a device:
ls -d /sys/devices/.../device-X/supplier:*
Signed-off-by: Saravana Kannan <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-python.c')
0 files changed, 0 insertions, 0 deletions