[Intel-gfx] [PATCH v1 02/11] drm: drop uapi dependency from drm_print.h

Sam Ravnborg sam at ravnborg.org
Mon Jul 29 14:35:55 UTC 2019


> >>
> >> Even then it so useless (which drm driver is this message for???) that I
> >> want to remove them all :(
> >
> > Yeah, agree. I mean it is nice if the core drm functions use a prefix 
> > for debug output.
> >
> > But I actually don't see the point for individual drivers.
> 
> We should all migrate to the versions with device...

Just to do an xkdc.com/927 I have considered:

drm_err(const struct drm_device *drm, ...)
drm_info(const struct drm_device *drm, ...)

drm_kms_err(const struct drm_device *drm, ...)
drm_kms_info(const struct drm_device *drm, ...))

And so on for vbl, primse. lease, state etc.

Then we could fish out relevant info from the drm device and present
this nicely.

For the cases where no drm_device is available the fallback is:
drm_dev_err(const struct drm_device *drm, ...)
drm_dev_info(const struct drm_device *drm, ...))

We could modify the existing UPPERCASE macros to be placeholders for
the more reader friendly lower cases variants and base it all on the
established infrastructure.

But this is just idle thinking, as only a serious patch would stir the
relevant discussions.

For now this is far from the top of my TODO list.


	Sam


More information about the Intel-gfx mailing list