of_get_drm_display_mode(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸŽ€ NAME πŸŽ€

of_get_drm_display_mode β€” get a drm_display_mode from devicetree. This is the of_get_drm_display_mode(9) page from the Kernel API Manual, and yes bestie, the name is a whole mouthful but we move. πŸ’…


✨ SYNOPSIS ✨

int of_get_drm_display_mode (struct device_node *np , struct drm_display_mode *dmode , u32 *bus_flags , int index );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • np β€” the device_node with the timing specification, iykyk.
  • dmode β€” will be set to the return value. Yes, literally that, keep up. πŸ’–
  • bus_flags β€” information about pixelclk, sync and DE polarity.
  • index β€” index into the list of display timings in devicetree.

🌸 DESCRIPTION 🌸

Okay so heads up: this function is expensive, and it should only be used if only one mode is to be read from DT. If you need multiple modes, do not spam this one β€” start with of_get_display_timings and work with that instead. That's the whole vibe check. 🫢

πŸ”₯ RETURN πŸ”₯

0 on success, a negative errno code when no of videomode node was found. That's it, that's the tea. 😭

🌈 SEE ALSO 🌈

Kernel file: ./drivers/gpu/drm/drm_modes.c β€” that's where the source lives, bestie.

The whole squad:


kisses and fairy dust 🧚 β€” this page is from source/version ./drivers/gpu/drm, dated October 2026, and it's the of_get_drm_display_mode(9) page. bye bestie πŸ’–

πŸ“¦ where this page comes from