1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0 2c66ec88fSEmmanuel Vadot%YAML 1.2 3c66ec88fSEmmanuel Vadot--- 4c66ec88fSEmmanuel Vadot$id: http://devicetree.org/schemas/display/allwinner,sun6i-a31-drc.yaml# 5c66ec88fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6c66ec88fSEmmanuel Vadot 7*7ef62cebSEmmanuel Vadottitle: Allwinner A31 Dynamic Range Controller 8c66ec88fSEmmanuel Vadot 9c66ec88fSEmmanuel Vadotmaintainers: 10c66ec88fSEmmanuel Vadot - Chen-Yu Tsai <wens@csie.org> 11c66ec88fSEmmanuel Vadot - Maxime Ripard <mripard@kernel.org> 12c66ec88fSEmmanuel Vadot 13c66ec88fSEmmanuel Vadotdescription: | 14c66ec88fSEmmanuel Vadot The DRC (Dynamic Range Controller) allows to dynamically adjust 15c66ec88fSEmmanuel Vadot pixel brightness/contrast based on histogram measurements for LCD 16c66ec88fSEmmanuel Vadot content adaptive backlight control. 17c66ec88fSEmmanuel Vadot 18c66ec88fSEmmanuel Vadotproperties: 19c66ec88fSEmmanuel Vadot compatible: 20c66ec88fSEmmanuel Vadot enum: 21c66ec88fSEmmanuel Vadot - allwinner,sun6i-a31-drc 22c66ec88fSEmmanuel Vadot - allwinner,sun6i-a31s-drc 23c66ec88fSEmmanuel Vadot - allwinner,sun8i-a23-drc 24c66ec88fSEmmanuel Vadot - allwinner,sun8i-a33-drc 25c66ec88fSEmmanuel Vadot - allwinner,sun9i-a80-drc 26c66ec88fSEmmanuel Vadot 27c66ec88fSEmmanuel Vadot reg: 28c66ec88fSEmmanuel Vadot maxItems: 1 29c66ec88fSEmmanuel Vadot 30c66ec88fSEmmanuel Vadot interrupts: 31c66ec88fSEmmanuel Vadot maxItems: 1 32c66ec88fSEmmanuel Vadot 33c66ec88fSEmmanuel Vadot clocks: 34c66ec88fSEmmanuel Vadot items: 35c66ec88fSEmmanuel Vadot - description: The DRC interface clock 36c66ec88fSEmmanuel Vadot - description: The DRC module clock 37c66ec88fSEmmanuel Vadot - description: The DRC DRAM clock 38c66ec88fSEmmanuel Vadot 39c66ec88fSEmmanuel Vadot clock-names: 40c66ec88fSEmmanuel Vadot items: 41c66ec88fSEmmanuel Vadot - const: ahb 42c66ec88fSEmmanuel Vadot - const: mod 43c66ec88fSEmmanuel Vadot - const: ram 44c66ec88fSEmmanuel Vadot 45c66ec88fSEmmanuel Vadot resets: 46c66ec88fSEmmanuel Vadot maxItems: 1 47c66ec88fSEmmanuel Vadot 48c66ec88fSEmmanuel Vadot ports: 495def4c47SEmmanuel Vadot $ref: /schemas/graph.yaml#/properties/ports 50c66ec88fSEmmanuel Vadot 51c66ec88fSEmmanuel Vadot properties: 52c66ec88fSEmmanuel Vadot port@0: 535def4c47SEmmanuel Vadot $ref: /schemas/graph.yaml#/properties/port 54c66ec88fSEmmanuel Vadot description: | 55c66ec88fSEmmanuel Vadot Input endpoints of the controller. 56c66ec88fSEmmanuel Vadot 57c66ec88fSEmmanuel Vadot port@1: 585def4c47SEmmanuel Vadot $ref: /schemas/graph.yaml#/properties/port 59c66ec88fSEmmanuel Vadot description: | 60c66ec88fSEmmanuel Vadot Output endpoints of the controller. 61c66ec88fSEmmanuel Vadot 62c66ec88fSEmmanuel Vadot required: 63c66ec88fSEmmanuel Vadot - port@0 64c66ec88fSEmmanuel Vadot - port@1 65c66ec88fSEmmanuel Vadot 66c66ec88fSEmmanuel Vadotrequired: 67c66ec88fSEmmanuel Vadot - compatible 68c66ec88fSEmmanuel Vadot - reg 69c66ec88fSEmmanuel Vadot - interrupts 70c66ec88fSEmmanuel Vadot - clocks 71c66ec88fSEmmanuel Vadot - clock-names 72c66ec88fSEmmanuel Vadot - resets 73c66ec88fSEmmanuel Vadot - ports 74c66ec88fSEmmanuel Vadot 75c66ec88fSEmmanuel VadotadditionalProperties: false 76c66ec88fSEmmanuel Vadot 77c66ec88fSEmmanuel Vadotexamples: 78c66ec88fSEmmanuel Vadot - | 79c66ec88fSEmmanuel Vadot #include <dt-bindings/interrupt-controller/arm-gic.h> 80c66ec88fSEmmanuel Vadot 81c66ec88fSEmmanuel Vadot #include <dt-bindings/clock/sun6i-a31-ccu.h> 82c66ec88fSEmmanuel Vadot #include <dt-bindings/reset/sun6i-a31-ccu.h> 83c66ec88fSEmmanuel Vadot 84c66ec88fSEmmanuel Vadot drc0: drc@1e70000 { 85c66ec88fSEmmanuel Vadot compatible = "allwinner,sun6i-a31-drc"; 86c66ec88fSEmmanuel Vadot reg = <0x01e70000 0x10000>; 87c66ec88fSEmmanuel Vadot interrupts = <GIC_SPI 91 IRQ_TYPE_LEVEL_HIGH>; 88c66ec88fSEmmanuel Vadot clocks = <&ccu CLK_AHB1_DRC0>, <&ccu CLK_IEP_DRC0>, 89c66ec88fSEmmanuel Vadot <&ccu CLK_DRAM_DRC0>; 90c66ec88fSEmmanuel Vadot clock-names = "ahb", "mod", 91c66ec88fSEmmanuel Vadot "ram"; 92c66ec88fSEmmanuel Vadot resets = <&ccu RST_AHB1_DRC0>; 93c66ec88fSEmmanuel Vadot 94c66ec88fSEmmanuel Vadot ports { 95c66ec88fSEmmanuel Vadot #address-cells = <1>; 96c66ec88fSEmmanuel Vadot #size-cells = <0>; 97c66ec88fSEmmanuel Vadot 98c66ec88fSEmmanuel Vadot drc0_in: port@0 { 99c66ec88fSEmmanuel Vadot reg = <0>; 100c66ec88fSEmmanuel Vadot 101c66ec88fSEmmanuel Vadot drc0_in_be0: endpoint { 102c66ec88fSEmmanuel Vadot remote-endpoint = <&be0_out_drc0>; 103c66ec88fSEmmanuel Vadot }; 104c66ec88fSEmmanuel Vadot }; 105c66ec88fSEmmanuel Vadot 106c66ec88fSEmmanuel Vadot drc0_out: port@1 { 107c66ec88fSEmmanuel Vadot #address-cells = <1>; 108c66ec88fSEmmanuel Vadot #size-cells = <0>; 109c66ec88fSEmmanuel Vadot reg = <1>; 110c66ec88fSEmmanuel Vadot 111c66ec88fSEmmanuel Vadot drc0_out_tcon0: endpoint@0 { 112c66ec88fSEmmanuel Vadot reg = <0>; 113c66ec88fSEmmanuel Vadot remote-endpoint = <&tcon0_in_drc0>; 114c66ec88fSEmmanuel Vadot }; 115c66ec88fSEmmanuel Vadot 116c66ec88fSEmmanuel Vadot drc0_out_tcon1: endpoint@1 { 117c66ec88fSEmmanuel Vadot reg = <1>; 118c66ec88fSEmmanuel Vadot remote-endpoint = <&tcon1_in_drc0>; 119c66ec88fSEmmanuel Vadot }; 120c66ec88fSEmmanuel Vadot }; 121c66ec88fSEmmanuel Vadot }; 122c66ec88fSEmmanuel Vadot }; 123c66ec88fSEmmanuel Vadot 124c66ec88fSEmmanuel Vadot 125c66ec88fSEmmanuel Vadot... 126