mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 12:44:03 +02:00
dt-bindings: leds: backlight: Convert TPS65217 to DT schema
Convert the Texas Instruments TPS65217 bindings to DT schema. During the conversion, the following updates were made: - Documented the 'regulators', 'charger' and 'pwrbutton' child nodes, which are used by the boards but were missing from the old txt binding. - Documented the 'interrupts', 'interrupt-controller', '#interrupt-cells' and 'ti,pmic-shutdown-controller' properties, which are used by the am335x boards and read by the driver. The regulator/tps65217.txt binding documented the same 'ti,tps65217' compatible and is superseded by this schema, so remove it as well. Signed-off-by: Eduard Bostina <egbostina@gmail.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com> Link: https://patch.msgid.link/20260723100605.628882-5-egbostina@gmail.com Signed-off-by: Lee Jones <lee@kernel.org>
This commit is contained in:
parent
8d6b6c05b8
commit
95231a9225
|
|
@ -0,0 +1,170 @@
|
|||
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
|
||||
%YAML 1.2
|
||||
---
|
||||
$id: http://devicetree.org/schemas/leds/backlight/ti,tps65217.yaml#
|
||||
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
||||
|
||||
title: TPS65217 family of regulators
|
||||
|
||||
maintainers:
|
||||
- Eduard Bostina <egbostina@gmail.com>
|
||||
|
||||
description:
|
||||
The TPS65217 chip contains a boost converter and current sinks which can be
|
||||
used to drive LEDs for use as backlights.
|
||||
|
||||
properties:
|
||||
compatible:
|
||||
const: ti,tps65217
|
||||
|
||||
reg:
|
||||
maxItems: 1
|
||||
description: I2C slave address
|
||||
|
||||
interrupts:
|
||||
maxItems: 1
|
||||
|
||||
interrupt-controller: true
|
||||
|
||||
"#interrupt-cells":
|
||||
const: 1
|
||||
|
||||
ti,pmic-shutdown-controller:
|
||||
type: boolean
|
||||
description:
|
||||
Set the PMIC to shutdown on PWR_EN toggle.
|
||||
|
||||
backlight:
|
||||
type: object
|
||||
additionalProperties: false
|
||||
description:
|
||||
Node for specifying WLED1 and WLED2 lines in TPS65217.
|
||||
|
||||
properties:
|
||||
isel:
|
||||
$ref: /schemas/types.yaml#/definitions/uint32
|
||||
enum: [1, 2]
|
||||
description: |
|
||||
Selection bit. Valid values:
|
||||
1 - ISEL1 (low-level)
|
||||
2 - ISEL2 (high-level)
|
||||
|
||||
fdim:
|
||||
$ref: /schemas/types.yaml#/definitions/uint32
|
||||
enum: [100, 200, 500, 1000]
|
||||
description:
|
||||
PWM dimming frequency in Hz.
|
||||
|
||||
default-brightness:
|
||||
$ref: /schemas/types.yaml#/definitions/uint32
|
||||
minimum: 0
|
||||
maximum: 100
|
||||
|
||||
required:
|
||||
- isel
|
||||
- fdim
|
||||
- default-brightness
|
||||
|
||||
regulators:
|
||||
type: object
|
||||
additionalProperties: false
|
||||
description:
|
||||
List of child nodes that specify the regulator initialization data.
|
||||
Not all regulators for the given device need to be present.
|
||||
|
||||
patternProperties:
|
||||
"^(dcdc[1-3]|ldo[1-4])$":
|
||||
type: object
|
||||
$ref: /schemas/regulator/regulator.yaml#
|
||||
unevaluatedProperties: false
|
||||
|
||||
charger:
|
||||
$ref: /schemas/power/supply/tps65217-charger.yaml#
|
||||
unevaluatedProperties: false
|
||||
|
||||
pwrbutton:
|
||||
$ref: /schemas/input/ti,tps65217-pwrbutton.yaml#
|
||||
unevaluatedProperties: false
|
||||
|
||||
required:
|
||||
- compatible
|
||||
- reg
|
||||
|
||||
additionalProperties: false
|
||||
|
||||
examples:
|
||||
- |
|
||||
i2c {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
pmic@24 {
|
||||
compatible = "ti,tps65217";
|
||||
reg = <0x24>;
|
||||
interrupt-controller;
|
||||
#interrupt-cells = <1>;
|
||||
ti,pmic-shutdown-controller;
|
||||
|
||||
backlight {
|
||||
isel = <1>; /* 1 - ISET1, 2 ISET2 */
|
||||
fdim = <100>; /* TPS65217_BL_FDIM_100HZ */
|
||||
default-brightness = <50>;
|
||||
};
|
||||
|
||||
charger {
|
||||
compatible = "ti,tps65217-charger";
|
||||
interrupts = <0>, <1>;
|
||||
interrupt-names = "USB", "AC";
|
||||
};
|
||||
|
||||
pwrbutton {
|
||||
compatible = "ti,tps65217-pwrbutton";
|
||||
interrupts = <2>;
|
||||
};
|
||||
|
||||
regulators {
|
||||
dcdc1 {
|
||||
regulator-name = "vdds_dpr";
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
dcdc2 {
|
||||
regulator-name = "vdd_mpu";
|
||||
regulator-min-microvolt = <925000>;
|
||||
regulator-max-microvolt = <1351500>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
dcdc3 {
|
||||
regulator-name = "vdd_core";
|
||||
regulator-min-microvolt = <925000>;
|
||||
regulator-max-microvolt = <1150000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo1 {
|
||||
regulator-name = "vio,vrtc,vdds";
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo2 {
|
||||
regulator-name = "vdd_3v3aux";
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo3 {
|
||||
regulator-name = "vdd_1v8";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo4 {
|
||||
regulator-name = "vdd_3v3a";
|
||||
regulator-always-on;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
@ -1,27 +0,0 @@
|
|||
TPS65217 family of regulators
|
||||
|
||||
The TPS65217 chip contains a boost converter and current sinks which can be
|
||||
used to drive LEDs for use as backlights.
|
||||
|
||||
Required properties:
|
||||
- compatible: "ti,tps65217"
|
||||
- reg: I2C slave address
|
||||
- backlight: node for specifying WLED1 and WLED2 lines in TPS65217
|
||||
- isel: selection bit, valid values: 1 for ISEL1 (low-level) and 2 for ISEL2 (high-level)
|
||||
- fdim: PWM dimming frequency, valid values: 100, 200, 500, 1000
|
||||
- default-brightness: valid values: 0-100
|
||||
|
||||
Each regulator is defined using the standard binding for regulators.
|
||||
|
||||
Example:
|
||||
|
||||
tps: tps@24 {
|
||||
reg = <0x24>;
|
||||
compatible = "ti,tps65217";
|
||||
backlight {
|
||||
isel = <1>; /* 1 - ISET1, 2 ISET2 */
|
||||
fdim = <100>; /* TPS65217_BL_FDIM_100HZ */
|
||||
default-brightness = <50>;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
@ -1,78 +0,0 @@
|
|||
TPS65217 family of regulators
|
||||
|
||||
Required properties:
|
||||
- compatible: "ti,tps65217"
|
||||
- reg: I2C slave address
|
||||
- regulators: list of regulators provided by this controller, must be named
|
||||
after their hardware counterparts: dcdc[1-3] and ldo[1-4]
|
||||
- regulators: This is the list of child nodes that specify the regulator
|
||||
initialization data for defined regulators. Not all regulators for the given
|
||||
device need to be present. The definition for each of these nodes is defined
|
||||
using the standard binding for regulators found at
|
||||
Documentation/devicetree/bindings/regulator/regulator.txt.
|
||||
|
||||
Optional properties:
|
||||
- ti,pmic-shutdown-controller: Telling the PMIC to shutdown on PWR_EN toggle.
|
||||
|
||||
The valid names for regulators are:
|
||||
tps65217: dcdc1, dcdc2, dcdc3, ldo1, ldo2, ldo3 and ldo4
|
||||
|
||||
Each regulator is defined using the standard binding for regulators.
|
||||
|
||||
Example:
|
||||
|
||||
tps: tps@24 {
|
||||
compatible = "ti,tps65217";
|
||||
ti,pmic-shutdown-controller;
|
||||
|
||||
regulators {
|
||||
dcdc1_reg: dcdc1 {
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
dcdc2_reg: dcdc2 {
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
dcdc3_reg: dcc3 {
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <1500000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo1_reg: ldo1 {
|
||||
regulator-min-microvolt = <1000000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo2_reg: ldo2 {
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo3_reg: ldo3 {
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo4_reg: ldo4 {
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
};
|
||||
};
|
||||
Loading…
Reference in New Issue
Block a user