From patchwork Tue Jan 17 16:25:03 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Liviu Dudau X-Patchwork-Id: 91702 Delivered-To: patch@linaro.org Received: by 10.182.3.34 with SMTP id 2csp526454obz; Tue, 17 Jan 2017 08:40:07 -0800 (PST) X-Received: by 10.99.174.4 with SMTP id q4mr46472260pgf.178.1484671207568; Tue, 17 Jan 2017 08:40:07 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b3si25444444plb.131.2017.01.17.08.40.07; Tue, 17 Jan 2017 08:40:07 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751403AbdAQQj7 (ORCPT + 25 others); Tue, 17 Jan 2017 11:39:59 -0500 Received: from fw-tnat.cambridge.arm.com ([217.140.96.140]:53818 "EHLO cam-smtp0.cambridge.arm.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751227AbdAQQj5 (ORCPT ); Tue, 17 Jan 2017 11:39:57 -0500 X-Greylist: delayed 873 seconds by postgrey-1.27 at vger.kernel.org; Tue, 17 Jan 2017 11:39:36 EST Received: from e110455-lin.cambridge.arm.com (e110455-lin.cambridge.arm.com [10.2.131.175]) by cam-smtp0.cambridge.arm.com (8.13.8/8.13.8) with ESMTP id v0HGOvUn022705; Tue, 17 Jan 2017 16:24:58 GMT From: Liviu Dudau To: Brian Starkey Cc: Mali DP Maintainers , David Airlie , DRI devel , LKML , Liviu Dudau Subject: [PATCH 4/8] drm: mali-dp: Don't force source size == crtc size Date: Tue, 17 Jan 2017 16:25:03 +0000 Message-Id: <20170117162507.31961-5-Liviu.Dudau@arm.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170117162507.31961-1-Liviu.Dudau@arm.com> References: <20170117162507.31961-1-Liviu.Dudau@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Brian Starkey Remove the check enforcing that src_w and src_h match crtc_w and crtc_h, as this prevents rotation from working. The check was intended to disallow scaling, but drm_plane_helper_check_state() does that for us, while also taking rotation into account, so the removed check was redundant in any case. Signed-off-by: Brian Starkey Signed-off-by: Liviu Dudau --- drivers/gpu/drm/arm/malidp_planes.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) -- 2.11.0 diff --git a/drivers/gpu/drm/arm/malidp_planes.c b/drivers/gpu/drm/arm/malidp_planes.c index f684fe4a80d2..69eba71253c9 100644 --- a/drivers/gpu/drm/arm/malidp_planes.c +++ b/drivers/gpu/drm/arm/malidp_planes.c @@ -135,8 +135,7 @@ static int malidp_de_plane_check(struct drm_plane *plane, if ((state->crtc_w > mp->hwdev->max_line_size) || (state->crtc_h > mp->hwdev->max_line_size) || (state->crtc_w < mp->hwdev->min_line_size) || - (state->crtc_h < mp->hwdev->min_line_size) || - (state->crtc_w != src_w) || (state->crtc_h != src_h)) + (state->crtc_h < mp->hwdev->min_line_size)) return -EINVAL; /* packed RGB888 / BGR888 can't be rotated or flipped */