Re: [RFC PATCH 2/2] media: synopsys: hdmirx: add HDMI audio capture support

From: Igor Paunovic

Date: Wed Jul 15 2026 - 15:28:06 EST


Hello Dmitry,

> Nit: platform_device_register_data() should work too. The specified
> DMA mask should be unused by the codec driver and even if it was
> used, it should be inherited from the parent dev and not fixed to
> 32bit. Please either remove .dma_mask or use
> platform_device_register_data().

Switched to platform_device_register_data() for v2 -- you're right,
the codec doesn't do DMA, so the mask (a leftover from the vendor
driver) is gone together with the pdevinfo boilerplate.

> Please fix Sashiko bug reports for v2. Otherwise, the patch looks
> okay. Thanks for working on it.

All five driver findings from that review are already fixed in my
tree (ERR_PTR handling, remove() teardown ordering, hw_params/worker
race, named clock lookup, consistent workqueue), along with the
Media CI sparse warnings and Sebastian's binding and S/PDIF DAI
comments. Re-validated on the Orange Pi 5 Plus. I'll send v2 with
all of it shortly.

Thanks for the review!

Igor
--------------------------------------------------------
=============================================================

On Wed, Jul 15, 2026 at 9:08 PM Dmitry Osipenko
<dmitry.osipenko@xxxxxxxxxxxxx> wrote:
>
> Hi,
>
> 15.07.2026 08:19, Igor Paunovic пишет:
> > +static int hdmirx_register_audio_device(struct snps_hdmirx_dev *hdmirx_dev)
> > +{
> > + struct hdmi_codec_pdata codec_data = {
> > + .ops = &hdmirx_audio_codec_ops,
> > + .i2s = 1,
> > + .no_i2s_playback = 1,
> > + .max_i2s_channels = 8,
> > + .data = hdmirx_dev,
> > + };
> > + struct platform_device_info pdevinfo = {
> > + .parent = hdmirx_dev->dev,
> > + .id = PLATFORM_DEVID_AUTO,
> > + .name = HDMI_CODEC_DRV_NAME,
> > + .data = &codec_data,
> > + .size_data = sizeof(codec_data),
> > + .dma_mask = DMA_BIT_MASK(32),
> > + };
> > +
> > + hdmirx_dev->audio_pdev = platform_device_register_full(&pdevinfo);
> Nit: platform_device_register_data() should work too. The specified DMA
> mask should be unused by the codec driver and even if it was used, it
> should be inherited from the parent dev and not fixed to 32bit. Please
> either remove .dma_mask or use platform_device_register_data().
>
> Please fix Sashiko bug reports for v2. Otherwise, the patch looks okay.
> Thanks for working on it.
>
> --
> Best regards,
> Dmitry