Devicetree
 help / color / mirror / Atom feed
From: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
To: Loic Poulain <loic.poulain@oss.qualcomm.com>
Cc: andersson@kernel.org, konradybcio@kernel.org, robh@kernel.org,
	krzk+dt@kernel.org, conor+dt@kernel.org,
	linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] arm64: dts: qcom: monaco-arduino-monza: Add overlay for Waveshare WM8960 Audio HAT
Date: Wed, 8 Jul 2026 14:30:16 +0100	[thread overview]
Message-ID: <2fbf3481-0f46-4942-8273-7f6d827c2b15@oss.qualcomm.com> (raw)
In-Reply-To: <CAFEp6-1VVmF-hrpPf34bFiYGOaa2HU9Pcvupt14MCjvW2-4VAA@mail.gmail.com>

On 7/8/26 1:33 PM, Loic Poulain wrote:
> Hi Srini,
> 
> On Tue, Jul 7, 2026 at 6:37 PM Srinivas Kandagatla
> <srinivas.kandagatla@oss.qualcomm.com> wrote:
>>
>> Add a DT overlay for the Waveshare WM8960 Audio HAT connected to the
>> 40-pin JHAT connector. The overlay adds the WM8960 fixed MCLK clock,
>> the WM8960 codec on I2C0, and the corresponding I2S1 playback and
>> capture DAI links to the sound card.
> 
> Looks like this hat also features a button on P11 (gpio85)?
> So it would be good to extend gpio-keys in that overlay.
> In that context, maybe assigning KEY_NEXTSONG or KEY_PLAYPAUSE?
> 

good point, We could add this, interestingly Rpi does nothing with this.
Will add this in v2 as PLAYPAUSE button.


