drm_kms_helper_poll_init(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ drm_kms_helper_poll_init(9) ✨

okay bestie, welcome to the Kernel API Manual πŸ’– this one's a little function with a big job, and it lives at drm_kms_helper_poll_init(9) β€” say that five times fast, i dare you 🫢


🌸 NAME 🌸

drm_kms_helper_poll_init β€” initialize and enable output polling πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

void drm_kms_helper_poll_init (struct drm_device *dev );

literally just one arg, we love a low-effort signature πŸ‘‘


πŸ¦‹ ARGUMENTS πŸ¦‹

  • dev β€” a struct drm_device. that's it. that's the whole argument. she's the main character here πŸŽ€

πŸ’œ DESCRIPTION πŸ’œ

so this function initializes output polling support for dev, and then β€” plot twist β€” it also enables it. two things, one call, iconic behavior honestly ✨

here's the vibe: if your driver doesn't have reliable hotplug support in hardware (no cap, some hardware just doesn't come through for you 😭), you can lean on this helper infrastructure to regularly poll those connectors and peep whether their connection state changed. it's giving "i'll just check myself" energy πŸ™ˆ

drivers get to control which connectors actually get polled by setting the DRM_CONNECTOR_POLL_CONNECT and DRM_CONNECTOR_POLL_DISCONNECT flags. 🚩

⚠️ okay important one: on connectors where probing live outputs can result in visual distortion, drivers should not set the DRM_CONNECTOR_POLL_DISCONNECT flag, because that's exactly how you avoid the distortion. do not skip this, bestie πŸ’€

and for the connectors that have no flag at all, or only DRM_CONNECTOR_POLL_HPD set? they are completely ignored by the polling logic. not even a little bit polled. ghosted, fr fr πŸ«₯

also worth knowing: a connector can be both polled and probed from the hotplug handler β€” that's a real combo that's allowed, specifically in case the hotplug interrupt is known to be unreliable. belt and suspenders, we stan 🌈


🌟 SEE ALSO 🌟

the whole friend group, assembled 🫢 go say hi:


πŸ“ SIGN-OFF πŸ“

this page came straight out of ./drivers/gpu/drm, dated October 2026, and honestly? she ate. now go init some polling, bestie β€” ily, bye! πŸ’–βœ¨πŸ§šβ€β™€οΈ

πŸ“¦ where this page comes from