alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec
@ 2022-10-03  3:24 Doug Brown
  2022-10-03  3:24 ` [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961 Doug Brown
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Doug Brown @ 2022-10-03  3:24 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown
  Cc: devicetree, alsa-devel, Doug Brown, patches, Takashi Iwai,
	Rob Herring, Krzysztof Kozlowski

This series adds devicetree support for the Wolfson WM8961 codec. The
first patch adds a schema, the second patch hooks it up in the code, and
the third patch allows it to be selected in Kconfig.

Changes since v1:
- Fix ordering of property lists and example in schema
- Fix wording of commit message
- Fix unused variable warning
- Split Kconfig change to separate commit

Doug Brown (3):
  ASoC: dt-bindings: add schema for WM8961
  ASoC: wm8961: add support for devicetree
  ASoC: codecs: allow WM8961 to be selected by the user

 .../devicetree/bindings/sound/wlf,wm8961.yaml | 40 +++++++++++++++++++
 sound/soc/codecs/Kconfig                      |  2 +-
 sound/soc/codecs/wm8961.c                     |  7 ++++
 3 files changed, 48 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/devicetree/bindings/sound/wlf,wm8961.yaml

-- 
2.34.1


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961
  2022-10-03  3:24 [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Doug Brown
@ 2022-10-03  3:24 ` Doug Brown
  2022-10-03  7:47   ` Krzysztof Kozlowski
  2022-10-03 10:11   ` Charles Keepax
  2022-10-03  3:24 ` [PATCH v2 2/3] ASoC: wm8961: add support for devicetree Doug Brown
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 9+ messages in thread
From: Doug Brown @ 2022-10-03  3:24 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown
  Cc: devicetree, alsa-devel, Doug Brown, patches, Takashi Iwai,
	Rob Herring, Krzysztof Kozlowski

Create a simple DT schema for the existing Wolfson WM8961 driver so that
DT support can be added to the driver.

Signed-off-by: Doug Brown <doug@schmorgal.com>
---
 .../devicetree/bindings/sound/wlf,wm8961.yaml | 40 +++++++++++++++++++
 1 file changed, 40 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/sound/wlf,wm8961.yaml

diff --git a/Documentation/devicetree/bindings/sound/wlf,wm8961.yaml b/Documentation/devicetree/bindings/sound/wlf,wm8961.yaml
new file mode 100644
index 000000000000..795d34e1e97a
--- /dev/null
+++ b/Documentation/devicetree/bindings/sound/wlf,wm8961.yaml
@@ -0,0 +1,40 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/sound/wlf,wm8961.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Wolfson WM8961 Ultra-Low Power Stereo CODEC
+
+maintainers:
+  - patches@opensource.cirrus.com
+
+properties:
+  compatible:
+    const: wlf,wm8961
+
+  reg:
+    maxItems: 1
+
+  '#sound-dai-cells':
+    const: 0
+
+required:
+  - compatible
+  - reg
+  - '#sound-dai-cells'
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+          #address-cells = <1>;
+          #size-cells = <0>;
+
+          wm8961: codec@4a {
+                  compatible = "wlf,wm8961";
+                  reg = <0x4a>;
+                  #sound-dai-cells = <0>;
+          };
+    };
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH v2 2/3] ASoC: wm8961: add support for devicetree
  2022-10-03  3:24 [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Doug Brown
  2022-10-03  3:24 ` [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961 Doug Brown
@ 2022-10-03  3:24 ` Doug Brown
  2022-10-03 10:11   ` Charles Keepax
  2022-10-03  3:24 ` [PATCH v2 3/3] ASoC: codecs: allow WM8961 to be selected by the user Doug Brown
  2022-10-18 12:13 ` [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Mark Brown
  3 siblings, 1 reply; 9+ messages in thread
From: Doug Brown @ 2022-10-03  3:24 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown
  Cc: devicetree, alsa-devel, Doug Brown, patches, Takashi Iwai,
	Rob Herring, Krzysztof Kozlowski

Add support for devicetree to the WM8961 driver so it can be used with
modern DT-based kernels.

Signed-off-by: Doug Brown <doug@schmorgal.com>
---
 sound/soc/codecs/wm8961.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/sound/soc/codecs/wm8961.c b/sound/soc/codecs/wm8961.c
index 7dc6aaf65576..a4857024711d 100644
--- a/sound/soc/codecs/wm8961.c
+++ b/sound/soc/codecs/wm8961.c
@@ -971,9 +971,16 @@ static const struct i2c_device_id wm8961_i2c_id[] = {
 };
 MODULE_DEVICE_TABLE(i2c, wm8961_i2c_id);
 
+static const struct of_device_id wm8961_of_match[] __maybe_unused = {
+	{ .compatible = "wlf,wm8961", },
+	{ }
+};
+MODULE_DEVICE_TABLE(of, wm8961_of_match);
+
 static struct i2c_driver wm8961_i2c_driver = {
 	.driver = {
 		.name = "wm8961",
+		.of_match_table = of_match_ptr(wm8961_of_match),
 	},
 	.probe_new = wm8961_i2c_probe,
 	.id_table = wm8961_i2c_id,
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH v2 3/3] ASoC: codecs: allow WM8961 to be selected by the user
  2022-10-03  3:24 [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Doug Brown
  2022-10-03  3:24 ` [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961 Doug Brown
  2022-10-03  3:24 ` [PATCH v2 2/3] ASoC: wm8961: add support for devicetree Doug Brown
@ 2022-10-03  3:24 ` Doug Brown
  2022-10-03 10:12   ` Charles Keepax
  2022-10-18 12:13 ` [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Mark Brown
  3 siblings, 1 reply; 9+ messages in thread
From: Doug Brown @ 2022-10-03  3:24 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown
  Cc: devicetree, alsa-devel, Doug Brown, patches, Takashi Iwai,
	Rob Herring, Krzysztof Kozlowski

Allow the WM8961 driver to be enabled independently now that it is
usable with devicetree.

Signed-off-by: Doug Brown <doug@schmorgal.com>
---
 sound/soc/codecs/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig
index e3b90c425faf..2b5787ee8d31 100644
--- a/sound/soc/codecs/Kconfig
+++ b/sound/soc/codecs/Kconfig
@@ -1929,7 +1929,7 @@ config SND_SOC_WM8960
 	depends on I2C
 
 config SND_SOC_WM8961
-	tristate
+	tristate "Wolfson Microelectronics WM8961 CODEC"
 	depends on I2C
 
 config SND_SOC_WM8962
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961
  2022-10-03  3:24 ` [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961 Doug Brown
@ 2022-10-03  7:47   ` Krzysztof Kozlowski
  2022-10-03 10:11   ` Charles Keepax
  1 sibling, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2022-10-03  7:47 UTC (permalink / raw)
  To: Doug Brown, Liam Girdwood, Mark Brown
  Cc: devicetree, alsa-devel, patches, Takashi Iwai, Rob Herring,
	Krzysztof Kozlowski

On 03/10/2022 05:24, Doug Brown wrote:
> Create a simple DT schema for the existing Wolfson WM8961 driver so that
> DT support can be added to the driver.
> 
> Signed-off-by: Doug Brown <doug@schmorgal.com>
> ---


Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961
  2022-10-03  3:24 ` [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961 Doug Brown
  2022-10-03  7:47   ` Krzysztof Kozlowski
@ 2022-10-03 10:11   ` Charles Keepax
  1 sibling, 0 replies; 9+ messages in thread
From: Charles Keepax @ 2022-10-03 10:11 UTC (permalink / raw)
  To: Doug Brown
  Cc: devicetree, alsa-devel, patches, Takashi Iwai, Rob Herring,
	Liam Girdwood, Mark Brown, Krzysztof Kozlowski

On Sun, Oct 02, 2022 at 08:24:12PM -0700, Doug Brown wrote:
> Create a simple DT schema for the existing Wolfson WM8961 driver so that
> DT support can be added to the driver.
> 
> Signed-off-by: Doug Brown <doug@schmorgal.com>
> ---

Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com>

Thanks,
Charles

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH v2 2/3] ASoC: wm8961: add support for devicetree
  2022-10-03  3:24 ` [PATCH v2 2/3] ASoC: wm8961: add support for devicetree Doug Brown
@ 2022-10-03 10:11   ` Charles Keepax
  0 siblings, 0 replies; 9+ messages in thread
From: Charles Keepax @ 2022-10-03 10:11 UTC (permalink / raw)
  To: Doug Brown
  Cc: devicetree, alsa-devel, patches, Takashi Iwai, Rob Herring,
	Liam Girdwood, Mark Brown, Krzysztof Kozlowski

On Sun, Oct 02, 2022 at 08:24:13PM -0700, Doug Brown wrote:
> Add support for devicetree to the WM8961 driver so it can be used with
> modern DT-based kernels.
> 
> Signed-off-by: Doug Brown <doug@schmorgal.com>
> ---

Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com>

Thanks,
Charles

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH v2 3/3] ASoC: codecs: allow WM8961 to be selected by the user
  2022-10-03  3:24 ` [PATCH v2 3/3] ASoC: codecs: allow WM8961 to be selected by the user Doug Brown
@ 2022-10-03 10:12   ` Charles Keepax
  0 siblings, 0 replies; 9+ messages in thread
From: Charles Keepax @ 2022-10-03 10:12 UTC (permalink / raw)
  To: Doug Brown
  Cc: devicetree, alsa-devel, patches, Takashi Iwai, Rob Herring,
	Liam Girdwood, Mark Brown, Krzysztof Kozlowski

On Sun, Oct 02, 2022 at 08:24:14PM -0700, Doug Brown wrote:
> Allow the WM8961 driver to be enabled independently now that it is
> usable with devicetree.
> 
> Signed-off-by: Doug Brown <doug@schmorgal.com>
> ---

Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com>

Thanks,
Charles

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec
  2022-10-03  3:24 [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Doug Brown
                   ` (2 preceding siblings ...)
  2022-10-03  3:24 ` [PATCH v2 3/3] ASoC: codecs: allow WM8961 to be selected by the user Doug Brown
@ 2022-10-18 12:13 ` Mark Brown
  3 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2022-10-18 12:13 UTC (permalink / raw)
  To: Doug Brown, Liam Girdwood
  Cc: devicetree, alsa-devel, patches, Takashi Iwai, Rob Herring,
	Krzysztof Kozlowski

On Sun, 2 Oct 2022 20:24:11 -0700, Doug Brown wrote:
> This series adds devicetree support for the Wolfson WM8961 codec. The
> first patch adds a schema, the second patch hooks it up in the code, and
> the third patch allows it to be selected in Kconfig.
> 
> Changes since v1:
> - Fix ordering of property lists and example in schema
> - Fix wording of commit message
> - Fix unused variable warning
> - Split Kconfig change to separate commit
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/3] ASoC: dt-bindings: add schema for WM8961
      commit: b9b0d88d87e5565e8d12bcf22ec601e8b4658dc6
[2/3] ASoC: wm8961: add support for devicetree
      commit: c96851ee8195c820b765c6a7effcec79c81eb9c6
[3/3] ASoC: codecs: allow WM8961 to be selected by the user
      commit: 74a6a948c8fc28c8937e24178739979b3cd2ce14

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-10-18 12:15 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-03  3:24 [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Doug Brown
2022-10-03  3:24 ` [PATCH v2 1/3] ASoC: dt-bindings: add schema for WM8961 Doug Brown
2022-10-03  7:47   ` Krzysztof Kozlowski
2022-10-03 10:11   ` Charles Keepax
2022-10-03  3:24 ` [PATCH v2 2/3] ASoC: wm8961: add support for devicetree Doug Brown
2022-10-03 10:11   ` Charles Keepax
2022-10-03  3:24 ` [PATCH v2 3/3] ASoC: codecs: allow WM8961 to be selected by the user Doug Brown
2022-10-03 10:12   ` Charles Keepax
2022-10-18 12:13 ` [PATCH v2 0/3] ASoC: add devicetree support for WM8961 codec Mark Brown

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).