[PATCH 1/3] drm/tegra: Add NVJPG driver
Thierry Reding
thierry.reding at gmail.com
Tue Jun 10 08:44:11 UTC 2025
On Tue, Jun 10, 2025 at 12:26:07PM +0900, Mikko Perttunen wrote:
> On 6/6/25 7:45 PM, Diogo Ivo wrote:
> > Add support for booting and using NVJPG on Tegra210 to the Host1x
> > and TegraDRM drivers. This driver only supports the new TegraDRM uAPI.
>
> Hello Diogo -- I'm happy to see this driver!
So am I, nice work!
[...]
> > + if (IS_ERR(nvjpg->regs))
> > + return PTR_ERR(nvjpg->regs);
> > +
> > + nvjpg->rst = devm_reset_control_get_exclusive_released(&pdev->dev, "nvjpg");
> > + if (IS_ERR(nvjpg->rst)) {
> > + err = PTR_ERR(nvjpg->rst);
> > +
> > + if (err != -EBUSY || WARN_ON(!pdev->dev.pm_domain)) {
> > + dev_err(&pdev->dev, "failed to get reset control: %d\n",
> > + err);
> > + return err;
> > + }
> > +
> > + /*
> > + * At this point, the reset control is most likely being used
> > + * by the generic power domain implementation. With any luck
> > + * the power domain will have taken care of resetting the SOR
> > + * and we don't have to do anything.
> > + */
> > + nvjpg->rst = NULL;
> > + }
>
> I see you've taken this from sor.c, but I think it should be unnecessary. I
> imagine the code in sor.c is overcomplicated as well, maybe because we used
> not to have the power domain implementation.
Agreed. SOR is also slightly older than NVJPG and used on Tegra124 where
we don't use power domains, so most of these quirks are for backwards-
compatibility. If we can avoid them for NVJPG, that'd be great.
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20250610/34eba1d1/attachment.sig>
More information about the dri-devel
mailing list