zynqmp_disp..._drm_formats(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… zynqmp_disp_layer_drm_formats β€” a Kernel API Manual moment πŸŽ€

okay so bestie, we're in the Kernel API Manual today (yes, the zynqmp_disp..._drm_formats(9) one, iykyk) and honestly? this little function is doing the most for you. let's get into it πŸ’–


✨ NAME ✨

zynqmp_disp_layer_drm_formats β€” literally just returns the DRM formats that a layer supports. that's it. that's the whole job. icon behaviour 🫢


🌸 SYNOPSIS 🌸

u32 * zynqmp_disp_layer_drm_formats (struct zynqmp_disp_layer *layer ,
unsigned int *num_formats );

like, yes, the formatting is a little crunchy, no cap β€” but it's exactly what's in the source so we're keeping it periodt πŸ’…


πŸ¦‹ ARGUMENTS πŸ¦‹

  • layer β€” the layer. your main character, fr. everything happens through her.
  • num_formats β€” a pointer to the returned number of formats. so you hand over a pointer, the function writes the count in there, and then you know how many formats you're dealing with. simple slay ✨

πŸ’€ NOTE πŸ’€

okay this is important so listen up bestie πŸ™ˆ β€” this function doesn't make sense for live video layers and will always return an empty list in those cases. like, it's giving "wrong tool for the job" energy.

if you actually want the list of media bus formats supported by the live video input layer, you need a different function entirely: zynqmp_disp_live_layer_formats. use that one. she's the one you want for live video 🧚


πŸ‘‘ RETURN πŸ‘‘

a newly allocated u32 array that stores all the DRM formats supported by the layer. so like, fresh array, all yours, treat her right πŸŽ€

and the number of formats in that array? that comes back to you through the num_formats argument. two-for-one deal, we love to see it πŸ’–


🌈 SEE ALSO 🌈

okay this list is long and honestly it ate. here's everyone in the group chat 🫢


and that's the whole page bestie, you're officially caught up πŸ’œ

this little gem lives over in ./drivers/gpu/drm/xlnx and the version/date on it is October 2026, filed under zynqmp_disp..._drm_formats(9) β€” so yeah, go forth and format responsibly, mwah πŸ’‹βœ¨πŸŽ€

πŸ“¦ where this page comes from