Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 166009
b: refs/heads/master
c: 06891e2
h: refs/heads/master
i:
  166007: 777983d
v: v3
  • Loading branch information
Jesse Barnes committed Sep 17, 2009
1 parent 7ba823d commit 2090189
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ba1234d17b3b1fe7087defb191a3c705f208aca6
refs/heads/master: 06891e27a9b5dba5268bb80e41a283f51335afe7
4 changes: 4 additions & 0 deletions trunk/drivers/gpu/drm/i915/i915_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@ static int i915_suspend(struct drm_device *dev, pm_message_t state)
pci_set_power_state(dev->pdev, PCI_D3hot);
}

dev_priv->suspended = 1;

return 0;
}

Expand Down Expand Up @@ -124,6 +126,8 @@ static int i915_resume(struct drm_device *dev)
drm_helper_resume_force_mode(dev);
}

dev_priv->suspended = 0;

return ret;
}

Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/gpu/drm/i915/i915_drv.h
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,7 @@ typedef struct drm_i915_private {
struct workqueue_struct *wq;

/* Register state */
bool suspended;
u8 saveLBB;
u32 saveDSPACNTR;
u32 saveDSPBCNTR;
Expand Down
5 changes: 4 additions & 1 deletion trunk/drivers/gpu/drm/i915/intel_lvds.c
Original file line number Diff line number Diff line change
Expand Up @@ -651,8 +651,11 @@ static int intel_lid_notify(struct notifier_block *nb, unsigned long val,
container_of(nb, struct drm_i915_private, lid_notifier);
struct drm_device *dev = dev_priv->dev;

if (acpi_lid_open())
if (acpi_lid_open() && !dev_priv->suspended) {
mutex_lock(&dev->mode_config.mutex);
drm_helper_resume_force_mode(dev);
mutex_unlock(&dev->mode_config.mutex);
}

drm_sysfs_hotplug_event(dev_priv->dev);

Expand Down

0 comments on commit 2090189

Please sign in to comment.