summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/display/dc/dc.h
diff options
context:
space:
mode:
authorNikola Cornij <nikola.cornij@amd.com>2021-01-22 06:35:54 +0300
committerAlex Deucher <alexander.deucher@amd.com>2021-02-02 20:12:22 +0300
commit40d916a2602c8920e0f04a49abfd1ff7c1e54e91 (patch)
treeffb2e442eb0d84a03898d7a29680d9c82419dae9 /drivers/gpu/drm/amd/display/dc/dc.h
parente2dcd9b8b803b927b4cbc59d91c4088334a248bb (diff)
downloadlinux-40d916a2602c8920e0f04a49abfd1ff7c1e54e91.tar.xz
drm/amd/display: Reject too small viewport size when validating plane
[why] Overlay won't move to a new positon if viewport size is smaller than what can be handled. It'd either disappear or stay at the old position. This condition is for example hit if overlay is moved too much outside of left or top edge of the screen, but it applies to any non-cursor plane type. [how] Reject this contidion at validation time. This gives the calling level a chance to handle this gracefully and avoid inconsistent behaivor. Signed-off-by: Nikola Cornij <nikola.cornij@amd.com> Reviewed-by: Nicholas Kazlauskas <Nicholas.Kazlauskas@amd.com> Acked-by: Anson Jacob <Anson.Jacob@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/dc.h')
-rw-r--r--drivers/gpu/drm/amd/display/dc/dc.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h
index d5105924c9e0..be9adddfac96 100644
--- a/drivers/gpu/drm/amd/display/dc/dc.h
+++ b/drivers/gpu/drm/amd/display/dc/dc.h
@@ -48,6 +48,7 @@
#define MAX_PLANES 6
#define MAX_STREAMS 6
#define MAX_SINKS_PER_LINK 4
+#define MIN_VIEWPORT_SIZE 12
/*******************************************************************************
* Display Core Interfaces