drm_kunit_he...tc_connector(9)
β¨ drm_kunit_he...tc_connector β¨
okay so bestie, this one lives in the Kernel API Manual (yes, the whole kernel, it's a lot, we love that for it) π
πΈ NAME πΈ
drm_kunit_helper_enable_crtc_connector β literally just enables a CRTC -> Connector output. that's the whole vibe β¨
π SYNOPSIS π
int drm_kunit_helper_enable_crtc_connector (struct kunit *test , struct
drm_device *drm , struct drm_crtc *crtc , struct drm_connector
*connector , const struct drm_display_mode *mode , struct
drm_modeset_acquire_ctx *ctx );
like yeah, six arguments, she's high-maintenance but she delivers π«Ά
π¦ ARGUMENTS π¦
testβ the test context object, aka the main character of this whole operation πdrmβ the device to alloc the plane for, no big deal, just the entire DRM device πcrtcβ the CRTC you're enabling πconnectorβ the Connector you're enabling, they come as a pair, iykyk π₯modeβ the display mode to configure the CRTC with βctxβ locking context, pls respect her π
π DESCRIPTION π
so the way this works: drm_kunit_helper_enable_crtc_connector creates an atomic update that enables the route from crtc to connector, with the given mode. like it's literally building the whole path, no cap π§
β οΈ and here's the part where you gotta pay attention bestie: you get a pointer to the new CRTC, or anERR_PTRotherwise. and if the error returned isEDEADLK, the entire atomic sequence must be restarted. like fully restart it. no shortcuts, fr fr π
π SEE ALSO π
- Kernel file
./drivers/gpu/drm/tests/drm_kunit_helpers.c drm_kunit_helper_alloc_device(9)drm_kunit_helper_free_device(9)drm_kunit_helper_atomic_state_alloc(9)drm_kunit_helper_create_primary_plane(9)drm_kunit_helper_create_crtc(9)drm_kunit_add_mode_destroy_action(9)drm_kunit_display_mode_from_cea_vic(9)
all her friends, go say hi, they ate π
and that's the page!! sign-off time: this lil beauty comes from ./drivers/gpu/drm/tests, dated October 2026, and the page is drm_kunit_he...tc_connector(9) just in case you forgot where you were π slay, go write some kunit tests, ily π
<!--chunk:9-->
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms