From: Neil Armstrong <narmstrong@baylibre.com>
To: Cheng-Yi Chiang <cychiang@chromium.org>, linux-kernel@vger.kernel.org
Cc: alsa-devel@alsa-project.org, tzungbi@chromium.org,
zhengxing@rock-chips.com, kuninori.morimoto.gx@renesas.com,
a.hajda@samsung.com, airlied@linux.ie, jeffy.chen@rock-chips.com,
dianders@chromium.org, dri-devel@lists.freedesktop.org,
cain.cai@rock-chips.com, linux-rockchip@lists.infradead.org,
Jonas Karlman <jonas@kwiboo.se>,
eddie.cai@rock-chips.com, Laurent.pinchart@ideasonboard.com,
daniel@ffwll.ch, enric.balletbo@collabora.com,
dgreid@chromium.org, sam@ravnborg.org,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2] drm: dw-hdmi-i2s: enable audio clock in audio_startup
Date: Mon, 2 Sep 2019 11:42:38 +0200 [thread overview]
Message-ID: <241fd791-3792-34c8-ac35-a81a0a41070c@baylibre.com> (raw)
In-Reply-To: <20190902035435.44463-1-cychiang@chromium.org>
Hi,
On 02/09/2019 05:54, Cheng-Yi Chiang wrote:
> In the designware databook, the sequence of enabling audio clock and
> setting format is not clearly specified.
> Currently, audio clock is enabled in the end of hw_param ops after
> setting format.
>
> On some monitors, there is a possibility that audio does not come out.
> Fix this by enabling audio clock in audio_startup ops
> before hw_param ops setting format.
>
> Signed-off-by: Cheng-Yi Chiang <cychiang@chromium.org>
> Reviewed-by: Douglas Anderson <dianders@chromium.org>
> Reviewed-by: Jonas Karlman <jonas@kwiboo.se>
> Tested-by: Douglas Anderson <dianders@chromium.org>
> ---
> Changes from v1:
> 1. Move audio_startup to the front of audio_shutdown.
> 2. Fix the indentation of audio_startup equal sign using tab.
> 3. Rebase the patch on linux-next/master.
> 4. Add Reviewed-by and Tested-by fields from dianders@chromium.org.
> 5. Add Reviewed-by field from jonas@kwiboo.se.
>
> drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c
> index 1d15cf9b6821..34d8e837555f 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi-i2s-audio.c
> @@ -109,6 +109,14 @@ static int dw_hdmi_i2s_hw_params(struct device *dev, void *data,
> hdmi_write(audio, conf0, HDMI_AUD_CONF0);
> hdmi_write(audio, conf1, HDMI_AUD_CONF1);
>
> + return 0;
> +}
> +
> +static int dw_hdmi_i2s_audio_startup(struct device *dev, void *data)
> +{
> + struct dw_hdmi_i2s_audio_data *audio = data;
> + struct dw_hdmi *hdmi = audio->hdmi;
> +
> dw_hdmi_audio_enable(hdmi);
>
> return 0;
> @@ -153,6 +161,7 @@ static int dw_hdmi_i2s_get_dai_id(struct snd_soc_component *component,
>
> static struct hdmi_codec_ops dw_hdmi_i2s_ops = {
> .hw_params = dw_hdmi_i2s_hw_params,
> + .audio_startup = dw_hdmi_i2s_audio_startup,
> .audio_shutdown = dw_hdmi_i2s_audio_shutdown,
> .get_eld = dw_hdmi_i2s_get_eld,
> .get_dai_id = dw_hdmi_i2s_get_dai_id,
>
Looks sane, Jonas should I apply it now it's rebased ?
Neil
next prev parent reply other threads:[~2019-09-02 9:42 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-02 3:54 [PATCH v2] drm: dw-hdmi-i2s: enable audio clock in audio_startup Cheng-Yi Chiang
2019-09-02 9:42 ` Neil Armstrong [this message]
2019-09-02 10:32 ` Jonas Karlman
2019-09-02 11:57 ` Neil Armstrong
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=241fd791-3792-34c8-ac35-a81a0a41070c@baylibre.com \
--to=narmstrong@baylibre.com \
--cc=Laurent.pinchart@ideasonboard.com \
--cc=a.hajda@samsung.com \
--cc=airlied@linux.ie \
--cc=alsa-devel@alsa-project.org \
--cc=cain.cai@rock-chips.com \
--cc=cychiang@chromium.org \
--cc=daniel@ffwll.ch \
--cc=dgreid@chromium.org \
--cc=dianders@chromium.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=eddie.cai@rock-chips.com \
--cc=enric.balletbo@collabora.com \
--cc=jeffy.chen@rock-chips.com \
--cc=jonas@kwiboo.se \
--cc=kuninori.morimoto.gx@renesas.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=sam@ravnborg.org \
--cc=tzungbi@chromium.org \
--cc=zhengxing@rock-chips.com \
/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).