[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <241fd791-3792-34c8-ac35-a81a0a41070c@baylibre.com>
Date: Mon, 2 Sep 2019 11:42:38 +0200
From: Neil Armstrong <narmstrong@...libre.com>
To: Cheng-Yi Chiang <cychiang@...omium.org>,
linux-kernel@...r.kernel.org
Cc: alsa-devel@...a-project.org, tzungbi@...omium.org,
zhengxing@...k-chips.com, kuninori.morimoto.gx@...esas.com,
a.hajda@...sung.com, airlied@...ux.ie, jeffy.chen@...k-chips.com,
dianders@...omium.org, dri-devel@...ts.freedesktop.org,
cain.cai@...k-chips.com, linux-rockchip@...ts.infradead.org,
Jonas Karlman <jonas@...boo.se>, eddie.cai@...k-chips.com,
Laurent.pinchart@...asonboard.com, daniel@...ll.ch,
enric.balletbo@...labora.com, dgreid@...omium.org,
sam@...nborg.org, linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH v2] drm: dw-hdmi-i2s: enable audio clock in audio_startup
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@...omium.org>
> Reviewed-by: Douglas Anderson <dianders@...omium.org>
> Reviewed-by: Jonas Karlman <jonas@...boo.se>
> Tested-by: Douglas Anderson <dianders@...omium.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@...omium.org.
> 5. Add Reviewed-by field from jonas@...boo.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
Powered by blists - more mailing lists