drm/print: Introduce drm_line_printer
authorMichal Wajdeczko <michal.wajdeczko@intel.com>
Thu, 3 Oct 2024 00:46:07 +0000 (17:46 -0700)
committerJohn Harrison <John.C.Harrison@Intel.com>
Tue, 8 Oct 2024 01:34:45 +0000 (18:34 -0700)
commit754e707e20e47482384f6e64eb3af08273292010
treebf37324a5fee969710451038c25a1c5d5e7db8ee
parentd8ce1a97722617317b04eb9f19ab8d6d95379f7a
drm/print: Introduce drm_line_printer

This drm printer wrapper can be used to increase the robustness of
the captured output generated by any other drm_printer to make sure
we didn't lost any intermediate lines of the output by adding line
numbers to each output line. Helpful for capturing some crash data.

v2: Extended short int counters to full int (JohnH)

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Signed-off-by: John Harrison <John.C.Harrison@Intel.com>
Cc: Jani Nikula <jani.nikula@intel.com>
Cc: dri-devel@lists.freedesktop.org
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20241003004611.2323493-8-John.C.Harrison@Intel.com
drivers/gpu/drm/drm_print.c
include/drm/drm_print.h