On Mon, 2008-11-17 at 18:14 +0800, Li Peng wrote:
> This patch restore HWS_PGA for device who don't use gtt mapped hardware
> status page.
> It is to fix the suspend/resume failure of xf86-video-intel dri2 branch
> on 945GME, as the dri2 branch doesn't call I830Resume() to restore
> hardware status page anymore and we need to handle this in
> i915_gem_entervt_ioctl()

This should also be saved/restored in i915_suspend.c so that it works
correctly in the absence of the X Server doing the enter/leavevt path.

> Peng
> diff --git a/drivers/gpu/drm/i915/i915_gem.c
> b/drivers/gpu/drm/i915/i915_gem.c
> index a15b098..b6b451a 100644
> --- a/drivers/gpu/drm/i915/i915_gem.c
> +++ b/drivers/gpu/drm/i915/i915_gem.c
> @@ -2924,8 +2924,13 @@ i915_gem_init_hws(struct drm_device *dev)
>       /* If we need a physical address for the status page, it's already
>        * initialized at driver load time.
>        */
> -     if (!I915_NEED_GFX_HWS(dev))
> +     if (!I915_NEED_GFX_HWS(dev)) {
> +             if (dev_priv->mm.suspended) {
> +                     I915_WRITE(HWS_PGA, dev_priv->dma_status_page);
> +                     I915_READ(HWS_PGA); /* posting read */
> +             }
>               return 0;
> +     }
>  
>       obj = drm_gem_object_alloc(dev, 4096);
>       if (obj == NULL) {
> 
> 
> _______________________________________________
> Intel-gfx mailing list
> [EMAIL PROTECTED]
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
-- 
Eric Anholt
[EMAIL PROTECTED]                         [EMAIL PROTECTED]


Attachment: signature.asc
Description: This is a digitally signed message part

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
--
_______________________________________________
Dri-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to