drm_mode_addfb(9)
π drm_mode_addfb(9) π
okay so real talk, this is a page straight outta the Kernel API Manual and it's about drm_mode_addfb β the vibe is very "let me add a framebuffer to your graphics config bestie" β¨
π NAME π
drm_mode_addfb β add an FB to the graphics configuration π
β SYNOPSIS β
int drm_mode_addfb (struct drm_device *dev , struct drm_mode_fb_cmd *or
, struct drm_file *file_priv );
like, that's the whole signature, no cap π«Ά
πΈ ARGUMENTS πΈ
devβ the drm device for the ioctl πorβ pointer to the request structure (yes it's literally namedor, iconic)file_privβ the drm file π
π¦ DESCRIPTION π¦
So you wanna add a new FB to the specified CRTC, given a user request? slay, that's literally what this does π
Important lore tho: this is the original addfb ioctl, and it only supported RGB formats. that's the whole reason drm_mode_addfb2(9) exists, iykyk π
It's called by the user via ioctl, or by an in-kernel client. both valid, both main character energy β¨
π₯ RETURN π₯
Zero on success, negative errno on failure. simple as that, fr fr π
π SEE ALSO π
- Kernel file
./drivers/gpu/drm/drm_framebuffer.c overview(9)drm_mode_addfb2(9)drm_mode_rmfb(9)drm_mode_getfb(9)drm_mode_getfb2_ioctl(9)drm_mode_dirtyfb_ioctl(9)drm_fb_release(9)drm_framebuffer_init(9)drm_framebuffer_lookup(9)drm_framebuffer_unregister_private(9)drm_framebuffer_cleanup(9)drm_framebuffer_remove(9)
okay that's the whole page bestie, go forth and add those framebuffers π§ββοΈ
this lil love letter to graphics config lives in ./drivers/gpu/drm, dated October 2026 β mwah, bye! πππ
π¦ 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