--srini
> 
>>
>> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
>> ---
>>  arch/arm64/boot/dts/qcom/Makefile             |   4 +
>>  ...uino-monza-waveshare-wm8960-audio-hat.dtso | 100 ++++++++++++++++++
>>  2 files changed, 104 insertions(+)
>>  create mode 100644 arch/arm64/boot/dts/qcom/monaco-arduino-monza-waveshare-wm8960-audio-hat.dtso
>>
>> diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile
>> index 5a1c56cf98f6..27cce61893ad 100644
>> --- a/arch/arm64/boot/dts/qcom/Makefile
>> +++ b/arch/arm64/boot/dts/qcom/Makefile
>> @@ -59,6 +59,10 @@ dtb-$(CONFIG_ARCH_QCOM)      += mahua-crd.dtb
>>  dtb-$(CONFIG_ARCH_QCOM)        += milos-fairphone-fp6.dtb
>>  dtb-$(CONFIG_ARCH_QCOM)        += milos-nothing-asteroids.dtb
>>  dtb-$(CONFIG_ARCH_QCOM)        += monaco-arduino-monza.dtb
>> +
>> +monaco-arduino-monza-waveshare-wm8960-audio-hat-dtbs   := monaco-arduino-monza.dtb monaco-arduino-monza-waveshare-wm8960-audio-hat.dtbo
>> +dtb-$(CONFIG_ARCH_QCOM)        += monaco-arduino-monza-waveshare-wm8960-audio-hat.dtb
>> +
>>  dtb-$(CONFIG_ARCH_QCOM)        += monaco-evk.dtb
>>
>>  monaco-evk-camera-imx577-dtbs  := monaco-evk.dtb monaco-evk-camera-imx577.dtbo
>> diff --git a/arch/arm64/boot/dts/qcom/monaco-arduino-monza-waveshare-wm8960-audio-hat.dtso b/arch/arm64/boot/dts/qcom/monaco-arduino-monza-waveshare-wm8960-audio-hat.dtso
>> new file mode 100644
>> index 000000000000..cf7b6a220bab
>> --- /dev/null
>> +++ b/arch/arm64/boot/dts/qcom/monaco-arduino-monza-waveshare-wm8960-audio-hat.dtso
>> @@ -0,0 +1,100 @@
>> +// SPDX-License-Identifier: BSD-3-Clause
>> +/*
>> + * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
>> + *
>> + * Device tree overlay for the Waveshare WM8960 Audio HAT connected to the
>> + * Arduino Monza 40-pin JHAT connector.
>> + */
>> +
>> +/dts-v1/;
>> +/plugin/;
>> +
>> +#include <dt-bindings/sound/qcom,q6dsp-lpass-ports.h>
>> +
>> +&{/} {
>> +       /* on board fixed crystal */
>> +       wm8960_mclk: wm8960-mclk {
>> +               compatible = "fixed-clock";
>> +               clock-frequency = <12288000>;
>> +               #clock-cells = <0>;
>> +       };
>> +};
>> +
>> +&i2c0 {
>> +       clock-frequency = <400000>;
>> +       #address-cells = <1>;
>> +       #size-cells = <0>;
>> +
>> +       wm8960: audio-codec@1a {
>> +               compatible = "wlf,wm8960";
>> +               reg = <0x1a>;
>> +               clocks = <&wm8960_mclk>;
>> +               clock-names = "mclk";
>> +               AVDD-supply = <&vdc_3v3>;
>> +               SPKVDD1-supply = <&vdc_5v>;
>> +               SPKVDD2-supply = <&vdc_5v>;
>> +               #sound-dai-cells = <0>;
>> +       };
>> +};
>> +
>> +&lpass_tlmm {
>> +       lpi_i2s1_active: lpi-i2s1-active-state {
>> +               clk-pins {
>> +                       pins = "gpio6";
>> +                       function = "i2s1_clk";
>> +                       drive-strength = <8>;
>> +                       bias-disable;
>> +               };
>> +
>> +               ws-pins {
>> +                       pins = "gpio7";
>> +                       function = "i2s1_ws";
>> +                       drive-strength = <8>;
>> +                       bias-disable;
>> +               };
>> +
>> +               data-pins {
>> +                       pins = "gpio8", "gpio9";
>> +                       function = "i2s1_data";
>> +                       drive-strength = <8>;
>> +                       bias-disable;
>> +               };
>> +       };
>> +};
>> +
>> +&sound {
>> +       pinctrl-0 = <&quad_mi2s_active>, <&quad_mclk_active>, <&lpi_i2s4_active>,
>> +                   <&lpi_i2s1_active>;
>> +
>> +       i2s1-playback-dai-link {
>> +               link-name = "JHAT Analog Playback";
>> +
>> +               codec {
>> +                       sound-dai = <&wm8960>;
>> +               };
>> +
>> +               cpu {
>> +                       sound-dai = <&q6apmbedai LPI_MI2S_RX_1>;
>> +               };
>> +
>> +               platform {
>> +                       sound-dai = <&q6apm>;
>> +               };
>> +       };
>> +
>> +       i2s1-capture-dai-link {
>> +               link-name = "JHAT Analog Capture";
>> +
>> +               codec {
>> +                       sound-dai = <&wm8960>;
>> +               };
>> +
>> +               cpu {
>> +                       sound-dai = <&q6apmbedai LPI_MI2S_TX_1>;
>> +               };
>> +
>> +               platform {
>> +                       sound-dai = <&q6apm>;
>> +               };
>> +       };
>> +};
>> --
>> 2.53.0
>>


      reply	other threads:[~2026-07-08 13:30 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-07 16:37 [PATCH 0/3] arm64: dts: qcom: monaco-arduino-monza: Enable JHAT 40-pin HAT accessories Srinivas Kandagatla
2026-07-07 16:37 ` [PATCH 1/3] arm64: dts: qcom: monaco-arduino-monza: Enable I2C0 and SPI3 for 40-pin JHAT connector Srinivas Kandagatla
2026-07-07 18:11   ` Dmitry Baryshkov
2026-07-08  6:34   ` Loic Poulain
2026-07-08  7:01   ` Konrad Dybcio
2026-07-07 16:37 ` [PATCH 2/3] arm64: dts: qcom: monaco-arduino-monza: Add label to sound node Srinivas Kandagatla
2026-07-07 18:13   ` Dmitry Baryshkov
2026-07-07 16:37 ` [PATCH 3/3] arm64: dts: qcom: monaco-arduino-monza: Add overlay for Waveshare WM8960 Audio HAT Srinivas Kandagatla
2026-07-07 18:15   ` Dmitry Baryshkov
2026-07-07 20:41     ` Srinivas Kandagatla
2026-07-08  7:02       ` Konrad Dybcio
2026-07-08 12:33   ` Loic Poulain
2026-07-08 13:30     ` Srinivas Kandagatla [this message]

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=2fbf3481-0f46-4942-8273-7f6d827c2b15@oss.qualcomm.com \
    --to=srinivas.kandagatla@oss.qualcomm.com \
    --cc=andersson@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=konradybcio@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=loic.poulain@oss.qualcomm.com \
    --cc=robh@kernel.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