[PATCH 2/2] drm/udl: Clear struct drm_connector_funcs.dpms

Emil Velikov emil.l.velikov at gmail.com
Tue Feb 11 12:02:33 UTC 2020


On Mon, 10 Feb 2020 at 08:10, Thomas Zimmermann <tzimmermann at suse.de> wrote:
>
> Hi
>
> Am 07.02.20 um 17:41 schrieb Daniel Vetter:
> > On Fri, Feb 07, 2020 at 03:16:02PM +0100, Thomas Zimmermann wrote:
> >> Atomic modesetting doesn't use struct drm_connector_funcs.dpms and
> >> the set function, drm_helper_connector_dpms(), wouldn't support it
> >> anyway. So keep the pointer to NULL.
> >>
> >> Signed-off-by: Thomas Zimmermann <tzimmermann at suse.de>
> >
> > On both patches:
> >
> > Reviewed-by: Daniel Vetter <daniel.vetter at ffwll.ch>
> >
> > I just suggested a drm_mode_config_validate() to Ville in his patch
> > series, which runs in drm_dev_register(). Maybe we could add a check for
> > that for atomic drivers? It's a bit a game of whack-a-mole otherwise :-)
>
> From the 'git grep' I'd say those where the only atomic drivers to set
> the callback. The others where non-atomic ones. OTOH, I recently thought
> on several occasions that this or that behaviour should be enforced at
> least by WARN_ON.
>
Having a WARN_ON was my first idea as I saw these patches fly-by.

Sure it will add some dmesg noise in the very odd corner-case.
At the same time, it will high-light existing and future bugs so that
we can address them promptly.

Emil


More information about the dri-devel mailing list