drm/i915: disable interrupts earlier in the driver unload code
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 24 Apr 2013 09:13:35 +0000 (11:13 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 24 Apr 2013 11:06:01 +0000 (13:06 +0200)
commitfd0c06420d39958032655a04cfd194d5a7b38f83
treec3c6c25b1a06a1f4b201f071375c3ef797fc02f7
parentd20d4f0ca343c0b76567d46fcc343c165e8d7c43
drm/i915: disable interrupts earlier in the driver unload code

Our rps code relies on the interrupts being off to prevent re-arming
of the work items at inopportune moments.

Also drop the redundant cancel_work for the main rps work,
disable_gt_powersave already takes care of that.

Finally add a WARN_ON to ensure we obey that piece of ordering
constraint. Long term I want to lock down the setup/teardown code in a
similar way to how we painstakingly check modeset sequence constraints
already.

v2: Disable polling after hpd handling is shut down - since Egbert's
hpd irq storm handling the hotplug work can re-arm the polling
handler. Spotted by Jani Nikula.

Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: Jani Nikula <jani.nikula@intel.com>
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_display.c
drivers/gpu/drm/i915/intel_pm.c