From: "Jiaxin Yu (俞家鑫)" <Jiaxin.Yu@mediatek.com>
To: "broonie@kernel.org" <broonie@kernel.org>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-mediatek@lists.infradead.org"
<linux-mediatek@lists.infradead.org>,
"ajye_huang@compal.corp-partner.google.com"
<ajye_huang@compal.corp-partner.google.com>,
"Chunxu Li (李春旭)" <Chunxu.Li@mediatek.com>,
"Allen-KH Cheng (程冠勲)" <Allen-KH.Cheng@mediatek.com>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>,
"kuninori.morimoto.gx@renesas.com"
<kuninori.morimoto.gx@renesas.com>,
"andrzej.hajda@intel.com" <andrzej.hajda@intel.com>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
Project_Global_Chrome_Upstream_Group
<Project_Global_Chrome_Upstream_Group@mediatek.com>,
"robert.foss@linaro.org" <robert.foss@linaro.org>,
"Laurent.pinchart@ideasonboard.com"
<Laurent.pinchart@ideasonboard.com>,
"neil.armstrong@linaro.org" <neil.armstrong@linaro.org>,
"AngeloGioacchino Del Regno"
<angelogioacchino.delregno@collabora.com>,
"Nicolas Prado" <nfraprado@collabora.com>,
"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>
Subject: Re: [PATCH v2 1/3] ASoC: hdmi-codec: Add event handler for hdmi TX
Date: Fri, 6 Dec 2024 15:39:15 +0000 [thread overview]
Message-ID: <b44319c9fabbea2e8c333191a0005ef5c4ec6b2c.camel@mediatek.com> (raw)
In-Reply-To: <00d5c728-3eb9-427a-bc60-5828c20fec09@sirena.org.uk>
On Mon, 2024-12-02 at 13:16 +0000, Mark Brown wrote:
> On Sun, Dec 01, 2024 at 05:15:45PM +0000, Jiaxin Yu (俞家鑫) wrote:
>
> > So I want to ask if I can do it by just adding
> > SOC_DAPM_PIN_SWITCH("Speakers") and SOC_DAPM_PIN_SWITCH("HDMI")?
> > Correspondingly, dapm widget and route path need to be added. That
> > is
> > "SND_SOC_DAPM_SPK("Speakers", NULL)/ SND_SOC_DAPM_LINE("HDMI1",
> > NULL)"
> > and "{"Speakers", NULL, "Speaker"}/ {"HDMI1", NULL, "TX"}".
>
> Yes, that's what I'd expect to see.
Dear Mark,
So if I open the "HDMI Switch" amixer control, it will call
'hdmi_codec_startup', which in turn calls "audio_startup()" in
'hdmi_codec_ops'. Conversely, if I close it, it will call
'hdmi_codec_shutdown', which in turn calls 'audio_shutdown' in
'hdmi_codec_ops'. Is this understanding correct?
static const struct snd_soc_dai_ops hdmi_codec_i2s_dai_ops = {
.probe = hdmi_dai_probe,
.startup = hdmi_codec_startup,
.shutdown = hdmi_codec_shutdown,
.hw_params = hdmi_codec_hw_params,
.prepare = hdmi_codec_prepare,
.set_fmt = hdmi_codec_i2s_set_fmt,
.mute_stream = hdmi_codec_mute,
.pcm_new = hdmi_codec_pcm_new,
.auto_selectable_formats = &hdmi_codec_formats,
.num_auto_selectable_formats = 1,
};
struct hdmi_codec_ops {
/*
* Called when ASoC starts an audio stream setup.
* Optional
*/
int (*audio_startup)(struct device *dev, void *data);
/*
* Shuts down the audio stream.
* Mandatory
*/
void (*audio_shutdown)(struct device *dev, void *data);
next prev parent reply other threads:[~2024-12-06 15:39 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-25 9:44 [PATCH v2 0/3] ASoC: mediatek:mt8186: fix both the speaker and hdmi Jiaxin Yu
2022-11-25 9:44 ` [PATCH v2 1/3] ASoC: hdmi-codec: Add event handler for hdmi TX Jiaxin Yu
2022-11-25 12:18 ` Mark Brown
2022-11-28 15:07 ` Jiaxin Yu (俞家鑫)
2022-11-29 17:22 ` Mark Brown
2022-12-01 15:06 ` Jiaxin Yu (俞家鑫)
2022-12-01 15:23 ` Mark Brown
2022-12-05 9:34 ` Jiaxin Yu (俞家鑫)
2022-12-05 12:07 ` Mark Brown
2022-12-13 14:23 ` Jiaxin Yu (俞家鑫)
2022-12-13 16:35 ` Mark Brown
2024-12-01 17:15 ` Jiaxin Yu (俞家鑫)
2024-12-02 13:16 ` Mark Brown
2024-12-06 15:39 ` Jiaxin Yu (俞家鑫) [this message]
2024-12-06 16:06 ` Mark Brown
2022-11-25 9:44 ` [PATCH v2 2/3] ASoC: mediatek: mt8186: correct the HDMI widgets Jiaxin Yu
2022-11-25 9:44 ` [PATCH v2 3/3] drm/bridge: it6505: Add audio support Jiaxin Yu
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=b44319c9fabbea2e8c333191a0005ef5c4ec6b2c.camel@mediatek.com \
--to=jiaxin.yu@mediatek.com \
--cc=Allen-KH.Cheng@mediatek.com \
--cc=Chunxu.Li@mediatek.com \
--cc=Laurent.pinchart@ideasonboard.com \
--cc=Project_Global_Chrome_Upstream_Group@mediatek.com \
--cc=ajye_huang@compal.corp-partner.google.com \
--cc=alsa-devel@alsa-project.org \
--cc=andrzej.hajda@intel.com \
--cc=angelogioacchino.delregno@collabora.com \
--cc=broonie@kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=kuninori.morimoto.gx@renesas.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=neil.armstrong@linaro.org \
--cc=nfraprado@collabora.com \
--cc=robert.foss@linaro.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
all inboxes | Powered by JetHome®