aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeonard Crestez <leonard.crestez@nxp.com>2019-11-19 18:38:56 +0200
committerJonathan Corbet <corbet@lwn.net>2019-11-19 13:16:53 -0700
commit83ededdb72ca125ddb9a6270b966ef0c26b5cf5a (patch)
treec7a145399f27885d59f3247f2bc44c11fed6832a
parentDocumentation: Document how to get links with git am (diff)
downloadlinux-dev-83ededdb72ca125ddb9a6270b966ef0c26b5cf5a.tar.xz
linux-dev-83ededdb72ca125ddb9a6270b966ef0c26b5cf5a.zip
docs: Add initial documentation for devfreq
The devfreq subsystem has plenty of kernel-doc comments but they're not currently included in sphinx documentation. Add a minimal devfreq.rst file which mostly just includes kernel-doc comments from devfreq source. This also exposes a number of kernel-doc warnings on `make htmldocs` Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com> Link: https://lore.kernel.org/r/e32fa9de8a60060a6ee5fc42f163111034f9a550.1574181341.git.leonard.crestez@nxp.com Signed-off-by: Jonathan Corbet <corbet@lwn.net>
-rw-r--r--Documentation/driver-api/devfreq.rst30
-rw-r--r--Documentation/driver-api/index.rst1
2 files changed, 31 insertions, 0 deletions
diff --git a/Documentation/driver-api/devfreq.rst b/Documentation/driver-api/devfreq.rst
new file mode 100644
index 000000000000..4a0bf87a3b13
--- /dev/null
+++ b/Documentation/driver-api/devfreq.rst
@@ -0,0 +1,30 @@
+.. SPDX-License-Identifier: GPL-2.0
+
+========================
+Device Frequency Scaling
+========================
+
+Introduction
+------------
+
+This framework provides a standard kernel interface for Dynamic Voltage and
+Frequency Switching on arbitrary devices.
+
+It exposes controls for adjusting frequency through sysfs files which are
+similar to the cpufreq subsystem.
+
+Devices for which current usage can be measured can have their frequency
+automatically adjusted by governors.
+
+API
+---
+
+Device drivers need to initialize a :c:type:`devfreq_profile` and call the
+:c:func:`devfreq_add_device` function to create a :c:type:`devfreq` instance.
+
+.. kernel-doc:: include/linux/devfreq.h
+.. kernel-doc:: include/linux/devfreq-event.h
+.. kernel-doc:: drivers/devfreq/devfreq.c
+ :export:
+.. kernel-doc:: drivers/devfreq/devfreq-event.c
+ :export:
diff --git a/Documentation/driver-api/index.rst b/Documentation/driver-api/index.rst
index 46d6a165b5a5..e66ebf5bfc89 100644
--- a/Documentation/driver-api/index.rst
+++ b/Documentation/driver-api/index.rst
@@ -39,6 +39,7 @@ available subsections can be seen below.
ipmb
i3c/index
interconnect
+ devfreq
hsi
edac
scsi