Documentation/devicetree/bindings/gpio/gpio-line-mux.yaml

Source file repositories/reference/linux-study-clean/Documentation/devicetree/bindings/gpio/gpio-line-mux.yaml

File Facts

System
Linux kernel
Corpus path
Documentation/devicetree/bindings/gpio/gpio-line-mux.yaml
Extension
.yaml
Size
2456 bytes
Lines
108
Domain
Support Tooling And Documentation
Bucket
Documentation
Inferred role
Support Tooling And Documentation: configuration, schema, or hardware description
Status
atlas-only

Why This File Exists

Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.

Dependency Surface

Detected Declarations

Annotated Snippet

# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/gpio/gpio-line-mux.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: GPIO line mux

maintainers:
  - Jonas Jelonek <jelonek.jonas@gmail.com>

description: |
  A GPIO controller to provide virtual GPIOs for a 1-to-many input-only mapping
  backed by a single shared GPIO and a multiplexer. A simple illustrated
  example is:

            +----- A
    IN     /
    <-----o------- B
        / |\
        | | +----- C
        | |  \
        | |   +--- D
        | |
       M1 M0

    MUX CONTROL

     M1 M0   IN
      0  0   A
      0  1   B
      1  0   C
      1  1   D

  This can be used in case a real GPIO is connected to multiple inputs and
  controlled by a multiplexer, and another subsystem/driver does not work
  directly with the multiplexer subsystem.

properties:
  compatible:
    const: gpio-line-mux

  gpio-controller: true

  "#gpio-cells":
    const: 2

  gpio-line-mux-states:
    description: Mux states corresponding to the virtual GPIOs.
    $ref: /schemas/types.yaml#/definitions/uint32-array

  gpio-line-names: true

  mux-controls:
    maxItems: 1
    description:
      Phandle to the multiplexer to control access to the GPIOs.

  ngpios: false

  muxed-gpios:
    maxItems: 1
    description:
      GPIO which is the '1' in 1-to-many and is shared by the virtual GPIOs
      and controlled via the mux.

required:
  - compatible
  - gpio-controller
  - gpio-line-mux-states

Annotation

Implementation Notes