From: Macpaul Lin <macpaul.lin@mediatek.com>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>, Pavel Machek <pavel@ucw.cz>,
Lee Jones <lee@kernel.org>,
Matthias Brugger <matthias.bgg@gmail.com>,
"AngeloGioacchino Del Regno"
<angelogioacchino.delregno@collabora.com>,
Sen Chu <sen.chu@mediatek.com>,
Sean Wang <sean.wang@mediatek.com>,
Macpaul Lin <macpaul.lin@mediatek.com>,
Andrew Lunn <andrew@lunn.ch>,
Florian Fainelli <f.fainelli@gmail.com>,
Vladimir Oltean <olteanv@gmail.com>,
"David S . Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
"Jakub Kicinski" <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>,
"Sebastian Reichel" <sre@kernel.org>,
Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
<linux-input@vger.kernel.org>, <devicetree@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <linux-leds@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
<linux-mediatek@lists.infradead.org>, <linux-pm@vger.kernel.org>,
<netdev@vger.kernel.org>, <linux-rtc@vger.kernel.org>,
<linux-sound@vger.kernel.org>,
Alexandre Mergnat <amergnat@baylibre.com>
Cc: Bear Wang <bear.wang@mediatek.com>,
Pablo Sun <pablo.sun@mediatek.com>,
Macpaul Lin <macpaul@gmail.com>,
Chris-qj chen <chris-qj.chen@mediatek.com>,
MediaTek Chromebook Upstream
<Project_Global_Chrome_Upstream_Group@mediatek.com>,
Chen-Yu Tsai <wenst@chromium.org>
Subject: [PATCH v8 2/3] ASoC: dt-bindings: mt6358: Convert to DT Schema
Date: Tue, 1 Oct 2024 18:41:44 +0800 [thread overview]
Message-ID: <20241001104145.24054-2-macpaul.lin@mediatek.com> (raw)
In-Reply-To: <20241001104145.24054-1-macpaul.lin@mediatek.com>
Convert the MediaTek MT6358 Audio CODEC bindings to DT schema.
This change implements the following updates:
1. Compatible property: Added the const 'mediatek,mt6358-sound'
to ensure alignment with the schema in the actual (DTS) file
"mt8186-corsola.dtsi" with 'mediatek,mt6366-sound'.
2. Example: Removed the example section, as it should be relocated to
the MT6397 PMIC file 'mfd/mediatek,mt6397.yaml'.
3. Use filename 'mediatek,mt6358-sound.yaml' to align the compatible
name.
Signed-off-by: Macpaul Lin <macpaul.lin@mediatek.com>
---
.../bindings/sound/mediatek,mt6358-sound.yaml | 44 +++++++++++++++++++
.../devicetree/bindings/sound/mt6358.txt | 26 -----------
2 files changed, 44 insertions(+), 26 deletions(-)
create mode 100644 Documentation/devicetree/bindings/sound/mediatek,mt6358-sound.yaml
delete mode 100644 Documentation/devicetree/bindings/sound/mt6358.txt
Changess for v1~v6:
- It was not in the origin patch set.
Changes for v7:
- It is seperated from the origin patch set (2/2, v6).
It could simplifies the audio-codec node in next patch (3/3, v7)
of 'mfd/mediatek,mt6397.yaml'
Changes for v8:
- Update compatible property with 'oneOf:' and 'items' syntax.
Thanks for the suggestion.
- Replace 'mt6358.yaml' with 'mediatek,mt6358-sound.yaml' to align
the compatible name.
diff --git a/Documentation/devicetree/bindings/sound/mediatek,mt6358-sound.yaml b/Documentation/devicetree/bindings/sound/mediatek,mt6358-sound.yaml
new file mode 100644
index 000000000000..36eb111f5746
--- /dev/null
+++ b/Documentation/devicetree/bindings/sound/mediatek,mt6358-sound.yaml
@@ -0,0 +1,44 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/sound/mediatek,mt6358-sound.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Mediatek MT6358 Audio Codec
+
+maintainers:
+ - Jiaxin Yu <jiaxin.yu@mediatek.com>
+ - Macpaul Lin <macpaul.lin@mediatek.com>
+
+description: |
+ The communication between MT6358 and SoC is through Mediatek PMIC wrapper.
+ For more detail, please visit Mediatek PMIC wrapper documentation.
+ Must be a child node of PMIC wrapper.
+
+properties:
+ compatible:
+ oneOf:
+ - enum:
+ - mediatek,mt6358-sound
+ - items:
+ - enum:
+ - mediatek,mt6366-sound
+ - const: mediatek,mt6358-sound
+
+ Avdd-supply:
+ description: Power source of AVDD
+
+ mediatek,dmic-mode:
+ $ref: /schemas/types.yaml#/definitions/uint32
+ description: |
+ Indicates how many data pins are used to transmit two channels of PDM
+ signal. 0 means two wires, 1 means one wire. Default value is 0.
+ enum:
+ - 0 # two wires
+ - 1 # one wire
+
+required:
+ - compatible
+ - Avdd-supply
+
+additionalProperties: false
diff --git a/Documentation/devicetree/bindings/sound/mt6358.txt b/Documentation/devicetree/bindings/sound/mt6358.txt
deleted file mode 100644
index fbe9e55c68f5..000000000000
--- a/Documentation/devicetree/bindings/sound/mt6358.txt
+++ /dev/null
@@ -1,26 +0,0 @@
-Mediatek MT6358 Audio Codec
-
-The communication between MT6358 and SoC is through Mediatek PMIC wrapper.
-For more detail, please visit Mediatek PMIC wrapper documentation.
-
-Must be a child node of PMIC wrapper.
-
-Required properties:
-
-- compatible - "string" - One of:
- "mediatek,mt6358-sound"
- "mediatek,mt6366-sound"
-- Avdd-supply : power source of AVDD
-
-Optional properties:
-- mediatek,dmic-mode : Indicates how many data pins are used to transmit two
- channels of PDM signal. 0 means two wires, 1 means one wire. Default
- value is 0.
-
-Example:
-
-mt6358_snd {
- compatible = "mediatek,mt6358-sound";
- Avdd-supply = <&mt6358_vaud28_reg>;
- mediatek,dmic-mode = <0>;
-};
--
2.45.2
next prev parent reply other threads:[~2024-10-01 10:42 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-01 10:41 [PATCH v8 1/3] regulator: dt-bindings: mt6323: Convert to DT schema Macpaul Lin
2024-10-01 10:41 ` Macpaul Lin [this message]
2024-10-02 5:58 ` [PATCH v8 2/3] ASoC: dt-bindings: mt6358: Convert to DT Schema Krzysztof Kozlowski
2024-10-01 10:41 ` [PATCH v8 3/3] dt-bindings: mfd: mediatek: mt6397: Convert to DT schema format Macpaul Lin
2024-10-02 6:00 ` Krzysztof Kozlowski
2024-10-09 15:52 ` Lee Jones
2024-10-15 20:31 ` Sebastian Reichel
2024-10-16 7:58 ` Lee Jones
2024-10-16 8:01 ` (subset) " Lee Jones
2024-10-16 8:02 ` Lee Jones
2024-10-01 15:26 ` [PATCH v8 1/3] regulator: dt-bindings: mt6323: Convert to DT schema AngeloGioacchino Del Regno
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241001104145.24054-2-macpaul.lin@mediatek.com \
--to=macpaul.lin@mediatek.com \
--cc=Project_Global_Chrome_Upstream_Group@mediatek.com \
--cc=alexandre.belloni@bootlin.com \
--cc=amergnat@baylibre.com \
--cc=andrew@lunn.ch \
--cc=angelogioacchino.delregno@collabora.com \
--cc=bear.wang@mediatek.com \
--cc=broonie@kernel.org \
--cc=chris-qj.chen@mediatek.com \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=edumazet@google.com \
--cc=f.fainelli@gmail.com \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=lee@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-leds@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux-rtc@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=macpaul@gmail.com \
--cc=matthias.bgg@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=olteanv@gmail.com \
--cc=pabeni@redhat.com \
--cc=pablo.sun@mediatek.com \
--cc=pavel@ucw.cz \
--cc=robh@kernel.org \
--cc=sean.wang@mediatek.com \
--cc=sen.chu@mediatek.com \
--cc=sre@kernel.org \
--cc=wenst@chromium.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).