Skip to content

Commit 5bad164

Browse files
Marek Vasutbroonie
authored andcommitted
regulator: dt-bindings: rpi-panel: Split 7" Raspberry Pi 720x1280 v2 binding
The 5" and 7" Raspberry Pi 720x1280 Display 2 MCU is a bit more complex than the original Display 1 ATTINY88 and the binding is also a bit more demanding. Split the binding into separate file and fill in required gpio-controller, #gpio-cells and #pwm-cells which must be present for the V2 MCU. Include mention of the 5" panel in the description of Display 2, as the 5" panel uses the same MCU. Fixes: 6d09c6e ("regulator: dt-bindings: rpi-panel: Add regulator for 7" Raspberry Pi 720x1280") Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org> Acked-by: Conor Dooley <conor.dooley@microchip.com> Message-ID: <20250905191637.147141-1-marek.vasut+renesas@mailbox.org> Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 92b9c2b commit 5bad164

2 files changed

Lines changed: 63 additions & 5 deletions

File tree

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/regulator/raspberrypi,7inch-touchscreen-panel-regulator-v2.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: RaspberryPi 5" and 7" display V2 MCU-based regulator/backlight controller
8+
9+
maintainers:
10+
- Marek Vasut <marek.vasut+renesas@mailbox.org>
11+
12+
description: |
13+
The RaspberryPi 5" and 7" display 2 has an MCU-based regulator, PWM
14+
backlight and GPIO controller on the PCB, which is used to turn the
15+
display unit on/off and control the backlight.
16+
17+
allOf:
18+
- $ref: regulator.yaml#
19+
20+
properties:
21+
compatible:
22+
const: raspberrypi,touchscreen-panel-regulator-v2
23+
24+
reg:
25+
maxItems: 1
26+
27+
gpio-controller: true
28+
"#gpio-cells":
29+
const: 2
30+
description:
31+
The first cell is the pin number, and the second cell is used to
32+
specify the gpio polarity (GPIO_ACTIVE_HIGH or GPIO_ACTIVE_LOW).
33+
34+
"#pwm-cells":
35+
const: 3
36+
description: See ../../pwm/pwm.yaml for description of the cell formats.
37+
38+
additionalProperties: false
39+
40+
required:
41+
- compatible
42+
- reg
43+
- gpio-controller
44+
- "#gpio-cells"
45+
- "#pwm-cells"
46+
47+
examples:
48+
- |
49+
i2c {
50+
#address-cells = <1>;
51+
#size-cells = <0>;
52+
regulator@45 {
53+
compatible = "raspberrypi,touchscreen-panel-regulator-v2";
54+
reg = <0x45>;
55+
gpio-controller;
56+
#gpio-cells = <2>;
57+
#pwm-cells = <3>;
58+
};
59+
};
60+
61+
...

Documentation/devicetree/bindings/regulator/raspberrypi,7inch-touchscreen-panel-regulator.yaml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,14 @@ maintainers:
1212
description: |
1313
The RaspberryPi 7" display has an ATTINY88-based regulator/backlight
1414
controller on the PCB, which is used to turn the display unit on/off
15-
and control the backlight. The V2 supports 5" and 7" panels and also
16-
offers PWM backlight control.
15+
and control the backlight.
1716
1817
allOf:
1918
- $ref: regulator.yaml#
2019

2120
properties:
2221
compatible:
23-
enum:
24-
- raspberrypi,7inch-touchscreen-panel-regulator
25-
- raspberrypi,touchscreen-panel-regulator-v2
22+
const: raspberrypi,7inch-touchscreen-panel-regulator
2623

2724
reg:
2825
maxItems: 1

0 commit comments

Comments
 (0)