Message ID | 20200515095118.2743122-31-emil.l.velikov@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Fareless gem_free_object | expand |
Am Freitag, 15. Mai 2020, 11:51:10 CEST schrieb Emil Velikov: > From: Emil Velikov <emil.velikov@collabora.com> > > Spelling out _unlocked for each and every driver is a annoying. > Especially if we consider how many drivers, do not know (or need to) > about the horror stories involving struct_mutex. > > Just drop the suffix. It makes the API cleaner. > > Done via the following script: > > __from=drm_gem_object_put_unlocked > __to=drm_gem_object_put > for __file in $(git grep --name-only $__from); do > sed -i "s/$__from/$__to/g" $__file; > done > > Cc: Sandy Huang <hjc@rock-chips.com> > Cc: "Heiko Stübner" <heiko@sntech.de> > Cc: David Airlie <airlied@linux.ie> > Signed-off-by: Emil Velikov <emil.velikov@collabora.com> > Acked-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Heiko Stuebner <heiko@sntech.de>
diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_fb.c b/drivers/gpu/drm/rockchip/rockchip_drm_fb.c index 9b13c784b347..3aa37e177667 100644 --- a/drivers/gpu/drm/rockchip/rockchip_drm_fb.c +++ b/drivers/gpu/drm/rockchip/rockchip_drm_fb.c @@ -88,7 +88,7 @@ rockchip_fb_create(struct drm_device *dev, struct drm_file *file, struct drm_gem_object **obj = afbc_fb->base.obj; for (i = 0; i < info->num_planes; ++i) - drm_gem_object_put_unlocked(obj[i]); + drm_gem_object_put(obj[i]); kfree(afbc_fb); return ERR_PTR(ret); diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_gem.c b/drivers/gpu/drm/rockchip/rockchip_drm_gem.c index 0d1884684dcb..b9275ba7c5a5 100644 --- a/drivers/gpu/drm/rockchip/rockchip_drm_gem.c +++ b/drivers/gpu/drm/rockchip/rockchip_drm_gem.c @@ -392,7 +392,7 @@ rockchip_gem_create_with_handle(struct drm_file *file_priv, goto err_handle_create; /* drop reference from allocate - handle holds it now. */ - drm_gem_object_put_unlocked(obj); + drm_gem_object_put(obj); return rk_obj;