Commit 1c70c0ce authored by Jesse Barnes's avatar Jesse Barnes Committed by Keith Packard

drm/i915: enable ring freq scaling, RC6 and graphics turbo on Ivy Bridge v3

They use the same register interfaces, so we can simply enable the
existing code on IVB.

v2:
  - resolve conflict with ring freq scaling, we can enable it too
v3:
  - resolve conflict again, this time on drm-intel-next
Signed-off-by: default avatarJesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: default avatarKeith Packard <keithp@keithp.com>
parent 8eb2c0ee
...@@ -865,7 +865,7 @@ static int i915_cur_delayinfo(struct seq_file *m, void *unused) ...@@ -865,7 +865,7 @@ static int i915_cur_delayinfo(struct seq_file *m, void *unused)
MEMSTAT_VID_SHIFT); MEMSTAT_VID_SHIFT);
seq_printf(m, "Current P-state: %d\n", seq_printf(m, "Current P-state: %d\n",
(rgvstat & MEMSTAT_PSTATE_MASK) >> MEMSTAT_PSTATE_SHIFT); (rgvstat & MEMSTAT_PSTATE_MASK) >> MEMSTAT_PSTATE_SHIFT);
} else if (IS_GEN6(dev)) { } else if (IS_GEN6(dev) || IS_GEN7(dev)) {
u32 gt_perf_status = I915_READ(GEN6_GT_PERF_STATUS); u32 gt_perf_status = I915_READ(GEN6_GT_PERF_STATUS);
u32 rp_state_limits = I915_READ(GEN6_RP_STATE_LIMITS); u32 rp_state_limits = I915_READ(GEN6_RP_STATE_LIMITS);
u32 rp_state_cap = I915_READ(GEN6_RP_STATE_CAP); u32 rp_state_cap = I915_READ(GEN6_RP_STATE_CAP);
...@@ -1131,7 +1131,7 @@ static int i915_ring_freq_table(struct seq_file *m, void *unused) ...@@ -1131,7 +1131,7 @@ static int i915_ring_freq_table(struct seq_file *m, void *unused)
int ret; int ret;
int gpu_freq, ia_freq; int gpu_freq, ia_freq;
if (!IS_GEN6(dev)) { if (!(IS_GEN6(dev) || IS_GEN7(dev))) {
seq_printf(m, "unsupported on this chipset\n"); seq_printf(m, "unsupported on this chipset\n");
return 0; return 0;
} }
......
...@@ -7970,7 +7970,7 @@ void intel_modeset_init(struct drm_device *dev) ...@@ -7970,7 +7970,7 @@ void intel_modeset_init(struct drm_device *dev)
intel_init_emon(dev); intel_init_emon(dev);
} }
if (IS_GEN6(dev)) { if (IS_GEN6(dev) || IS_GEN7(dev)) {
gen6_enable_rps(dev_priv); gen6_enable_rps(dev_priv);
gen6_update_ring_freq(dev_priv); gen6_update_ring_freq(dev_priv);
} }
...@@ -8014,7 +8014,7 @@ void intel_modeset_cleanup(struct drm_device *dev) ...@@ -8014,7 +8014,7 @@ void intel_modeset_cleanup(struct drm_device *dev)
if (IS_IRONLAKE_M(dev)) if (IS_IRONLAKE_M(dev))
ironlake_disable_drps(dev); ironlake_disable_drps(dev);
if (IS_GEN6(dev)) if (IS_GEN6(dev) || IS_GEN7(dev))
gen6_disable_rps(dev); gen6_disable_rps(dev);
if (IS_IRONLAKE_M(dev)) if (IS_IRONLAKE_M(dev))
......
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