diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2010-08-03 11:59:48 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2010-08-03 11:59:48 +0000 |
commit | ede3e612e2f75814674a3d59db92555c37d359f7 (patch) | |
tree | 460e0cb32975dc1e5992a238769404aaeda0117a | |
parent | 0054e3c6e28f0db5a6e6dd1605f975a166e19aa8 (diff) |
Save/restore BLC_HIST_CTL as well at suspend/resume time; which allows
the x40 LCD to light up after unsuspend.
https://bugzilla.kernel.org/attachment.cgi?id=23409
https://bugzilla.kernel.org/show_bug.cgi?id=10985
ok oga
-rw-r--r-- | sys/dev/pci/drm/i915_drv.c | 2 | ||||
-rw-r--r-- | sys/dev/pci/drm/i915_drv.h | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/sys/dev/pci/drm/i915_drv.c b/sys/dev/pci/drm/i915_drv.c index 3bc7222a443..ea88e97fa89 100644 --- a/sys/dev/pci/drm/i915_drv.c +++ b/sys/dev/pci/drm/i915_drv.c @@ -5477,6 +5477,7 @@ inteldrm_save_display(struct inteldrm_softc *dev_priv) dev_priv->savePP_CONTROL = I915_READ(PP_CONTROL); dev_priv->savePFIT_PGM_RATIOS = I915_READ(PFIT_PGM_RATIOS); dev_priv->saveBLC_PWM_CTL = I915_READ(BLC_PWM_CTL); + dev_priv->saveBLC_HIST_CTL = I915_READ(BLC_HIST_CTL); if (IS_I965G(dev_priv)) dev_priv->saveBLC_PWM_CTL2 = I915_READ(BLC_PWM_CTL2); if (IS_MOBILE(dev_priv) && !IS_I830(dev_priv)) @@ -5571,6 +5572,7 @@ inteldrm_restore_display(struct inteldrm_softc *dev_priv) } else { I915_WRITE(PFIT_PGM_RATIOS, dev_priv->savePFIT_PGM_RATIOS); I915_WRITE(BLC_PWM_CTL, dev_priv->saveBLC_PWM_CTL); + I915_WRITE(BLC_HIST_CTL, dev_priv->saveBLC_HIST_CTL); I915_WRITE(PP_ON_DELAYS, dev_priv->savePP_ON_DELAYS); I915_WRITE(PP_OFF_DELAYS, dev_priv->savePP_OFF_DELAYS); I915_WRITE(PP_DIVISOR, dev_priv->savePP_DIVISOR); diff --git a/sys/dev/pci/drm/i915_drv.h b/sys/dev/pci/drm/i915_drv.h index 36b3e4d442e..2063f969788 100644 --- a/sys/dev/pci/drm/i915_drv.h +++ b/sys/dev/pci/drm/i915_drv.h @@ -1536,6 +1536,8 @@ read64(struct inteldrm_softc *dev_priv, bus_size_t off) #define BACKLIGHT_DUTY_CYCLE_SHIFT (0) #define BACKLIGHT_DUTY_CYCLE_MASK (0xffff) +#define BLC_HIST_CTL 0x61260 + /* TV port control */ #define TV_CTL 0x68000 /** Enables the TV encoder */ |