brintos

brintos / linux-shallow public Read only

0
0
Text · 2.9 KiB · 8b3b3bf Raw
136 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2%YAML 1.23---4$id: http://devicetree.org/schemas/leds/leds-lgm.yaml#5$schema: http://devicetree.org/meta-schemas/core.yaml#6 7title: Intel Lightning Mountain (LGM) SoC LED Serial Shift Output (SSO) Controller driver8 9maintainers:10  - Zhu, Yi Xin <Yixin.zhu@intel.com>11  - Amireddy Mallikarjuna reddy <mallikarjunax.reddy@intel.com>12 13properties:14  compatible:15    const: intel,lgm-ssoled16 17  reg:18    maxItems: 119 20  clocks:21    maxItems: 222 23  clock-names:24    items:25      - const: sso26      - const: fpid27 28  gpio-controller: true29 30  '#gpio-cells':31    const: 232 33  ngpios:34    minimum: 035    maximum: 3236    description:37      Number of GPIOs this controller provides.38 39  intel,sso-update-rate-hz:40    description:41      Blink frequency for SOUTs in Hz.42 43  led-controller:44    type: object45    description:46      This sub-node must contain a sub-node for each leds.47 48    additionalProperties: false49 50    properties:51      '#address-cells':52        const: 153 54      '#size-cells':55        const: 056 57    patternProperties:58      "^led@[0-2]$":59        $ref: common.yaml#60        unevaluatedProperties: false61 62        properties:63          reg:64            description: Index of the LED.65            minimum: 066            maximum: 267 68          led-gpios:69            maxItems: 170 71          intel,sso-hw-trigger:72            type: boolean73            description: This property indicates Hardware driven/control LED.74 75          intel,sso-hw-blink:76            type: boolean77            description: This property indicates Enable LED blink by Hardware.78 79          intel,sso-blink-rate-hz:80            description: LED HW blink frequency.81 82          retain-state-suspended:83            type: boolean84            description: The suspend state of LED can be retained.85 86          retain-state-shutdown:87            type: boolean88            description: Retain the state of the LED on shutdown.89 90required:91  - compatible92  - reg93  - clocks94  - clock-names95  - "#gpio-cells"96  - gpio-controller97 98additionalProperties: false99 100examples:101  - |102    #include <dt-bindings/clock/intel,lgm-clk.h>103    #include <dt-bindings/leds/common.h>104 105    ssogpio: ssogpio@e0d40000 {106      compatible = "intel,lgm-ssoled";107      reg = <0xE0D40000 0x2E4>;108      gpio-controller;109      #gpio-cells = <2>;110      ngpios = <32>;111      pinctrl-names = "default";112      pinctrl-0 = <&pinctrl_ledc>;113      clocks = <&cgu0 LGM_GCLK_LEDC0>, <&afeclk>;114      clock-names = "sso", "fpid";115      intel,sso-update-rate-hz = <250000>;116 117      led-controller {118        #address-cells = <1>;119        #size-cells = <0>;120 121        led@0 {122          reg = <0>;123          function = "gphy";124          color = <LED_COLOR_ID_GREEN>;125          led-gpios = <&ssogpio 0 0>;126        };127 128        led@2 {129          reg = <2>;130          function = LED_FUNCTION_POWER;131          color = <LED_COLOR_ID_GREEN>;132          led-gpios = <&ssogpio 23 0>;133        };134      };135    };136