32ada6b098
Properties with standard unit suffixes already have a type and don't need type definitions. They also default to a single entry, so 'maxItems: 1' can be dropped. adi,ad5758 is an oddball which defined an enum of arrays. While a valid schema, it is simpler as a whole to only define scalar constraints. Cc: Jean Delvare <jdelvare@suse.com> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com> Cc: Ulf Hansson <ulf.hansson@linaro.org> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jakub Kicinski <kuba@kernel.org> Cc: Serge Semin <fancer.lancer@gmail.com> Cc: linux-hwmon@vger.kernel.org Cc: linux-i2c@vger.kernel.org Cc: linux-iio@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-input@vger.kernel.org Cc: linux-mmc@vger.kernel.org Cc: netdev@vger.kernel.org Cc: linux-pm@vger.kernel.org Cc: linux-rtc@vger.kernel.org Cc: linux-serial@vger.kernel.org Cc: alsa-devel@alsa-project.org Cc: linux-watchdog@vger.kernel.org Signed-off-by: Rob Herring <robh@kernel.org> Acked-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Mark Brown <broonie@kernel.org> Acked-by: Wolfram Sang <wsa@kernel.org> # for I2C Acked-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Acked-by: Sebastian Reichel <sre@kernel.org> # for power-supply Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> #for-iio Acked-by: Alexandre TORGUE <alexandre.torgue@foss.st.com> Link: https://lore.kernel.org/r/20210128194515.743252-1-robh@kernel.org
138 lines
3.5 KiB
YAML
138 lines
3.5 KiB
YAML
# SPDX-License-Identifier: GPL-2.0
|
|
%YAML 1.2
|
|
---
|
|
$id: http://devicetree.org/schemas/regulator/fixed-regulator.yaml#
|
|
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
|
|
|
title: Fixed Voltage regulators
|
|
|
|
maintainers:
|
|
- Liam Girdwood <lgirdwood@gmail.com>
|
|
- Mark Brown <broonie@kernel.org>
|
|
|
|
description:
|
|
Any property defined as part of the core regulator binding, defined in
|
|
regulator.yaml, can also be used. However a fixed voltage regulator is
|
|
expected to have the regulator-min-microvolt and regulator-max-microvolt
|
|
to be the same.
|
|
|
|
allOf:
|
|
- $ref: "regulator.yaml#"
|
|
|
|
if:
|
|
properties:
|
|
compatible:
|
|
contains:
|
|
const: regulator-fixed-clock
|
|
required:
|
|
- clocks
|
|
else:
|
|
if:
|
|
properties:
|
|
compatible:
|
|
contains:
|
|
const: regulator-fixed-domain
|
|
required:
|
|
- power-domains
|
|
- required-opps
|
|
|
|
properties:
|
|
compatible:
|
|
enum:
|
|
- regulator-fixed
|
|
- regulator-fixed-clock
|
|
- regulator-fixed-domain
|
|
|
|
regulator-name: true
|
|
|
|
gpio:
|
|
description: gpio to use for enable control
|
|
maxItems: 1
|
|
|
|
clocks:
|
|
description:
|
|
clock to use for enable control. This binding is only available if
|
|
the compatible is chosen to regulator-fixed-clock. The clock binding
|
|
is mandatory if compatible is chosen to regulator-fixed-clock.
|
|
maxItems: 1
|
|
|
|
power-domains:
|
|
description:
|
|
Power domain to use for enable control. This binding is only
|
|
available if the compatible is chosen to regulator-fixed-domain.
|
|
maxItems: 1
|
|
|
|
required-opps:
|
|
description:
|
|
Performance state to use for enable control. This binding is only
|
|
available if the compatible is chosen to regulator-fixed-domain. The
|
|
power-domain binding is mandatory if compatible is chosen to
|
|
regulator-fixed-domain.
|
|
maxItems: 1
|
|
|
|
startup-delay-us:
|
|
description: startup time in microseconds
|
|
|
|
off-on-delay-us:
|
|
description: off delay time in microseconds
|
|
|
|
enable-active-high:
|
|
description:
|
|
Polarity of GPIO is Active high. If this property is missing,
|
|
the default assumed is Active low.
|
|
type: boolean
|
|
|
|
gpio-open-drain:
|
|
description:
|
|
GPIO is open drain type. If this property is missing then default
|
|
assumption is false.
|
|
type: boolean
|
|
|
|
vin-supply:
|
|
description: Input supply phandle.
|
|
|
|
required:
|
|
- compatible
|
|
- regulator-name
|
|
|
|
unevaluatedProperties: false
|
|
|
|
examples:
|
|
- |
|
|
reg_1v8: regulator-1v8 {
|
|
compatible = "regulator-fixed";
|
|
regulator-name = "1v8";
|
|
regulator-min-microvolt = <1800000>;
|
|
regulator-max-microvolt = <1800000>;
|
|
gpio = <&gpio1 16 0>;
|
|
startup-delay-us = <70000>;
|
|
enable-active-high;
|
|
regulator-boot-on;
|
|
gpio-open-drain;
|
|
vin-supply = <&parent_reg>;
|
|
};
|
|
reg_1v8_clk: regulator-1v8-clk {
|
|
compatible = "regulator-fixed-clock";
|
|
regulator-name = "1v8";
|
|
regulator-min-microvolt = <1800000>;
|
|
regulator-max-microvolt = <1800000>;
|
|
clocks = <&clock1>;
|
|
startup-delay-us = <70000>;
|
|
enable-active-high;
|
|
regulator-boot-on;
|
|
vin-supply = <&parent_reg>;
|
|
};
|
|
reg_1v8_domain: regulator-1v8-domain {
|
|
compatible = "regulator-fixed-domain";
|
|
regulator-name = "1v8";
|
|
regulator-min-microvolt = <1800000>;
|
|
regulator-max-microvolt = <1800000>;
|
|
power-domains = <&domain1>;
|
|
required-opps = <&domain1_state1>;
|
|
startup-delay-us = <70000>;
|
|
enable-active-high;
|
|
regulator-boot-on;
|
|
vin-supply = <&parent_reg>;
|
|
};
|
|
...
|