From patchwork Mon Nov 30 13:53:24 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 57452 Delivered-To: patch@linaro.org Received: by 10.112.155.196 with SMTP id vy4csp1486428lbb; Mon, 30 Nov 2015 05:54:16 -0800 (PST) X-Received: by 10.98.73.133 with SMTP id r5mr69692679pfi.160.1448891636089; Mon, 30 Nov 2015 05:53:56 -0800 (PST) Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTP id ht11si10564096pac.98.2015.11.30.05.53.55; Mon, 30 Nov 2015 05:53:56 -0800 (PST) Received-SPF: pass (google.com: domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Authentication-Results: mx.google.com; spf=pass (google.com: domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id CD0C26E5B0; Mon, 30 Nov 2015 05:53:53 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mailout4.w1.samsung.com (mailout4.w1.samsung.com [210.118.77.14]) by gabe.freedesktop.org (Postfix) with ESMTPS id 168E86E5AF for ; Mon, 30 Nov 2015 05:53:50 -0800 (PST) Received: from eucpsbgm2.samsung.com (unknown [203.254.199.245]) by mailout4.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NYM000T9RXP7HB0@mailout4.w1.samsung.com> for dri-devel@lists.freedesktop.org; Mon, 30 Nov 2015 13:53:49 +0000 (GMT) X-AuditID: cbfec7f5-f79b16d000005389-d3-565c54ed840e Received: from eusync2.samsung.com ( [203.254.199.212]) by eucpsbgm2.samsung.com (EUCPMTA) with SMTP id 5B.68.21385.DE45C565; Mon, 30 Nov 2015 13:53:49 +0000 (GMT) Received: from amdc1339.digital.local ([106.116.147.30]) by eusync2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0NYM007NRRXFE700@eusync2.samsung.com>; Mon, 30 Nov 2015 13:53:49 +0000 (GMT) From: Marek Szyprowski To: dri-devel@lists.freedesktop.org, linux-samsung-soc@vger.kernel.org Subject: [PATCH v2 09/22] drm/exynos: mixer: enable video overlay plane only when VP is available Date: Mon, 30 Nov 2015 14:53:24 +0100 Message-id: <1448891617-18830-10-git-send-email-m.szyprowski@samsung.com> X-Mailer: git-send-email 1.9.2 In-reply-to: <1448891617-18830-1-git-send-email-m.szyprowski@samsung.com> References: <1448891617-18830-1-git-send-email-m.szyprowski@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrFLMWRmVeSWpSXmKPExsVy+t/xK7pvQ2LCDE4+YrO4te4cq8XGGetZ La58fc9msfPBLnaLSfcnsFi8ebuGyeLFvYssFq9fGFrMOL+PyWLtkbvsFjMmv2SzaFv9gdVi 1a4/jA68Hjtn3WX3uN99nMnj3zF2jy39QN7OSXuZPPq2rGL0+LxJLoA9issmJTUnsyy1SN8u gSuj++kv9oJG9orfBzcyNzB+Ye1i5OSQEDCReDznAhOELSZx4d56ti5GLg4hgaWMEvcuboBy mpgkvu35CFbFJmAo0fW2iw3EFhFwk2g6PBNsErPAYWaJw1PrQGxhgWSJ1ccWgtWzCKhKNH37 zg5i8wp4SmxevxFqm5zE/5crwGxOoPiTs6fBaoQEPCQ2zDjGNIGRdwEjwypG0dTS5ILipPRc I73ixNzi0rx0veT83E2MkBD9uoNx6TGrQ4wCHIxKPLwSZtFhQqyJZcWVuYcYJTiYlUR4A01j woR4UxIrq1KL8uOLSnNSiw8xSnOwKInzztz1PkRIID2xJDU7NbUgtQgmy8TBKdXAKL2wsf3j o1/anqIlzD/vSZc5d3tF9AWq5N48ue5n+eOZdbfZv1kL+KzzO/ykKuRq7StFof5H/Dm/TRUU DrC+9z6/YEX/mct/tizglGP5duL/Lnu3kxO0Kru33HGJ323SwVUjxnN2T0oPt0HNfoGZiZu3 qn5rTpip5hrmMPGWDJ/r38s3J84uU2Ipzkg01GIuKk4EAA0VuepNAgAA Cc: Javier Martinez Canillas , Krzysztof Kozlowski , Bartlomiej Zolnierkiewicz , Seung-Woo Kim , Andrzej Hajda , Tobias Jakobi , Marek Szyprowski X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Video overlay plane should be registered only when suitable hardware sub-block (Video Processor) is available. Signed-off-by: Marek Szyprowski Reviewed-by: Gustavo Padovan --- drivers/gpu/drm/exynos/exynos_mixer.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c b/drivers/gpu/drm/exynos/exynos_mixer.c index 84ee3396c429..8d2ce13eb725 100644 --- a/drivers/gpu/drm/exynos/exynos_mixer.c +++ b/drivers/gpu/drm/exynos/exynos_mixer.c @@ -1167,6 +1167,9 @@ static int mixer_bind(struct device *dev, struct device *manager, void *data) const uint32_t *formats; unsigned int fcount; + if (zpos == VP_DEFAULT_WIN && !ctx->vp_enabled) + continue; + if (zpos < VP_DEFAULT_WIN) { formats = mixer_formats; fcount = ARRAY_SIZE(mixer_formats);