amdgpu_dm_cr..._cursor_mode(9)
π amdgpu_dm_cr..._cursor_mode(9) β a Kernel API Manual moment
okay so bestie, this is a page straight out of the Kernel API Manual (yes, that's the manual name, we're being fancy today π), and the star of the show is amdgpu_dm_crtc_get_cursor_mode. Cursor drama incoming, iykyk.
β¨ NAME β¨
amdgpu_dm_crtc_get_cursor_mode β literally just figuring out which cursor mode the crtc needs, no cap π
πΈ SYNOPSIS πΈ
int amdgpu_dm_crtc_get_cursor_mode (struct amdgpu_device *adev , struct
drm_atomic_commit *state , struct dm_crtc_state *dm_crtc_state , enum
amdgpu_dm_cursor_mode *cursor_mode );
π¦ ARGUMENTS π¦
adevβ the amdgpu device itself, main character energy πstateβ the DRM atomic statedm_crtc_stateβ the amdgpu state for the CRTC that's holding the cursor (yes, the cursor lives there, we checked π«Ά)cursor_modeβ this one's the output: it returns the required cursor mode ondm_crtc_state
π DESCRIPTION π
So what this bad boy actually does: it gets whether the cursor should be enabled in native mode or overlay mode on the dm_crtc_state. Two modes, one vibe check, and it picks. π
Here's the tea though β the cursor should be enabled in overlay mode if there exists an underlying plane (one the cursor may be blended on top of, bestie) that is any of these:
- YUV formatted π³
- scaled differently from the cursor
- has a color pipeline active
Any one of those and it's overlay mode, periodt.
β οΈ little heads up: since zpos info is required, drm_atomic_normalize_zpos must be called before you call this function. Not optional, not a suggestion, it's giving prerequisite π
β RETURN β
0 on success π β or an error code if getting the cursor plane state failed π (rude of it, honestly).
π₯ SEE ALSO π₯
- Kernel file
./drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_cursor.c Cursor Modes - Native vs Overlay(9)dm_plane_color_pipeline_active(9)
mmm okay that's the whole page, you ate that bestie π this iconic little number came from ./drivers/gpu/drm/amd/display/..., dated October 2026, and titled amdgpu_dm_cr..._cursor_mode(9) β literally the manual's own signature sign-off, slay β¨π
π¦ 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