diff options
| author | Nicholas Kazlauskas <nicholas.kazlauskas@amd.com> | 2019-04-18 19:42:32 +0300 |
|---|---|---|
| committer | Alex Deucher <alexander.deucher@amd.com> | 2019-05-24 20:20:49 +0300 |
| commit | e371e19c10a264bd72c2ff1d21e2167b994710d1 (patch) | |
| tree | b43447e697feab45fa03251d7548b57ceddb81f1 /tools/perf/scripts/python/syscall-counts.py | |
| parent | 1352c779cb74d427f4150cbe779a2f7886f70cae (diff) | |
| download | linux-e371e19c10a264bd72c2ff1d21e2167b994710d1.tar.xz | |
drm/amd/display: Disable cursor when offscreen in negative direction
[Why]
When x or y is negative we set the x and y values to 0 and compensate
with a positive cursor hotspot in DM since DC expects positive cursor
values.
When x or y is less than or equal to the maximum cursor width or height
the cursor hotspot is clamped so the hotspot doesn't exceed the
cursor size:
if (x < 0) {
xorigin = min(-x, amdgpu_crtc->max_cursor_width - 1);
x = 0;
}
if (y < 0) {
yorigin = min(-y, amdgpu_crtc->max_cursor_height - 1);
y = 0;
}
This incorrectly forces the cursor to be at least 1 pixel on the screen
in either direction when x or y is sufficiently negative.
[How]
Just disable the cursor when it goes far enough off the screen in one
of these directions.
This fixes kms_cursor_crc@cursor-256x256-offscreen.
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Sun peng Li <Sunpeng.Li@amd.com>
Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'tools/perf/scripts/python/syscall-counts.py')
0 files changed, 0 insertions, 0 deletions
