summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorMaxime Ripard <maxime@cerno.tech>2022-07-11 19:38:39 +0200
committerMaxime Ripard <maxime@cerno.tech>2022-07-13 10:46:06 +0200
commit35a3b82f1bdd60e454de34f984a3f09b38f64b61 (patch)
tree14136ce24bec20be56af16a601a9f8b4ca0ff73f /include
parentdrm/connector: Check for destroy implementation (diff)
downloadlinux-35a3b82f1bdd60e454de34f984a3f09b38f64b61.tar.xz
linux-35a3b82f1bdd60e454de34f984a3f09b38f64b61.zip
drm/connector: Introduce drmm_connector_init
Unlike other DRM entities, there's no helper to create a DRM-managed initialisation of a connector. Let's create an helper to initialise a connector that would be passed as an argument, and handle the cleanup through a DRM-managed action. Acked-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: Thomas Zimmermann <tzimmermann@suse.de> Signed-off-by: Maxime Ripard <maxime@cerno.tech> Link: https://lore.kernel.org/r/20220711173939.1132294-10-maxime@cerno.tech
Diffstat (limited to 'include')
-rw-r--r--include/drm/drm_connector.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h
index a1705d6b3fba..2c6fa746efac 100644
--- a/include/drm/drm_connector.h
+++ b/include/drm/drm_connector.h
@@ -1677,6 +1677,11 @@ int drm_connector_init_with_ddc(struct drm_device *dev,
const struct drm_connector_funcs *funcs,
int connector_type,
struct i2c_adapter *ddc);
+int drmm_connector_init(struct drm_device *dev,
+ struct drm_connector *connector,
+ const struct drm_connector_funcs *funcs,
+ int connector_type,
+ struct i2c_adapter *ddc);
void drm_connector_attach_edid_property(struct drm_connector *connector);
int drm_connector_register(struct drm_connector *connector);
void drm_connector_unregister(struct drm_connector *connector);