gma500: Fix crash on D2700MUD and various other boards

The recent changes led to the lid timer code being run on various devices.
It does no harm on most but isn't needed. It also calls unconditionally
into the Poulsbo backlight code which goes bang on Cedartrail.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
Alan Cox
2012-05-14 12:03:34 +01:00
committed by Dave Airlie
parent f9aa76a852
commit 6607e02401
2 changed files with 12 additions and 4 deletions

View File

@@ -208,11 +208,11 @@ static int psb_driver_unload(struct drm_device *dev)
psb_modeset_cleanup(dev);
if (dev_priv) {
psb_intel_opregion_fini(dev);
psb_lid_timer_takedown(dev_priv);
if (dev_priv->ops->chip_teardown)
dev_priv->ops->chip_teardown(dev);
psb_intel_opregion_fini(dev);
psb_do_takedown(dev);
@@ -336,8 +336,6 @@ static int psb_driver_load(struct drm_device *dev, unsigned long chipset)
PSB_WSGX32(0x30000000, PSB_CR_BIF_3D_REQ_BASE);
acpi_video_register();
if (dev_priv->opregion.lid_state)
psb_lid_timer_init(dev_priv);
ret = drm_vblank_init(dev, dev_priv->num_pipe);
if (ret)