]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amd/display: Only enable cursor on pipes that need it
authorNicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Thu, 30 Jan 2020 18:29:05 +0000 (13:29 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 4 Feb 2020 15:32:22 +0000 (10:32 -0500)
commit90fa66cea9b130e2d21620917a98d9046707a922
tree36da2dc6d479b0920f17aa56885e2c4c8f2af734
parentb2ca2cf0930a1a24a6e67519b19ec4df28b34bd1
drm/amd/display: Only enable cursor on pipes that need it

[Why]
In current code we're essentially drawing the cursor on every pipe
that contains it. This only works when the planes have the same
scaling for src to dest rect, otherwise we'll get "double cursor" where
one cursor is incorrectly filtered and offset from the real position.

[How]
Without dedicated cursor planes on DCN we require at least one pipe
that matches the scaling of the current timing.

This is an optimization and workaround for the most common case where
the top-most plane is not scaled but the bottom-most plane is scaled.

Whenever a pipe has a parent pipe in the blending tree whose recout
fully contains the current pipe we can disable the pipe.

This only applies when the pipe is actually visible of course.

Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c