STRUCT DRM_SHADOW_PLANE_STATE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ 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 in map should be established in the plane's prepare_fb callback, and removed in the cleanup_fb callback. 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 🌈


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