|
|
@@ -2087,6 +2087,7 @@ void intel_flush_primary_plane(struct drm_i915_private *dev_priv,
|
|
|
static void intel_enable_primary_hw_plane(struct drm_i915_private *dev_priv,
|
|
|
enum plane plane, enum pipe pipe)
|
|
|
{
|
|
|
+ struct drm_device *dev = dev_priv->dev;
|
|
|
struct intel_crtc *intel_crtc =
|
|
|
to_intel_crtc(dev_priv->pipe_to_crtc_mapping[pipe]);
|
|
|
int reg;
|
|
|
@@ -2106,6 +2107,14 @@ static void intel_enable_primary_hw_plane(struct drm_i915_private *dev_priv,
|
|
|
|
|
|
I915_WRITE(reg, val | DISPLAY_PLANE_ENABLE);
|
|
|
intel_flush_primary_plane(dev_priv, plane);
|
|
|
+
|
|
|
+ /*
|
|
|
+ * BDW signals flip done immediately if the plane
|
|
|
+ * is disabled, even if the plane enable is already
|
|
|
+ * armed to occur at the next vblank :(
|
|
|
+ */
|
|
|
+ if (IS_BROADWELL(dev))
|
|
|
+ intel_wait_for_vblank(dev, intel_crtc->pipe);
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
@@ -11088,6 +11097,22 @@ const char *intel_output_name(int output)
|
|
|
return names[output];
|
|
|
}
|
|
|
|
|
|
+static bool intel_crt_present(struct drm_device *dev)
|
|
|
+{
|
|
|
+ struct drm_i915_private *dev_priv = dev->dev_private;
|
|
|
+
|
|
|
+ if (IS_ULT(dev))
|
|
|
+ return false;
|
|
|
+
|
|
|
+ if (IS_CHERRYVIEW(dev))
|
|
|
+ return false;
|
|
|
+
|
|
|
+ if (IS_VALLEYVIEW(dev) && !dev_priv->vbt.int_crt_support)
|
|
|
+ return false;
|
|
|
+
|
|
|
+ return true;
|
|
|
+}
|
|
|
+
|
|
|
static void intel_setup_outputs(struct drm_device *dev)
|
|
|
{
|
|
|
struct drm_i915_private *dev_priv = dev->dev_private;
|
|
|
@@ -11096,7 +11121,7 @@ static void intel_setup_outputs(struct drm_device *dev)
|
|
|
|
|
|
intel_lvds_init(dev);
|
|
|
|
|
|
- if (!IS_ULT(dev) && !IS_CHERRYVIEW(dev) && dev_priv->vbt.int_crt_support)
|
|
|
+ if (intel_crt_present(dev))
|
|
|
intel_crt_init(dev);
|
|
|
|
|
|
if (HAS_DDI(dev)) {
|