drm/i915: Use CONFIG_DRM_FBDEV_EMULATION
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 10 Aug 2015 11:34:08 +0000 (13:34 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 11 Aug 2015 12:00:29 +0000 (14:00 +0200)
Instead of our own duplicated one. This fixes a bug in the driver
unload code if DRM_FBDEV_EMULATION=n but DRM_I915_FBDEV=y because we
try to unregister the nonexistent fbdev drm_framebuffer.

Cc: Archit Taneja <architt@codeaurora.org>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reported-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/Kconfig
drivers/gpu/drm/i915/Makefile
drivers/gpu/drm/i915/i915_debugfs.c
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/intel_display.c
drivers/gpu/drm/i915/intel_dp_mst.c
drivers/gpu/drm/i915/intel_drv.h

index eb87e2538861506409ad7651a6a5b7738e771fa4..051eab33e4c7b13260994ebb884cc44a5394c4bc 100644 (file)
@@ -36,21 +36,6 @@ config DRM_I915
          i810 driver instead, and the Atom z5xx series has an entirely
          different implementation.
 
-config DRM_I915_FBDEV
-       bool "Enable legacy fbdev support for the modesetting intel driver"
-       depends on DRM_I915
-       select DRM_KMS_FB_HELPER
-       select FB_CFB_FILLRECT
-       select FB_CFB_COPYAREA
-       select FB_CFB_IMAGEBLIT
-       default y
-       help
-         Choose this option if you have a need for the legacy fbdev
-         support. Note that this support also provide the linux console
-         support on top of the intel modesetting driver.
-
-         If in doubt, say "Y".
-
 config DRM_I915_PRELIMINARY_HW_SUPPORT
        bool "Enable preliminary support for prerelease Intel hardware by default"
        depends on DRM_I915
index e52e0125164450ad7f1e2dea841000b7a24c94bb..b3d9992f02103c8a0ba5ca4428b60e97a51b8c9d 100644 (file)
@@ -59,7 +59,7 @@ i915-y += intel_audio.o \
          intel_sideband.o \
          intel_sprite.o
 i915-$(CONFIG_ACPI)            += intel_acpi.o intel_opregion.o
-i915-$(CONFIG_DRM_I915_FBDEV)  += intel_fbdev.o
+i915-$(CONFIG_DRM_FBDEV_EMULATION)     += intel_fbdev.o
 
 # modesetting output/encoder code
 i915-y += dvo_ch7017.o \
index 51580bdd587fd8e6e3ef3f4820682924bdc35003..36fe318757376fcdb3d3ad2c63fe072f3df53733 100644 (file)
@@ -1868,7 +1868,7 @@ static int i915_gem_framebuffer_info(struct seq_file *m, void *data)
        struct intel_framebuffer *fb;
        struct drm_framebuffer *drm_fb;
 
-#ifdef CONFIG_DRM_I915_FBDEV
+#ifdef CONFIG_DRM_FBDEV_EMULATION
        struct drm_i915_private *dev_priv = dev->dev_private;
 
        ifbdev = dev_priv->fbdev;
index 23ce125e0298e05b430f05daf45ef56952948fed..e9d2befbcaf3b382e28f593ac1ce16a9e9184101 100644 (file)
@@ -1854,7 +1854,7 @@ struct drm_i915_private {
 
        struct drm_i915_gem_object *vlv_pctx;
 
-#ifdef CONFIG_DRM_I915_FBDEV
+#ifdef CONFIG_DRM_FBDEV_EMULATION
        /* list of fbdev register on this device */
        struct intel_fbdev *fbdev;
        struct work_struct fbdev_suspend_work;
index 43b0f17ad1fa5c1e2c86c8c5e8381d4035edc63c..97ec61c842edce4b0a73cd1d6dfc18ed896cf773 100644 (file)
@@ -10221,7 +10221,7 @@ static struct drm_framebuffer *
 mode_fits_in_fbdev(struct drm_device *dev,
                   struct drm_display_mode *mode)
 {
-#ifdef CONFIG_DRM_I915_FBDEV
+#ifdef CONFIG_DRM_FBDEV_EMULATION
        struct drm_i915_private *dev_priv = dev->dev_private;
        struct drm_i915_gem_object *obj;
        struct drm_framebuffer *fb;
@@ -14475,7 +14475,7 @@ intel_user_framebuffer_create(struct drm_device *dev,
        return intel_framebuffer_create(dev, mode_cmd, obj);
 }
 
-#ifndef CONFIG_DRM_I915_FBDEV
+#ifndef CONFIG_DRM_FBDEV_EMULATION
 static inline void intel_fbdev_output_poll_changed(struct drm_device *dev)
 {
 }
index 585f0a45b3f1cf0cb53603c9204f9c271eb06df1..efc8cf53f0f318e650fdc3d55adf53efd5bee836 100644 (file)
@@ -395,7 +395,7 @@ static bool intel_dp_mst_get_hw_state(struct intel_connector *connector)
 
 static void intel_connector_add_to_fbdev(struct intel_connector *connector)
 {
-#ifdef CONFIG_DRM_I915_FBDEV
+#ifdef CONFIG_DRM_FBDEV_EMULATION
        struct drm_i915_private *dev_priv = to_i915(connector->base.dev);
        drm_fb_helper_add_one_connector(&dev_priv->fbdev->helper, &connector->base);
 #endif
@@ -403,7 +403,7 @@ static void intel_connector_add_to_fbdev(struct intel_connector *connector)
 
 static void intel_connector_remove_from_fbdev(struct intel_connector *connector)
 {
-#ifdef CONFIG_DRM_I915_FBDEV
+#ifdef CONFIG_DRM_FBDEV_EMULATION
        struct drm_i915_private *dev_priv = to_i915(connector->base.dev);
        drm_fb_helper_remove_one_connector(&dev_priv->fbdev->helper, &connector->base);
 #endif
index 320c9e6bd8484e231767534e4563047957ff2b25..2e743d6abffd1b40c2b9d0a6b97d81a8f28552d3 100644 (file)
@@ -1203,7 +1203,7 @@ void intel_dvo_init(struct drm_device *dev);
 
 
 /* legacy fbdev emulation in intel_fbdev.c */
-#ifdef CONFIG_DRM_I915_FBDEV
+#ifdef CONFIG_DRM_FBDEV_EMULATION
 extern int intel_fbdev_init(struct drm_device *dev);
 extern void intel_fbdev_initial_config(void *data, async_cookie_t cookie);
 extern void intel_fbdev_fini(struct drm_device *dev);