[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241231004311.2574720-1-martin.blumenstingl@googlemail.com>
Date: Tue, 31 Dec 2024 01:43:11 +0100
From: Martin Blumenstingl <martin.blumenstingl@...glemail.com>
To: dmitry.baryshkov@...aro.org
Cc: Laurent.pinchart@...asonboard.com,
airlied@...il.com,
alain.volmat@...s.st.com,
alim.akhtar@...sung.com,
andrzej.hajda@...el.com,
andy.yan@...k-chips.com,
angelogioacchino.delregno@...labora.com,
broonie@...nel.org,
chunkuang.hu@...nel.org,
dave.stevenson@...pberrypi.com,
dri-devel@...ts.freedesktop.org,
heiko@...ech.de,
hjc@...k-chips.com,
inki.dae@...sung.com,
jani.nikula@...ux.intel.com,
jernej.skrabec@...il.com,
jonas@...boo.se,
kernel-list@...pberrypi.com,
krzk@...nel.org,
kyungmin.park@...sung.com,
lgirdwood@...il.com,
linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org,
linux-mediatek@...ts.infradead.org,
linux-rockchip@...ts.infradead.org,
linux-samsung-soc@...r.kernel.org,
linux-sound@...r.kernel.org,
linux@...linux.org.uk,
maarten.lankhorst@...ux.intel.com,
matthias.bgg@...il.com,
mcanal@...lia.com,
mripard@...nel.org,
neil.armstrong@...aro.org,
p.zabel@...gutronix.de,
perex@...ex.cz,
ple@...libre.com,
rfoss@...nel.org,
rgallaispou@...il.com,
simona@...ll.ch,
sw0312.kim@...sung.com,
tiwai@...e.com,
tzimmermann@...e.de
Subject: RE: [PATCH v10 03/10] drm/connector: implement generic HDMI audio helpers
Hello Dmitry,
this is great work - thanks for your efforts!
To give some context:
I am working on a HDMI controller driver for the Amlogic Meson8/8b/8m2
SoCs. Unfortunately the driver is not mature enough for upstream
submission (all I have is the vendor driver which serves as reference).
That said, my goal is to upstream the driver at some point. I have
already switched my driver to use hdmi_{clear,write}_infoframe. Now
I'm trying this series to simplify my code even further - by using
your audio helper work!
> --- /dev/null
> +++ b/drivers/gpu/drm/display/drm_hdmi_audio_helper.c
> @@ -0,0 +1,190 @@
> [...]
> +static const struct hdmi_codec_ops drm_connector_hdmi_audio_ops = {
> + .audio_startup = drm_connector_hdmi_audio_startup,
> + .prepare = drm_connector_hdmi_audio_prepare,
> + .audio_shutdown = drm_connector_hdmi_audio_shutdown,
> + .mute_stream = drm_connector_hdmi_audio_mute_stream,
> + .get_eld = drm_connector_hdmi_audio_get_eld,
> + .get_dai_id = drm_connector_hdmi_audio_get_dai_id,
> + .hook_plugged_cb = drm_connector_hdmi_audio_hook_plugged_cb,
> +};
On my platform drm_connector_hdmi_audio_prepare() is never called. As
a result of that the audio infoframe is never written to my HDMI
controller hardware (hdmi_write_infoframe() is never called with type
HDMI_INFOFRAME_TYPE_AUDIO). My hack to make it work is to add the
following line to drm_connector_hdmi_audio_ops:
.hw_params = drm_connector_hdmi_audio_prepare,
I checked all instances of struct hdmi_codec_ops in v6.13-rc3 and it
seems that there is only a single driver which uses the .prepare
callback (drivers/gpu/drm/vc4/vc4_hdmi.c). All other drivers seem to
implement .hw_params instead.
The audio controller code for my platform is already upstream:
- sound/soc/meson/aiu-codec-ctrl.c
- sound/soc/meson/aiu-encoder-i2s.c
- sound/soc/meson/aiu-fifo-i2s.c
My understanding is that you have a platform with a lontium-lt9611
HDMI controller available for testing. Can you please help me
investigate and find out which piece of code is calling
hdmi_codec_prepare() and therefore lt9611_hdmi_audio_prepare() on
your board?
Thank you and best regards,
Martin
Powered by blists - more mailing lists