Message ID | 20230221183211.21964-9-clamor95@gmail.com |
---|---|
State | New |
Headers | show |
Series | Fix sound on ASUS Transformers | expand |
On Tue, Feb 21, 2023 at 08:32:09PM +0200, Svyatoslav Ryhel wrote: > Add dt-binding for Fortemedia FM34NE DSP. > > Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com> > --- > .../bindings/dsp/fortemedia,dsp.yaml | 95 +++++++++++++++++++ > 1 file changed, 95 insertions(+) > create mode 100644 Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml > > diff --git a/Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml b/Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml > new file mode 100644 > index 000000000000..78f30969d9bf > --- /dev/null > +++ b/Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml > @@ -0,0 +1,95 @@ > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/dsp/fortemedia,dsp.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Fortemedia DSP core > + > +maintainers: > + - Svyatoslav Ryhel <clamor95@gmail.com> > + > +description: | Don't need '|' > + Asus Transformer T20/T30 tablet family contains a DSP core > + used for advanced noise cancellation. > + > +properties: > + compatible: > + items: > + - enum: > + - asus,tf101-dsp > + - asus,tf201-dsp > + - asus,tf300t-dsp > + - asus,tf700t-dsp > + - pegatron,chagall-dsp > + Drop blank line. > + - const: fortemedia,fm34 > + > + reg: > + maxItems: 1 > + > + bypass-gpios: Needs a description what this is. > + maxItems: 1 > + > + reset-gpios: > + maxItems: 1 > + > + vdd-supply: true > + > + clocks: > + maxItems: 1 > + > + clock-names: > + items: > + - const: mclk > + > + assigned-clocks: > + maxItems: 1 > + > + assigned-clock-parents: > + maxItems: 1 > + > + assigned-clock-rates: > + maxItems: 1 > + > +required: > + - compatible > + - reg > + - vdd-supply > + > +additionalProperties: false > + > +examples: > + - | > + #include <dt-bindings/clock/tegra30-car.h> > + #include <dt-bindings/soc/tegra-pmc.h> > + > + i2c { > + #address-cells = <1>; > + #size-cells = <0>; > + > + dsp@60 { > + compatible = "asus,tf201-dsp", "fortemedia,fm34"; > + reg = <0x60>; > + > + bypass-gpios = <&gpio 222 0>; > + reset-gpios = <&gpio 115 1>; > + > + vdd-supply = <&vdd_1v8_dsp>; > + > + clocks = <&tegra_pmc TEGRA_PMC_CLK_OUT_1>; > + clock-names = "mclk"; > + > + assigned-clocks = <&tegra_pmc TEGRA_PMC_CLK_OUT_1>; > + assigned-clock-parents = <&tegra_car TEGRA30_CLK_EXTERN1>; > + }; > + }; > + > + vdd_1v8_dsp: regulator-dsp { > + compatible = "regulator-fixed"; > + regulator-name = "vdd_1v8_dsp"; > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + gpio = <&gpio 165 0>; > + enable-active-high; > + }; Drop this node. No need to show providers in consumer examples. Rob
diff --git a/Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml b/Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml new file mode 100644 index 000000000000..78f30969d9bf --- /dev/null +++ b/Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml @@ -0,0 +1,95 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/dsp/fortemedia,dsp.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Fortemedia DSP core + +maintainers: + - Svyatoslav Ryhel <clamor95@gmail.com> + +description: | + Asus Transformer T20/T30 tablet family contains a DSP core + used for advanced noise cancellation. + +properties: + compatible: + items: + - enum: + - asus,tf101-dsp + - asus,tf201-dsp + - asus,tf300t-dsp + - asus,tf700t-dsp + - pegatron,chagall-dsp + + - const: fortemedia,fm34 + + reg: + maxItems: 1 + + bypass-gpios: + maxItems: 1 + + reset-gpios: + maxItems: 1 + + vdd-supply: true + + clocks: + maxItems: 1 + + clock-names: + items: + - const: mclk + + assigned-clocks: + maxItems: 1 + + assigned-clock-parents: + maxItems: 1 + + assigned-clock-rates: + maxItems: 1 + +required: + - compatible + - reg + - vdd-supply + +additionalProperties: false + +examples: + - | + #include <dt-bindings/clock/tegra30-car.h> + #include <dt-bindings/soc/tegra-pmc.h> + + i2c { + #address-cells = <1>; + #size-cells = <0>; + + dsp@60 { + compatible = "asus,tf201-dsp", "fortemedia,fm34"; + reg = <0x60>; + + bypass-gpios = <&gpio 222 0>; + reset-gpios = <&gpio 115 1>; + + vdd-supply = <&vdd_1v8_dsp>; + + clocks = <&tegra_pmc TEGRA_PMC_CLK_OUT_1>; + clock-names = "mclk"; + + assigned-clocks = <&tegra_pmc TEGRA_PMC_CLK_OUT_1>; + assigned-clock-parents = <&tegra_car TEGRA30_CLK_EXTERN1>; + }; + }; + + vdd_1v8_dsp: regulator-dsp { + compatible = "regulator-fixed"; + regulator-name = "vdd_1v8_dsp"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + gpio = <&gpio 165 0>; + enable-active-high; + };
Add dt-binding for Fortemedia FM34NE DSP. Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com> --- .../bindings/dsp/fortemedia,dsp.yaml | 95 +++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 Documentation/devicetree/bindings/dsp/fortemedia,dsp.yaml