]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
docs: iio: ad4062: Add GPIO Controller support
authorJorge Marques <jorge.marques@analog.com>
Wed, 17 Dec 2025 12:13:31 +0000 (13:13 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Wed, 31 Dec 2025 17:59:25 +0000 (17:59 +0000)
Explains the GPIO controller support with emphasis on the mask
depending on which GPs are exposed.

Signed-off-by: Jorge Marques <jorge.marques@analog.com>
Reviewed-by: Linus Walleij <linusw@kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Documentation/iio/ad4062.rst

index 8d388f9e2f450eabeab5d9387e39e2fa0800c25b..d77287836430c1e62b36a83aa5cfe09c4eb280c5 100644 (file)
@@ -29,6 +29,9 @@ the devicetree ``interrupt-names`` property:
 - GP0: Is assigned the role of Threshold Either signal.
 - GP1: Is assigned the role of Data Ready signal.
 
+If the property ``gpio-controller`` is present in the devicetree, then the GPO
+not present in the ``interrupt-names`` is exposed as a GPO.
+
 Device attributes
 =================
 
@@ -134,3 +137,12 @@ The following event attributes are available:
      - Set the hysteresis value for the maximum threshold.
    * - ``thresh_rising_value``
      - Set the maximum threshold value.
+
+GPO controller support
+======================
+
+The device supports using GP0 and GP1 as GPOs. If the devicetree contains the
+node ``gpio-controller```, the device is marked as a GPIO controller and the
+GPs not listed in ``interrupt-names`` are exposed as a GPO. The GPIO index
+matches the pin name, so if GP0 is not exposed but GP1 is, index 0 is masked
+out and only index 1 can be set.