drm_connector_dynamic_init(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… drm_connector_dynamic_init(9) β€” Init a preallocated dynamic connector

okay so bestie, this is the drm_connector_dynamic_init(9) page from the Kernel API Manual, and it’s literally all about getting a preallocated dynamic connector ready without chaos ✨


🌸 NAME 🌸

drm_connector_dynamic_init β€” init a preallocated dynamic connector 🫢


✨ SYNOPSIS ✨

int drm_connector_dynamic_init (struct drm_device *dev , struct
       drm_connector *connector , const struct drm_connector_funcs *funcs , int
       connector_type , struct i2c_adapter *ddc );

πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the DRM device, bestie πŸ’–
  • connector β€” the connector you’re initialising, no cap
  • funcs β€” the callbacks for this connector πŸ‘‘
  • connector_type β€” the user visible type of the connector
  • ddc β€” pointer to the associated ddc adapter πŸ¦‹

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so this function initialises a preallocated dynamic connector πŸ’… Connectors should be subclassed as part of driver connector objects. The connector structure should not be allocated with devm_kzalloc. periodt.

Drivers should call this for dynamic connectors which can be hotplugged after drm_dev_register has been called already, e.g. DP MST connectors. For all other β€” static β€” connectors, drivers should call one of the drm_connector_init*()/drmm_connector_init*() functions. iykyk 🌈

After calling this function the drivers must call drm_connector_dynamic_register. no skipping, bestie 😭

To remove the connector the driver must call drm_connector_unregister followed by drm_connector_put. Putting the last reference will call the driver’s drm_connector_funcs.destroy hook, which in turn must call drm_connector_cleanup and free the connector structure. that’s the whole lifecycle vibe πŸ”₯


🌟 RETURN 🌟

Zero on success, error code on failure. slay πŸ’–


πŸ‘‘ SEE ALSO πŸ‘‘

okay the whole related-calls group chat is here, fr fr 🫢


Source/version: ./drivers/gpu/drm Β· date: October 2026 Β· title: drm_connector_dynamic_init(9). slay, bye bestie! πŸŽ€βœ¨

πŸ“¦ where this page comes from