drm_rotation_simplify(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

okay so bestie, welcome to the drm_rotation_simplify(9) page from the Kernel API Manual β€” manual name folded in right here like a lil ribbon πŸŽ€. This one is all about taking a rotation and trying to simplify it into a form the hardware actually supports, and it is lowkey iconic for that. πŸ’…

🌸 NAME 🌸

  • drm_rotation_simplify β€” Try to simplify the rotation ✨

✨ SYNOPSIS ✨

here’s the signature, copied exactly so nobody comes for me:

unsigned int drm_rotation_simplify (unsigned int rotation , unsigned int
       supported_rotations );

πŸŽ€ ARGUMENTS πŸŽ€

  • rotation β€” Rotation to be simplified. That’s the one you’re trying to glow-up. πŸ’–
  • supported_rotations β€” Supported rotations. The set your hardware can actually serve. πŸ‘‘

πŸ¦‹ DESCRIPTION πŸ¦‹

Attempt to simplify the rotation to a form that is supported. e.g. if the hardware supports everything except DRM_MODE_REFLECT_X, one could call this function like this:

drm_rotation_simplify(rotation, DRM_MODE_ROTATE_0 | DRM_MODE_ROTATE_90 |
       DRM_MODE_ROTATE_180 | DRM_MODE_ROTATE_270 | DRM_MODE_REFLECT_Y);

to eliminate the DRM_MODE_REFLECT_X flag. So yeah, it’s giving β€œmake it fit the supported list” energy. 🌈

⚠️ important bestie: depending on what kind of transforms the hardware supports, this function may not be able to produce a supported transform, so the caller should check the result afterwards. No cap, check that result. πŸ’€

πŸ”₯ SEE ALSO πŸ”₯

the whole squad of related kernel docs, fr fr:


later, bestie 🫢 β€” source/version: ./drivers/gpu/drm; date: October 2026. drm_rotation_simplify(9) out. πŸ’–βœ¨

πŸ“¦ where this page comes from