From patchwork Thu Feb 16 10:24:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sascha Hauer X-Patchwork-Id: 13142840 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9D7D2C61DA4 for ; Thu, 16 Feb 2023 10:25:07 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 940ED10ED0E; Thu, 16 Feb 2023 10:25:06 +0000 (UTC) Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by gabe.freedesktop.org (Postfix) with ESMTPS id 99F9910ED0E for ; Thu, 16 Feb 2023 10:25:03 +0000 (UTC) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pSbRd-0001Qi-OT; Thu, 16 Feb 2023 11:24:53 +0100 Received: from [2a0a:edc0:0:1101:1d::28] (helo=dude02.red.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1pSbRY-005Kis-6l; Thu, 16 Feb 2023 11:24:49 +0100 Received: from sha by dude02.red.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1pSbRY-002Sfc-OD; Thu, 16 Feb 2023 11:24:48 +0100 From: Sascha Hauer To: dri-devel@lists.freedesktop.org Subject: [PATCH v6 0/4] drm/rockchip: dw_hdmi: Add 4k@30 support Date: Thu, 16 Feb 2023 11:24:43 +0100 Message-Id: <20230216102447.582905-1-s.hauer@pengutronix.de> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: sha@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: dri-devel@lists.freedesktop.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Dan Johansen , Sascha Hauer , Sandy Huang , linux-rockchip@lists.infradead.org, FUKAUMI Naoki , Michael Riesch , kernel@pengutronix.de, Robin Murphy Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" One small fix compared to the last version, when checking for valid resolutions I accidently compared the current mode width with the maximum allowed height which resulted in wrong resolutions being discarded. Changes since v5: - Fix wrong check width vs. height Changes since v4: - Use struct vop_reg to store resolutions - Only check for valid clock rates when clock != NULL Changes since v3: - Add patch to limit VOP resolutions to hardware capabilities Changes since v2: - Use correct register values for mpll_cfg - Add patch to discard modes we cannot achieve Changes since v1: - Allow non standard clock rates only on Synopsys phy as suggested by Robin Murphy Sascha Hauer (4): drm/rockchip: vop: limit maximium resolution to hardware capabilities drm/rockchip: dw_hdmi: relax mode_valid hook drm/rockchip: dw_hdmi: Add support for 4k@30 resolution drm/rockchip: dw_hdmi: discard modes with unachievable pixelclocks drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c | 41 ++++++++++++++++---- drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 15 +++++++ drivers/gpu/drm/rockchip/rockchip_drm_vop.h | 6 +++ drivers/gpu/drm/rockchip/rockchip_drm_vop2.h | 5 --- drivers/gpu/drm/rockchip/rockchip_vop_reg.c | 18 +++++++++ 5 files changed, 73 insertions(+), 12 deletions(-)