STRUCT VMW_KMS_DIRTY(9)
π struct vmw_kms_dirty(9) β like, the whole vibe
okay so bestie, welcome to the kernel API manual, section 9 β we're talking about struct vmw_kms_dirty, and honestly? it's giving closure structure goals. β¨
It's the closure struct that the vmw_kms_helper_dirty function passes around. Think of it as the lil group chat that everybody in the helper/callback friend group keeps replying in. π«Ά
β¨ SYNOPSIS β¨
like, the whole shape of it, no cap:
struct vmw_kms_dirty {
void (*fifo_commit)(struct vmw_kms_dirty *);
void (*clip)(struct vmw_kms_dirty *);
size_t fifo_reserve_size;
struct vmw_private *dev_priv;
struct vmw_display_unit *unit;
void *cmd;
struct drm_crtc *crtc;
u32 num_hits;
s32 fb_x;
s32 fb_y;
s32 unit_x1;
s32 unit_y1;
s32 unit_x2;
s32 unit_y2;
};
π Members π
okay so here's who's who in the struct, and who sets them up, because that part matters SO much:
fifo_commitβ a callback that gets called once per display unit, right after all the clip rects are done. This function's whole job is to commit the fifo space that the helper reserved. Set up by the caller. πclipβ a callback called for each cliprect on each display unit. Set up by the caller. literally her moment.fifo_reserve_sizeβ the fifo size that the helper should try to allocate for each display unit. Set up by the caller. πdev_privβ pointer to the device private. Set up by the helper. slay.unitβ the current display unit. Set up by the helper before a call toclip. π¦cmdβ the allocated fifo space. Set up by the helper before the firstclipcall. main character energy fr.crtcβ the crtc for which we're building the dirty commands. πΈnum_hitsβ number of clip rect commands for this display unit. Cleared by the helper before the firstclipcall, then updated by the clip callback. teamwork!fb_xβ the clip rect's left side, in framebuffer coordinates.fb_yβ the clip rect's right side, in framebuffer coordinates. (yep, "right" β that's literally what it says π)unit_x1β the clip rect's left side, in crtc coordinates.unit_y1β the clip rect's top side, in crtc coordinates. βunit_x2β the clip rect's right side, in crtc coordinates.unit_y2β the clip rect's bottom side, in crtc coordinates. π
π Description π
so the helper updates the clip rect coordinates on every single clip call β that's the whole loop, bestie. π₯
also, heads up: this may be derived from if more info needs to be passed between the helper caller and the helper callbacks. iykyk β plan accordingly. π
π SEE ALSO π
go check out the kernel file ./drivers/gpu/drm/vmwgfx/vmwgfx_kms.h struct vmw_du_update_plane(9), struct vmw_du_update_plane_surface(9), struct vmw_du_update_plane_buffer(9), and vmw_du_translate_to_crtc(9) β the whole friend group, fr fr. π§
okay and that's the page!! π this one lives out of ./drivers/gpu/drm/vmwgfx, dated October 2026 β bye bestie, go commit that fifo space πβ¨
π¦ 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