diff options
author | Thomas Zimmermann <tzimmermann@suse.de> | 2022-03-08 22:52:17 +0300 |
---|---|---|
committer | Patrik Jakobsson <patrik.r.jakobsson@gmail.com> | 2022-03-16 19:42:21 +0300 |
commit | 6069fd815d287e786a5ac1b0f875fa92aac798ff (patch) | |
tree | d9a129bca4e5e4373dcafd94b99ab5a8becce44d /drivers/gpu/drm/gma500/psb_drv.c | |
parent | 97bd66c46d8bfbc02406d848ebb53c6a2992e03f (diff) | |
download | linux-6069fd815d287e786a5ac1b0f875fa92aac798ff.tar.xz |
drm/gma500: Cleanup GTT uninit and error handling
Replace psb_gtt_takedown() with finalizer function that is only called
for unloading the driver. Use roll-back pattern for error handling in
psb_gtt_init() and _resume(). Also fixes a bug where vmap_addr was never
unmapped.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Acked-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220308195222.13471-8-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/gma500/psb_drv.c')
-rw-r--r-- | drivers/gpu/drm/gma500/psb_drv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/gma500/psb_drv.c b/drivers/gpu/drm/gma500/psb_drv.c index 2891a3dc8d2e..41be6e1ac7f9 100644 --- a/drivers/gpu/drm/gma500/psb_drv.c +++ b/drivers/gpu/drm/gma500/psb_drv.c @@ -192,7 +192,7 @@ static void psb_driver_unload(struct drm_device *dev) psb_mmu_driver_takedown(dev_priv->mmu); dev_priv->mmu = NULL; } - psb_gtt_takedown(dev); + psb_gtt_fini(dev); if (dev_priv->scratch_page) { set_pages_wb(dev_priv->scratch_page, 1); __free_page(dev_priv->scratch_page); |