]> www.infradead.org Git - users/willy/xarray.git/commit
drm/vc4: drv: Use drm_dev_unplug
authorMaxime Ripard <maxime@cerno.tech>
Mon, 11 Jul 2022 17:38:43 +0000 (19:38 +0200)
committerMaxime Ripard <maxime@cerno.tech>
Wed, 13 Jul 2022 08:46:06 +0000 (10:46 +0200)
commit4a9551237d44cb051c0a3d7a18d11d6be27ef1d9
tree8b4b422b729c8cfa181cb45d2d6c88a42695698e
parent6cf61bf49c9bdb9ba2d33be812d90dd406326c6c
drm/vc4: drv: Use drm_dev_unplug

When our KMS driver is unbound, the device is no longer there but we might
still have users with an opened fd to the KMS device.

To avoid any issue in such a situation, every device access needs to be
protected by calls to drm_dev_enter() and drm_dev_exit(), and the driver
needs to call drm_dev_unplug().

We'll add calls to drm_dev_enter()/drm_dev_exit() in subsequent patches
changing the relevant drivers, but let's start by calling drm_dev_unplug().

Acked-by: Thomas Zimmermann <tzimmermann@suse.de>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://lore.kernel.org/r/20220711173939.1132294-14-maxime@cerno.tech
drivers/gpu/drm/vc4/vc4_drv.c