STRUCT DRM_SHADOW_PLANE_STATE(9)
π¦ struct drm_shadow_plane_state(9) β the glow-up π
okay so bestie, welcome to the struct drm_..._plane_state(9) page (that's the manual name, we're keeping it iconic), and honestly? this one's a little gem. it's from the Kernel API Manual, and it's all about giving shadow-buffer planes their moment. β¨
πΈ NAME πΈ
struct drm_shadow_plane_state β literally the plane state for planes that have shadow buffers. that's it, that's the vibe. π
β¨ SYNOPSIS β¨
here's the structure, exactly as it lives, no edits, no cap:
struct drm_shadow_plane_state {
struct drm_plane_state base;
struct drm_format_conv_state fmtcnv_state;
struct iosys_map map[DRM_FORMAT_MAX_PLANES];
struct iosys_map data[DRM_FORMAT_MAX_PLANES];
};
look at her. so organized. main character energy fr fr. π
π«Ά Members π«Ά
baseβ the plane state itself. the blueprint, the foundation, the base if you will. πfmtcnv_stateβ the format-conversion state. and lowkey there's a lot going on here:- it's per-plane state for format conversion.
- it holds flags for copying shadow buffers into backend storage.
- it also holds temporary storage for format conversion. like a lil scratchpad, but make it DRM. π
mapβ mappings of the plane's framebuffer BOs in to kernel address space.
heads up bestie: the memory mappings stored inmapshould be established in the plane'sprepare_fbcallback, and removed in thecleanup_fbcallback. set them up, tear them down β no leaving them lying around, that's not the vibe. π
dataβ the address of each framebuffer BO's data.
this is the address of the data stored in each mapping. and here's the catch: this is different for framebuffers with non-zero offset fields. so like, don't assume it's just the mapping address, okay? β
π Description π
so, for planes that use a shadow buffer, struct drm_shadow_plane_state provides the regular plane state plus mappings of the shadow buffer into kernel address space. the regular state ate, and the mappings came along for the ride. periodt. π₯
π SEE ALSO π
- Kernel file
./include/drm/drm_gem_atomic_helper.h DRM_SHADOW_PLANE_MAX_WIDTH(9)DRM_SHADOW_PLANE_MAX_HEIGHT(9)to_drm_shadow_plane_state(9)DRM_GEM_SHADOW_PLANE_FUNCS(9)DRM_GEM_SHADOW_PLANE_HELPER_FUNCS(9)DRM_GEM_SIMPLE_DISPLAY_PIPE_SHADOW_PLANE_FUNCS(9)
okay that's the whole page! π this lil baddie lives over in ./include/drm, dated October 2026, and it's filed under struct drm_..._plane_state(9). go forth and shadow-buffer responsibly, bestie β you've got this. π¦πΈπ«Ά
π¦ 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