drm/arm/malidp: use drmm_* to allocate driver structures
authorDanilo Krummrich <dakr@redhat.com>
Wed, 26 Oct 2022 15:59:30 +0000 (17:59 +0200)
committerLiviu Dudau <liviu.dudau@arm.com>
Wed, 16 Nov 2022 10:33:39 +0000 (10:33 +0000)
commitaefae8719a9aaede5032ca7331fc3cf65fd7ac7f
treec78531a1b2c89c398f3d4040ecf3faee61d6b48a
parent0e308efe232afdec35d508f5dfae52f03d50efca
drm/arm/malidp: use drmm_* to allocate driver structures

Use drm managed resources to allocate driver structures and get rid of
the deprecated drm_dev_alloc() call and replace it with
devm_drm_dev_alloc().

This also serves as preparation to get rid of drm_device->dev_private
and to fix use-after-free issues on driver unload.

Signed-off-by: Danilo Krummrich <dakr@redhat.com>
Signed-off-by: Liviu Dudau <liviu.dudau@arm.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20221026155934.125294-2-dakr@redhat.com
drivers/gpu/drm/arm/malidp_drv.c
drivers/gpu/drm/arm/malidp_drv.h