drm/i915: only build i915_debugfs.c when CONFIG_DEBUG_FS is enabled
authorJani Nikula <jani.nikula@intel.com>
Mon, 16 Dec 2013 11:10:36 +0000 (13:10 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 16 Dec 2013 15:53:32 +0000 (16:53 +0100)
The whole file is wrapped around in #if defined(CONFIG_DEBUG_FS) anyway,
so skip the file at the build level already.

Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/Makefile
drivers/gpu/drm/i915/i915_debugfs.c

index 41838eaa799c5afcb7510bae31118099d4d848a3..da682cbcb8061dd33d8c67c901e476ffebeffc32 100644 (file)
@@ -4,7 +4,6 @@
 
 ccflags-y := -Iinclude/drm
 i915-y := i915_drv.o i915_dma.o i915_irq.o \
-         i915_debugfs.o \
          i915_gpu_error.o \
           i915_suspend.o \
          i915_gem.o \
@@ -55,6 +54,8 @@ i915-$(CONFIG_ACPI)   += intel_acpi.o
 
 i915-$(CONFIG_DRM_I915_FBDEV) += intel_fbdev.o
 
+i915-$(CONFIG_DEBUG_FS) += i915_debugfs.o
+
 obj-$(CONFIG_DRM_I915)  += i915.o
 
 CFLAGS_i915_trace_points.o := -I$(src)
index 242189ee3607a91ed1049a375c5631c21b199308..6294ffdcc0ac46df5643713673a655ef2541414e 100644 (file)
@@ -40,8 +40,6 @@
 #include <drm/i915_drm.h>
 #include "i915_drv.h"
 
-#if defined(CONFIG_DEBUG_FS)
-
 enum {
        ACTIVE_LIST,
        INACTIVE_LIST,
@@ -3282,5 +3280,3 @@ void i915_debugfs_cleanup(struct drm_minor *minor)
                drm_debugfs_remove_files(info_list, 1, minor);
        }
 }
-
-#endif /* CONFIG_DEBUG_FS */