drm_crtc_legacy_gamma_set(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… drm_crtc_legacy_gamma_set(9) πŸ’…

okay so bestie, welcome to another page of the Kernel API Manual β€” this one's all about drm_crtc_legacy_gamma_set, and honestly it's giving "vintage but still relevant" ✨


🌸 NAME 🌸

drm_crtc_legacy_gamma_set β€” set the legacy gamma correction table 🎨


⭐ SYNOPSIS ⭐

int drm_crtc_legacy_gamma_set (struct drm_crtc *crtc , u16 *red , u16
*green , u16 *blue , u32 size , struct drm_modeset_acquire_ctx *ctx );

like, that's the whole vibe check right there πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • crtc β€” the CRTC object πŸ’– (the main character of this function, fr)
  • red β€” the red correction table πŸ“
  • green β€” the green correction table 🧚
  • blue β€” the blue correction table πŸ¦‹
  • size β€” size of the tables, no cap
  • ctx β€” the lock acquire context πŸ”’

πŸ¦‹ DESCRIPTION πŸ¦‹

So what does this actually do? It implements support for the legacy gamma correction table for drivers that have set drm_crtc_funcs.gamma_set β€” or that support color management through the DEGAMMA_LUT/GAMMA_LUT properties πŸ‘‘ like, both paths are valid, slay.

If you wanna know how atomic color management and gamma tables work in general, check out drm_crtc_enable_color_mgmt and the containing chapter β€” it's required reading, iykyk πŸ“š

And here's the actual tea: this function sets the gamma using drm_crtc_funcs.gamma_set if set, or alternatively using the crtc color management properties. Two routes, one destination, iconic behavior fr fr πŸ’…


🌈 SEE ALSO 🌈

the whole friend group showed up for this one, so let's give them all a shoutout 🫢


and that's the whole page, bestie β€” go set some gamma tables, you've got this πŸ’œ

okay bye ily, this one came from ./drivers/gpu/drm and it's dated October 2026, and yeah the page name is literally drm_crtc_legacy_gamma_set(9) β€” iconic from start to finish, periodt πŸŽ€βœ¨

πŸ“¦ where this page comes from