Commit 6e3100ec authored by Paulo Zanoni's avatar Paulo Zanoni

drm/i915/kbl: KBL also needs to run the SAGV code

According to BSpec, it's the "core CPUs" that need the code, which
means SKL and KBL, but not BXT.

I don't have a KBL to test this patch on it.

v2: Only SKL should have I915_SAGV_NOT_CONTROLLED.

Cc: stable@vger.kernel.org
Reviewed-by: default avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: default avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1474578035-424-4-git-send-email-paulo.r.zanoni@intel.com
parent 56feca91
...@@ -2880,8 +2880,14 @@ skl_wm_plane_id(const struct intel_plane *plane) ...@@ -2880,8 +2880,14 @@ skl_wm_plane_id(const struct intel_plane *plane)
static bool static bool
intel_has_sagv(struct drm_i915_private *dev_priv) intel_has_sagv(struct drm_i915_private *dev_priv)
{ {
return IS_SKYLAKE(dev_priv) && if (IS_KABYLAKE(dev_priv))
dev_priv->sagv_status != I915_SAGV_NOT_CONTROLLED; return true;
if (IS_SKYLAKE(dev_priv) &&
dev_priv->sagv_status != I915_SAGV_NOT_CONTROLLED)
return true;
return false;
} }
/* /*
...@@ -2919,7 +2925,7 @@ intel_enable_sagv(struct drm_i915_private *dev_priv) ...@@ -2919,7 +2925,7 @@ intel_enable_sagv(struct drm_i915_private *dev_priv)
* Some skl systems, pre-release machines in particular, * Some skl systems, pre-release machines in particular,
* don't actually have an SAGV. * don't actually have an SAGV.
*/ */
if (ret == -ENXIO) { if (IS_SKYLAKE(dev_priv) && ret == -ENXIO) {
DRM_DEBUG_DRIVER("No SAGV found on system, ignoring\n"); DRM_DEBUG_DRIVER("No SAGV found on system, ignoring\n");
dev_priv->sagv_status = I915_SAGV_NOT_CONTROLLED; dev_priv->sagv_status = I915_SAGV_NOT_CONTROLLED;
return 0; return 0;
...@@ -2973,7 +2979,7 @@ intel_disable_sagv(struct drm_i915_private *dev_priv) ...@@ -2973,7 +2979,7 @@ intel_disable_sagv(struct drm_i915_private *dev_priv)
* Some skl systems, pre-release machines in particular, * Some skl systems, pre-release machines in particular,
* don't actually have an SAGV. * don't actually have an SAGV.
*/ */
if (result == -ENXIO) { if (IS_SKYLAKE(dev_priv) && result == -ENXIO) {
DRM_DEBUG_DRIVER("No SAGV found on system, ignoring\n"); DRM_DEBUG_DRIVER("No SAGV found on system, ignoring\n");
dev_priv->sagv_status = I915_SAGV_NOT_CONTROLLED; dev_priv->sagv_status = I915_SAGV_NOT_CONTROLLED;
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment