From: Alan Cox Date: Wed, 25 Apr 2012 13:36:13 +0000 (+0100) Subject: gma500: Fix leak of uncached page X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=1896344b181549cea0ab38a810f4f8efcd6ecafb;p=openwrt%2Fstaging%2Fblogic.git gma500: Fix leak of uncached page This was reported a long time ago (and I apologize to whoever it was that reported it as I've lost the original report). Signed-off-by: Alan Cox Signed-off-by: Dave Airlie --- diff --git a/drivers/gpu/drm/gma500/psb_drv.c b/drivers/gpu/drm/gma500/psb_drv.c index c34adf9d910a..d5a6eab8227e 100644 --- a/drivers/gpu/drm/gma500/psb_drv.c +++ b/drivers/gpu/drm/gma500/psb_drv.c @@ -246,6 +246,7 @@ static int psb_driver_unload(struct drm_device *dev) } psb_gtt_takedown(dev); if (dev_priv->scratch_page) { + set_pages_wb(dev_priv->scratch_page, 1); __free_page(dev_priv->scratch_page); dev_priv->scratch_page = NULL; }