drm/i915: Make intel_display_suspend atomic, v2.
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Mon, 1 Jun 2015 10:50:05 +0000 (12:50 +0200)
committerJani Nikula <jani.nikula@intel.com>
Fri, 12 Jun 2015 10:19:34 +0000 (13:19 +0300)
commit06ea0b0897db906c5616f660a34b54d92f7d09cf
treedcf6fca1fb4ddff0ae6f2503329230bd08de1f83
parent5da76e94c4b8d40465a907fc3a151051e8021cdc
drm/i915: Make intel_display_suspend atomic, v2.

Calculate all state using a normal transition, but afterwards fudge
crtc->state->active back to its old value. This should still allow
state restore in setup_hw_state to work properly.

Calling intel_set_mode will cause intel_display_set_init_power to be
called, make sure init_power gets set again afterwards.

Changes since v1:
- Fix to compile with v2 of the patch that adds intel_display_suspend.
- Add intel_display_set_init_power.
- Set return value to int to allow error checking.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/intel_display.c
drivers/gpu/drm/i915/intel_drv.h