[PATCH v4 2/5] drm: adp: Add Apple Display Pipe driver
Sasha Finkelstein
fnkl.kernel at gmail.com
Thu Jan 16 18:52:30 UTC 2025
On Wed, 15 Jan 2025 at 11:21, Dmitry Baryshkov
<dmitry.baryshkov at linaro.org> wrote:
> > + ret = drm_simple_encoder_init(drm, &adp->encoder, DRM_MODE_ENCODER_DSI);
>
> This is being deprecated, please use drm_encoder_init() /
> drmm_encoder_init() instead.
I seem to be unable to find any documentation or a mailing list post
to this effect. If you are referring to this patchset:
https://patchwork.kernel.org/project/linux-samsung-soc/patch/20200313201744.19773-3-sam@ravnborg.org/
according to my understanding, it has not been applied.
In this case, the simple encoder api provides all functionality i need,
and a replacement would just be a simple encoder, except copied and pasted
into this driver.
> > +static void adp_remove(struct platform_device *pdev)
> > +{
> > + struct device *dev = &pdev->dev;
> > + struct drm_device *drm = dev_get_drvdata(dev);
> > + struct adp_drv_private *adp = to_adp(drm);
> > +
> > + adp_disable_vblank(adp);
>
> Isn't it being helped by the DRM itself? Anyway, I'd suggest moving it
> after DRM device unregistration and shutdown.
Not sure i follow, as this call disables generation of vblank interrupts,
shouldn't it be done before all drm structures are torn down, to prevent
the interrupt handler from potentially operating on objects that are in
an invalid state?
More information about the dri-devel
mailing list