drm/omap: clear omap_obj->paddr in omap_gem_put_paddr()
authorTomi Valkeinen <tomi.valkeinen@ti.com>
Wed, 3 Sep 2014 19:25:53 +0000 (19:25 +0000)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Tue, 24 Mar 2015 11:33:24 +0000 (13:33 +0200)
Clear omap_obj's paddr when unmapping the memory, so that it's easier to
catch bad use of the paddr.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
drivers/gpu/drm/omapdrm/omap_gem.c

index aeb91ed653c9f8d2e410a6b95ed7e194168ef508..9b250c93b046ea9e30fac31bba9d87f119ef5ba1 100644 (file)
@@ -828,6 +828,7 @@ int omap_gem_put_paddr(struct drm_gem_object *obj)
                                dev_err(obj->dev->dev,
                                        "could not release unmap: %d\n", ret);
                        }
+                       omap_obj->paddr = 0;
                        omap_obj->block = NULL;
                }
        }