From b0313f89672eddf0188dac96bb8f83135510a45c Mon Sep 17 00:00:00 2001 From: Jean Delvare Date: Mon, 28 Apr 2008 02:15:12 -0700 Subject: radeonfb: fix debug option Fix CONFIG_FB_RADEON_DEBUG. DEBUG must be defined before including any kernel header, otherwise dev_dbg() resolves to a no-op. Also, when debugging is disabled, don't set DEBUG at all instead of setting it to 0, to comply with what the kernel headers expect. Signed-off-by: Jean Delvare Acked-by: Benjamin Herrenschmidt Cc: "Antonino A. Daplas" Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/video/aty/radeonfb.h | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'drivers/video/aty/radeonfb.h') diff --git a/drivers/video/aty/radeonfb.h b/drivers/video/aty/radeonfb.h index 5eac1ce52e7..8215ca0555c 100644 --- a/drivers/video/aty/radeonfb.h +++ b/drivers/video/aty/radeonfb.h @@ -1,6 +1,10 @@ #ifndef __RADEONFB_H__ #define __RADEONFB_H__ +#ifdef CONFIG_FB_RADEON_DEBUG +#define DEBUG 1 +#endif + #include #include #include @@ -367,13 +371,7 @@ struct radeonfb_info { /* * Debugging stuffs */ -#ifdef CONFIG_FB_RADEON_DEBUG -#define DEBUG 1 -#else -#define DEBUG 0 -#endif - -#if DEBUG +#ifdef DEBUG #define RTRACE printk #else #define RTRACE if(0) printk -- cgit v1.2.3