drm/vc4: hdmi: Switch to device-managed CEC initialization
authorMaxime Ripard <maxime@cerno.tech>
Mon, 11 Jul 2022 17:39:12 +0000 (19:39 +0200)
committerMaxime Ripard <maxime@cerno.tech>
Wed, 13 Jul 2022 08:46:10 +0000 (10:46 +0200)
commit015653f7af7cb7fa56e9a88af2a15c814a39b6b4
tree445f0b937f690919b945738a8730f32d6cd41c0f
parent59f9d46af43c884b92f690934263196387437c7e
drm/vc4: hdmi: Switch to device-managed CEC initialization

The current code to unregister our CEC device needs to be undone manually
when we remove the HDMI driver.

Since the CEC framework will allocate its main structure, and will defer
its deallocation to when the last user will have closed it, we don't really
need to take any particular measure to prevent any use-after-free and can
thus use any managed action.

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