|
| 1 | +What: /sys/class/devlink/.../ |
| 2 | +Date: May 2020 |
| 3 | +Contact: Saravana Kannan <saravanak@google.com> |
| 4 | +Description: |
| 5 | + Provide a place in sysfs for the device link objects in the |
| 6 | + kernel at any given time. The name of a device link directory, |
| 7 | + denoted as ... above, is of the form <supplier>--<consumer> |
| 8 | + where <supplier> is the supplier device name and <consumer> is |
| 9 | + the consumer device name. |
| 10 | + |
| 11 | +What: /sys/class/devlink/.../auto_remove_on |
| 12 | +Date: May 2020 |
| 13 | +Contact: Saravana Kannan <saravanak@google.com> |
| 14 | +Description: |
| 15 | + This file indicates if the device link will ever be |
| 16 | + automatically removed by the driver core when the consumer and |
| 17 | + supplier devices themselves are still present. |
| 18 | + |
| 19 | + This will be one of the following strings: |
| 20 | + |
| 21 | + 'consumer unbind' |
| 22 | + 'supplier unbind' |
| 23 | + 'never' |
| 24 | + |
| 25 | + 'consumer unbind' means the device link will be removed when |
| 26 | + the consumer's driver is unbound from the consumer device. |
| 27 | + |
| 28 | + 'supplier unbind' means the device link will be removed when |
| 29 | + the supplier's driver is unbound from the supplier device. |
| 30 | + |
| 31 | + 'never' means the device link will not be automatically removed |
| 32 | + when as long as the supplier and consumer devices themselves |
| 33 | + are still present. |
| 34 | + |
| 35 | +What: /sys/class/devlink/.../consumer |
| 36 | +Date: May 2020 |
| 37 | +Contact: Saravana Kannan <saravanak@google.com> |
| 38 | +Description: |
| 39 | + This file is a symlink to the consumer device's sysfs directory. |
| 40 | + |
| 41 | +What: /sys/class/devlink/.../runtime_pm |
| 42 | +Date: May 2020 |
| 43 | +Contact: Saravana Kannan <saravanak@google.com> |
| 44 | +Description: |
| 45 | + This file indicates if the device link has any impact on the |
| 46 | + runtime power management behavior of the consumer and supplier |
| 47 | + devices. For example: Making sure the supplier doesn't enter |
| 48 | + runtime suspend while the consumer is active. |
| 49 | + |
| 50 | + This will be one of the following strings: |
| 51 | + |
| 52 | + '0' - Does not affect runtime power management |
| 53 | + '1' - Affects runtime power management |
| 54 | + |
| 55 | +What: /sys/class/devlink/.../status |
| 56 | +Date: May 2020 |
| 57 | +Contact: Saravana Kannan <saravanak@google.com> |
| 58 | +Description: |
| 59 | + This file indicates the status of the device link. The status |
| 60 | + of a device link is affected by whether the supplier and |
| 61 | + consumer devices have been bound to their corresponding |
| 62 | + drivers. The status of a device link also affects the binding |
| 63 | + and unbinding of the supplier and consumer devices with their |
| 64 | + drivers and also affects whether the software state of the |
| 65 | + supplier device is synced with the hardware state of the |
| 66 | + supplier device after boot up. |
| 67 | + See also: sysfs-devices-state_synced. |
| 68 | + |
| 69 | + This will be one of the following strings: |
| 70 | + |
| 71 | + 'not tracked' |
| 72 | + 'dormant' |
| 73 | + 'available' |
| 74 | + 'consumer probing' |
| 75 | + 'active' |
| 76 | + 'supplier unbinding' |
| 77 | + 'unknown' |
| 78 | + |
| 79 | + 'not tracked' means this device link does not track the status |
| 80 | + and has no impact on the binding, unbinding and syncing the |
| 81 | + hardware and software device state. |
| 82 | + |
| 83 | + 'dormant' means the supplier and the consumer devices have not |
| 84 | + bound to their driver. |
| 85 | + |
| 86 | + 'available' means the supplier has bound to its driver and is |
| 87 | + available to supply resources to the consumer device. |
| 88 | + |
| 89 | + 'consumer probing' means the consumer device is currently |
| 90 | + trying to bind to its driver. |
| 91 | + |
| 92 | + 'active' means the supplier and consumer devices have both |
| 93 | + bound successfully to their drivers. |
| 94 | + |
| 95 | + 'supplier unbinding' means the supplier devices is currently in |
| 96 | + the process of unbinding from its driver. |
| 97 | + |
| 98 | + 'unknown' means the state of the device link is not any of the |
| 99 | + above. If this is ever the value, there's a bug in the kernel. |
| 100 | + |
| 101 | +What: /sys/class/devlink/.../supplier |
| 102 | +Date: May 2020 |
| 103 | +Contact: Saravana Kannan <saravanak@google.com> |
| 104 | +Description: |
| 105 | + This file is a symlink to the supplier device's sysfs directory. |
| 106 | + |
| 107 | +What: /sys/class/devlink/.../sync_state_only |
| 108 | +Date: May 2020 |
| 109 | +Contact: Saravana Kannan <saravanak@google.com> |
| 110 | +Description: |
| 111 | + This file indicates if the device link is limited to only |
| 112 | + affecting the syncing of the hardware and software state of the |
| 113 | + supplier device. |
| 114 | + |
| 115 | + This will be one of the following strings: |
| 116 | + |
| 117 | + '0' |
| 118 | + '1' - Affects runtime power management |
| 119 | + |
| 120 | + '0' means the device link can affect other device behaviors |
| 121 | + like binding/unbinding, suspend/resume, runtime power |
| 122 | + management, etc. |
| 123 | + |
| 124 | + '1' means the device link will only affect the syncing of |
| 125 | + hardware and software state of the supplier device after boot |
| 126 | + up and doesn't not affect other behaviors of the devices. |
0 commit comments