pvr_events.o
pvrsrvkm-objs-$(CONFIG_PVR_DEBUG) += pvr_debug.o
+pvrsrvkm-objs-$(CONFIG_DEBUG_FS) += pvr_debug.o
pvrsrvkm-objs-$(CONFIG_PVR_TIMING) += pvr_debug.o
pvrsrvkm-objs += $(pvrsrvkm-objs-y) $(pvrsrvkm-objs-m)
#include "sgxutils.h"
#include "pvr_bridge_km.h"
+#ifdef CONFIG_PVR_DEBUG
+
u32 gPVRDebugLevel = DBGPRIV_WARNING;
#define PVR_MAX_MSG_LEN PVR_MAX_DEBUG_MESSAGE_LEN
return 0;
}
+#endif
+
#ifdef CONFIG_DEBUG_FS
static struct dentry *debugfs_dir;
void pvr_dbg_init(void)
{
+#if defined(CONFIG_PVR_DEBUG) || defined(TIMING)
mutex_init(&gsDebugMutexNonIRQ);
+#endif
pvr_init_debugfs();
}
int *eof, void *data);
void PVRDebugSetLevel(u32 uDebugLevel);
-void pvr_dbg_init(void);
-void pvr_dbg_cleanup(void);
-
#define PVR_DBG_BREAK
#else
#define PVR_TRACE(fmt, ...) do { } while (0)
#define PVR_DBG_BREAK do { } while (0)
+#endif /* TIMING */
+
+#endif /* CONFIG_PVR_DEBUG */
+
+#if defined(CONFIG_PVR_DEBUG) || defined(TIMING) || defined(CONFIG_DEBUG_FS)
+
+void pvr_dbg_init(void);
+void pvr_dbg_cleanup(void);
+
+#else
+
static inline void pvr_dbg_init(void) {};
static inline void pvr_dbg_cleanup(void) {};
-#endif
#endif
#endif