[Intel-gfx] [PATCH] drm/i915: intel_overlay_print_error_state() only needed for debugfs

Tobias Doerffel tobias.doerffel at gmail.com
Wed Aug 25 23:54:21 CEST 2010


The function intel_overlay_print_error_state() is called from within
i915_error_state() in i915_debufs.c which is only built if
CONFIG_DEBUG_FS is set. When building without this option, seq_printf()
is not declared in intel_overlay.c and the file fails to compile.
Furthermore the whole function is superfluous in this case. Therefore
only build it if CONFIG_DEBUG_FS is set.
---
 drivers/gpu/drm/i915/intel_overlay.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_overlay.c b/drivers/gpu/drm/i915/intel_overlay.c
index 4f00390..74feb89 100644
--- a/drivers/gpu/drm/i915/intel_overlay.c
+++ b/drivers/gpu/drm/i915/intel_overlay.c
@@ -1461,6 +1461,7 @@ err:
 	return NULL;
 }
 
+#ifdef CONFIG_DEBUG_FS
 void
 intel_overlay_print_error_state(struct seq_file *m, struct intel_overlay_error_state *error)
 {
@@ -1513,3 +1514,4 @@ intel_overlay_print_error_state(struct seq_file *m, struct intel_overlay_error_s
 	P(UVSCALEV);
 #undef P
 }
+#endif	/* CONFIG_DEBUG_FS */
-- 
1.7.1




More information about the Intel-gfx mailing list