From patchwork Mon Nov 12 18:41:09 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 10679143 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 99AFF14BA for ; Mon, 12 Nov 2018 18:41:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 739DE2A3BE for ; Mon, 12 Nov 2018 18:41:31 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 635162A3FA; Mon, 12 Nov 2018 18:41:31 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 574C32A3BE for ; Mon, 12 Nov 2018 18:41:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=MEGfQvY4npK6AkaA2LMHE3SL7zdbFx5jO4yAgkoyvsc=; b=M/2 +oN7sJTa1mgKKZMRa3xYVK87UQEcYUPEP/C0gMriUvP6pMKjaCzdmMfWBA/twZnMELEqycGH8H7Pj W7HN7TYc59YD9yamMJSemYka6VV5MFyYtUOSEooDOBlkIM2KD/5T/fDu2Q8/I+5h9aG9NwS6KJKgf 4Ri63rXI/4NQwe7vvTkhNXy03OiYvllayfm1OZ2MsuvfhGz/cGOqwkHw7RWgvqIUAZ7SY+8TzfERy 2mPEHgAu0vANFVmOdljs9Nc+De/LvghPHf3SSOiGbk3WpXM6lK7VLP8xePNzGDWxYxeLhIgxbQDOI 557cbz4udsGGv4YWXt4DKgqjTINiN7g==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gMH9N-0005nZ-VK; Mon, 12 Nov 2018 18:41:29 +0000 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gMH9K-0005mb-RQ for linux-amlogic@lists.infradead.org; Mon, 12 Nov 2018 18:41:28 +0000 Received: by mail-wr1-x443.google.com with SMTP id u9-v6so10534771wrr.0 for ; Mon, 12 Nov 2018 10:41:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=iuAX5TYkA3a3jJaJm+03pdZzSpJ7OiC/CynShEo+Iy4=; b=KTV4uo5X+KCYBd7YptF9gsa7JNL2YfLnmQcAP7xvFTxUqVrkqUdvc48uGn9ZGOeitp D7gN7PURRLA7QN4NU5UQcL5pZDF43JDUZ0biRGlsE1RNA43Z5/ckQuw1aBtnHopGHIhD 71mfa/IpcTpUAl3IBbJdQAMjH4aeiEKTkhzxwNlWfKJZG2CgwZ5GOlK9VSSfSlSA0vzY osWR6RUB+wKfs2x5tctSCcBV5AlwMqKifZTpK8szli7CX7CIdayHgE5bRnB062dNpFzF em6cX3W8qZggiQsnkzLWqWnMcmwk2UBlJnW5RugH5M8ZIS80tmlAzsSSJW3g4efw+Dbw wsWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=iuAX5TYkA3a3jJaJm+03pdZzSpJ7OiC/CynShEo+Iy4=; b=OeaTloJVVeeiUf0pSQWyk8abbvmIq49aPKBW8jU812K7LAEG2J88/LNXgpsfUmOl+a t0CcVBMGohZs/qQN55lNZ16jegMyFfO4gDW79qesPRztZabIK8wjTsz2At4gXo1KQ6yb TJEx8BfZA7F8Y9HQAivT03qUy3m5Mkee0lhyXuCML0k6riVJG3gV1GjvaSHUUeyudtSL tAH0OH9rshPiIKpPPRi3RwjXLs1X1lS3CTh/LibANienEettTzOdjcGFBp1MazAvNrT9 19YDwON8PA7Ky8/s4szZMERRlQJYf16BkMg7u87YSYCAeqVrcn/wqDOzbI25lxMhHCJO o0Ng== X-Gm-Message-State: AGRZ1gLcfEZQ/C4a5BQvhHF8T+3Z26ejugx4Ay7i1tdJxrqAhqliuNSe M55NWskUS16t46BcbXnStgwp7g== X-Google-Smtp-Source: AJdET5dpmxVrYLXxDsd/bDPpuhPisHwFp8cCm4mnSBlTTfZf0jLHWgDdMxsIUxeTWFtwhmx9C9r5OA== X-Received: by 2002:adf:b6a8:: with SMTP id j40-v6mr1927777wre.55.1542048074434; Mon, 12 Nov 2018 10:41:14 -0800 (PST) Received: from localhost.localdomain (12.red-95-121-90.dynamicip.rima-tde.net. [95.121.90.12]) by smtp.gmail.com with ESMTPSA id h198-v6sm9750315wmd.31.2018.11.12.10.41.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 12 Nov 2018 10:41:13 -0800 (PST) From: Jorge Ramirez-Ortiz To: jramirez@baylibre.com, narmstrong@baylibre.com, airlied@linux.ie, carlo@caione.org, khilman@baylibre.com Subject: [PATCH] drm/meson: venc: dmt mode must use encp Date: Mon, 12 Nov 2018 19:41:09 +0100 Message-Id: <1542048069-22603-1-git-send-email-jramirez@baylibre.com> X-Mailer: git-send-email 2.7.4 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181112_104126_928734_3AEE51B2 X-CRM114-Status: GOOD ( 10.83 ) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org MIME-Version: 1.0 Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Jorge Ramirez-Ortiz The video mode for DMT is only populated to support encp. Signed-off-by: Jorge Ramirez-Ortiz Acked-by: Neil Armstrong --- drivers/gpu/drm/meson/meson_venc.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/meson/meson_venc.c b/drivers/gpu/drm/meson/meson_venc.c index 514245e..acbbad3 100644 --- a/drivers/gpu/drm/meson/meson_venc.c +++ b/drivers/gpu/drm/meson/meson_venc.c @@ -854,6 +854,13 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic, unsigned int sof_lines; unsigned int vsync_lines; + /* Use VENCI for 480i and 576i and double HDMI pixels */ + if (mode->flags & DRM_MODE_FLAG_DBLCLK) { + hdmi_repeat = true; + use_enci = true; + venc_hdmi_latency = 1; + } + if (meson_venc_hdmi_supported_vic(vic)) { vmode = meson_venc_hdmi_get_vic_vmode(vic); if (!vmode) { @@ -865,13 +872,7 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic, } else { meson_venc_hdmi_get_dmt_vmode(mode, &vmode_dmt); vmode = &vmode_dmt; - } - - /* Use VENCI for 480i and 576i and double HDMI pixels */ - if (mode->flags & DRM_MODE_FLAG_DBLCLK) { - hdmi_repeat = true; - use_enci = true; - venc_hdmi_latency = 1; + use_enci = false; } /* Repeat VENC pixels for 480/576i/p, 720p50/60 and 1080p50/60 */