[Intel-gfx] [PATCH 8/8] drm/print: introduce new struct drm_device based logging macros
Jani Nikula
jani.nikula at intel.com
Thu Oct 10 09:32:20 UTC 2019
On Wed, 09 Oct 2019, "Ruhl, Michael J" <michael.j.ruhl at intel.com> wrote:
>>-----Original Message-----
>>From: Intel-gfx [mailto:intel-gfx-bounces at lists.freedesktop.org] On Behalf Of
>>Jani Nikula
>>+/* Helper for struct drm_device based logging. */
>>+#define __drm_printk(drm, level, type, fmt, ...) \
>>+ dev_##level##type(drm->dev, "[drm] " fmt, ##__VA_ARGS__)
>
> In the past, I have been able to do a:
>
> #undef pr_fmt
> #define pr_fmt(fmt) "[myinfo here] " fmt
>
> And have the "[myinfo here]" portion show up the output.
>
> Is it possible that you might be able to use this instead of "[drm] " fmt?
>
> I think that the this will be the same result, but might be more in
> line with the printk interface?
pr_fmt is only used by the pr_<level>() macros in printk.h that use
printk. This does not use printk.
BR,
Jani.
--
Jani Nikula, Intel Open Source Graphics Center
More information about the Intel-gfx
mailing list