diff mbox

drm: Enable pr_debug() for drm_printer

Message ID 20171027110602.31519-1-chris@chris-wilson.co.uk (mailing list archive)
State New, archived
Headers show

Commit Message

Chris Wilson Oct. 27, 2017, 11:06 a.m. UTC
pr_debug() is conditionally compiled and requires either
dynamic-debugging to be enabled or for the code to opt-in using #define
DEBUG. Since drm_print provides a central debugging facility using
pr_debug(), make sure it will always produce output.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Rob Clark <robdclark@gmail.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 drivers/gpu/drm/drm_print.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Sean Paul Oct. 30, 2017, 9:05 p.m. UTC | #1
On Fri, Oct 27, 2017 at 12:06:02PM +0100, Chris Wilson wrote:
> pr_debug() is conditionally compiled and requires either
> dynamic-debugging to be enabled or for the code to opt-in using #define
> DEBUG. Since drm_print provides a central debugging facility using
> pr_debug(), make sure it will always produce output.
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Rob Clark <robdclark@gmail.com>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>

Applied to drm-misc-next

Thanks!

Sean

> ---
>  drivers/gpu/drm/drm_print.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/gpu/drm/drm_print.c b/drivers/gpu/drm/drm_print.c
> index 0b3bf476dc4b..82ff327eb2df 100644
> --- a/drivers/gpu/drm/drm_print.c
> +++ b/drivers/gpu/drm/drm_print.c
> @@ -23,6 +23,8 @@
>   * Rob Clark <robdclark@gmail.com>
>   */
>  
> +#define DEBUG /* for pr_debug() */
> +
>  #include <stdarg.h>
>  #include <linux/seq_file.h>
>  #include <drm/drmP.h>
> -- 
> 2.15.0.rc2
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
diff mbox

Patch

diff --git a/drivers/gpu/drm/drm_print.c b/drivers/gpu/drm/drm_print.c
index 0b3bf476dc4b..82ff327eb2df 100644
--- a/drivers/gpu/drm/drm_print.c
+++ b/drivers/gpu/drm/drm_print.c
@@ -23,6 +23,8 @@ 
  * Rob Clark <robdclark@gmail.com>
  */
 
+#define DEBUG /* for pr_debug() */
+
 #include <stdarg.h>
 #include <linux/seq_file.h>
 #include <drm/drmP.h>