mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 19:08:57 +09:00
drm/rockchip: vop: set vop min size to 4x4
Change-Id: Ib00c223b4df34cf0821e19fb23b54c1496bc2b3a Signed-off-by: Sandy Huang <hjc@rock-chips.com>
This commit is contained in:
@@ -1663,6 +1663,14 @@ static int vop_plane_atomic_check(struct drm_plane *plane,
|
||||
vop = to_vop(crtc);
|
||||
vop_data = vop->data;
|
||||
|
||||
if (state->src_w >> 16 < 4 || state->src_h >> 16 < 4 ||
|
||||
state->crtc_w < 4 || state->crtc_h < 4) {
|
||||
DRM_ERROR("Invalid size: %dx%d->%dx%d, min size is 4x4\n",
|
||||
state->src_w >> 16, state->src_h >> 16,
|
||||
state->crtc_w, state->crtc_h);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (drm_rect_width(src) >> 16 > vop_data->max_input.width ||
|
||||
drm_rect_height(src) >> 16 > vop_data->max_input.height) {
|
||||
DRM_ERROR("Invalid source: %dx%d. max input: %dx%d\n",
|
||||
|
||||
Reference in New Issue
Block a user