1Linux Devlink Documentation 2=========================== 3 4devlink is an API to expose device information and resources not directly 5related to any device class, such as chip-wide/switch-ASIC-wide configuration. 6 7Locking 8------- 9 10Driver facing APIs are currently transitioning to allow more explicit 11locking. Drivers can use the existing ``devlink_*`` set of APIs, or 12new APIs prefixed by ``devl_*``. The older APIs handle all the locking 13in devlink core, but don't allow registration of most sub-objects once 14the main devlink object is itself registered. The newer ``devl_*`` APIs assume 15the devlink instance lock is already held. Drivers can take the instance 16lock by calling ``devl_lock()``. It is also held in most of the callbacks. 17Eventually all callbacks will be invoked under the devlink instance lock, 18refer to the use of the ``DEVLINK_NL_FLAG_NO_LOCK`` flag in devlink core 19to find out which callbacks are not converted, yet. 20 21Drivers are encouraged to use the devlink instance lock for their own needs. 22 23Interface documentation 24----------------------- 25 26The following pages describe various interfaces available through devlink in 27general. 28 29.. toctree:: 30 :maxdepth: 1 31 32 devlink-dpipe 33 devlink-health 34 devlink-info 35 devlink-flash 36 devlink-params 37 devlink-port 38 devlink-region 39 devlink-resource 40 devlink-reload 41 devlink-selftests 42 devlink-trap 43 devlink-linecard 44 45Driver-specific documentation 46----------------------------- 47 48Each driver that implements ``devlink`` is expected to document what 49parameters, info versions, and other features it supports. 50 51.. toctree:: 52 :maxdepth: 1 53 54 bnxt 55 hns3 56 ionic 57 ice 58 mlx4 59 mlx5 60 mlxsw 61 mv88e6xxx 62 netdevsim 63 nfp 64 qed 65 ti-cpsw-switch 66 am65-nuss-cpsw-switch 67 prestera 68 iosm 69 octeontx2 70