[PATCH v4] drm/bridge: adv7511_audio: Update Audio InfoFrame properly

Dmitry Baryshkov dmitry.baryshkov at linaro.org
Fri Dec 20 01:30:50 UTC 2024


On Tue, Nov 19, 2024 at 08:40:29AM +0100, Stefan Ekenberg wrote:
> AUDIO_UPDATE bit (Bit 5 of MAIN register 0x4A) needs to be set to 1
> while updating Audio InfoFrame information and then set to 0 when done.
> Otherwise partially updated Audio InfoFrames could be sent out. Two
> cases where this rule were not followed are fixed:
>  - In adv7511_hdmi_hw_params() make sure AUDIO_UPDATE bit is updated
>    before/after setting ADV7511_REG_AUDIO_INFOFRAME.
>  - In audio_startup() use the correct register for clearing
>    AUDIO_UPDATE bit.
> 
> The problem with corrupted audio infoframes were discovered by letting
> a HDMI logic analyser check the output of ADV7535.
> 
> Note that this patchs replaces writing REG_GC(1) with
> REG_INFOFRAME_UPDATE. Bit 5 of REG_GC(1) is positioned within field
> GC_PP[3:0] and that field doesn't control audio infoframe and is read-
> only. My conclusion therefore was that the author if this code meant to
> clear bit 5 of REG_INFOFRAME_UPDATE from the very beginning.
> 
> Tested-by: Biju Das <biju.das.jz at bp.renesas.com>
> Fixes: 53c515befe28 ("drm/bridge: adv7511: Add Audio support")
> Signed-off-by: Stefan Ekenberg <stefan.ekenberg at axis.com>
> ---
> Changes in v4:
> - Add Tested-by tag
> - Link to v3: https://lore.kernel.org/r/20241118-adv7511-audio-info-frame-v3-1-31edd9931856@axis.com
> 
> Changes in v3:
> - Extend commit message and explain replacement of REG_GC(1)
> - Link to v2: https://lore.kernel.org/r/20241115-adv7511-audio-info-frame-v2-1-ca4793ef3a91@axis.com
> 
> Changes in v2:
> - Add Fixes tag
> - Link to v1: https://lore.kernel.org/r/20241113-adv7511-audio-info-frame-v1-1-49b368b995a5@axis.com
> ---
>  drivers/gpu/drm/bridge/adv7511/adv7511_audio.c | 14 ++++++++++++--
>  1 file changed, 12 insertions(+), 2 deletions(-)
> 

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov at linaro.org>

-- 
With best wishes
Dmitry


More information about the dri-devel mailing list