From patchwork Fri Dec 13 14:02:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 13907148 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 D15D4E77180 for ; Fri, 13 Dec 2024 14:03:37 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2E6FD10F034; Fri, 13 Dec 2024 14:03:37 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="ifNDwjN/"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3CE7610E43C for ; Fri, 13 Dec 2024 14:03:19 +0000 (UTC) Received: from [127.0.1.1] (91-157-155-49.elisa-laajakaista.fi [91.157.155.49]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 070099CE; Fri, 13 Dec 2024 15:02:41 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734098563; bh=avI8ClOrtHzD2SipA/Fyk+O8iRhwsleato1FpezpTWY=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=ifNDwjN/LxtUeUzL+ptdqI2vpnYnfvIOnMFRZ6co9OkGN9kFZ1liCgkaxvgf8FYA9 AatlpmgmFfEV1Kd20M0nQAoiMWh0YtjLYQOh270jm1bq1JuGB8/XZMUdvm970LhfKv Wi3dBwd8baDwJH155eB4CdE/JiH7dTyaEF91M0Io= From: Tomi Valkeinen Date: Fri, 13 Dec 2024 16:02:57 +0200 Subject: [PATCH v4 1/7] drm/rcar-du: dsi: Fix PHY lock bit check MIME-Version: 1.0 Message-Id: <20241213-rcar-gh-dsi-v4-1-f8e41425207b@ideasonboard.com> References: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> In-Reply-To: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> To: Laurent Pinchart , Kieran Bingham , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Michael Turquette , Stephen Boyd , LUU HOAI , Jagan Teki , Sam Ravnborg , Biju Das Cc: Laurent Pinchart , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart , linux-clk@vger.kernel.org, Tomi Valkeinen , stable@vger.kernel.org X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2124; i=tomi.valkeinen@ideasonboard.com; h=from:subject:message-id; bh=oDefLvswOZixERy//YecN6qGggsNckidLEErkzhvvTE=; b=owEBbQKS/ZANAwAIAfo9qoy8lh71AcsmYgBnXD6fqlh2cfKv9yKNYeS0tJuFhpEsxrdtsxzhY F238xpuTi6JAjMEAAEIAB0WIQTEOAw+ll79gQef86f6PaqMvJYe9QUCZ1w+nwAKCRD6PaqMvJYe 9bnGEACL6ZLqXvLPb7sYP9smLCn3LxfrWBClOxvCi771IIQyuaDPc9RMrfqwuPfm7J+PZN0bHqy wVVeqIUzN/SN8x9UIAW010anYsO9G8GGRVzdiVu/3p51N7oGTllBSb1c2rXdJCdtoH6kIQjLuLl 4hyHS+2WdjwZY3DwzI+V4R/DEgNSAm+QSF7j84bFdSNrnqLzbJJrHOUhWyzrkybK+n0lPW33QqI FsV5pl0s9wWM73upH2893MeiPk4oV4JLALSjPOKX+ff5EDkFuohrA/P+6tAz4HstpTUqGc5Obyr QAy7Fl5Y0PdDHP/IitrAzHM7bhtQUjC7OfhlZkBxIkVtKNYMserwpgaiy4OyTV+t0LebtR2WY9b M4JK5cZng4ffjgvfILzHuGJVCylUWeddRQefFBKJ57mughNB3vhfOdvEPeZcxu7JQOVlwYanj2Y zeY7KArEfTGaa7/yAYzn9ZkHHAoiligck3ib5ds1JjjxwIzWTvdyt8WEUafOBbsP5x5VDP8c6aS ddULNvbTBGR+zoxMrqUb0wPhFqcyVpyXUVTv/KgdZFyPtOKw/wCxPMeIACH9HkKUT3O+GQsSMfY avgsr7BlP79zkw1co3mUffrvRHPSvFvlcKe8dMP46pmk6UYmsSYW+UVeQ0JNUUY1lkH4BJOWjZf Jf5uRaEhkH9sgzg== X-Developer-Key: i=tomi.valkeinen@ideasonboard.com; a=openpgp; fpr=C4380C3E965EFD81079FF3A7FA3DAA8CBC961EF5 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Tomi Valkeinen The driver checks for bit 16 (using CLOCKSET1_LOCK define) in CLOCKSET1 register when waiting for the PPI clock. However, the right bit to check is bit 17 (CLOCKSET1_LOCK_PHY define). Not only that, but there's nothing in the documents for bit 16 for V3U nor V4H. So, fix the check to use bit 17, and drop the define for bit 16. Fixes: 155358310f01 ("drm: rcar-du: Add R-Car DSI driver") Fixes: 11696c5e8924 ("drm: Place Renesas drivers in a separate dir") Cc: stable@vger.kernel.org Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart Tested-by: Geert Uytterhoeven --- drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c | 2 +- drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c index 2dba7c5ffd2c..92f4261305bd 100644 --- a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c +++ b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c @@ -587,7 +587,7 @@ static int rcar_mipi_dsi_startup(struct rcar_mipi_dsi *dsi, for (timeout = 10; timeout > 0; --timeout) { if ((rcar_mipi_dsi_read(dsi, PPICLSR) & PPICLSR_STPST) && (rcar_mipi_dsi_read(dsi, PPIDLSR) & PPIDLSR_STPST) && - (rcar_mipi_dsi_read(dsi, CLOCKSET1) & CLOCKSET1_LOCK)) + (rcar_mipi_dsi_read(dsi, CLOCKSET1) & CLOCKSET1_LOCK_PHY)) break; usleep_range(1000, 2000); diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h index f8114d11f2d1..a6b276f1d6ee 100644 --- a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h +++ b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h @@ -142,7 +142,6 @@ #define CLOCKSET1 0x101c #define CLOCKSET1_LOCK_PHY (1 << 17) -#define CLOCKSET1_LOCK (1 << 16) #define CLOCKSET1_CLKSEL (1 << 8) #define CLOCKSET1_CLKINSEL_EXTAL (0 << 2) #define CLOCKSET1_CLKINSEL_DIG (1 << 2) From patchwork Fri Dec 13 14:02:58 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 13907141 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 6F165E7717D for ; Fri, 13 Dec 2024 14:03:22 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0020D10E43C; Fri, 13 Dec 2024 14:03:21 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="Ag8Arc1p"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8ECCB10E43C for ; Fri, 13 Dec 2024 14:03:20 +0000 (UTC) Received: from [127.0.1.1] (91-157-155-49.elisa-laajakaista.fi [91.157.155.49]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id B848DA98; Fri, 13 Dec 2024 15:02:43 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734098565; bh=DMH9kb64WnVAVtxcUTTPxPJIxU2uJoWDyUzVe2vOmFI=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=Ag8Arc1pFKN30PWkrzX+IlYvjku0c2AyhB8dCtZiIU6Ftsa4r/4+1WXVPFOcE59Ry RGxPdef+j9vpwy/cGBQID+Ji0L1nOLni+g4CAjPLsp1NYVwWFwGPjCTypvjfYlBhaE 2T9//HjJqsMGuqePv8DNwKHNQpw/2h/co63YL4Vs= From: Tomi Valkeinen Date: Fri, 13 Dec 2024 16:02:58 +0200 Subject: [PATCH v4 2/7] drm/rcar-du: Write DPTSR only if the second source exists MIME-Version: 1.0 Message-Id: <20241213-rcar-gh-dsi-v4-2-f8e41425207b@ideasonboard.com> References: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> In-Reply-To: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> To: Laurent Pinchart , Kieran Bingham , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Michael Turquette , Stephen Boyd , LUU HOAI , Jagan Teki , Sam Ravnborg , Biju Das Cc: Laurent Pinchart , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart , linux-clk@vger.kernel.org, Tomi Valkeinen X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2000; i=tomi.valkeinen@ideasonboard.com; h=from:subject:message-id; bh=ic1vAEEJzv9LWzHbe/oAaaiBIH9en2R++zJCqIckjhU=; b=owEBbQKS/ZANAwAIAfo9qoy8lh71AcsmYgBnXD6g+uCaGXeD3HQSWg6+b2hXl45qtMbcLQ3hR bpjtYagp/WJAjMEAAEIAB0WIQTEOAw+ll79gQef86f6PaqMvJYe9QUCZ1w+oAAKCRD6PaqMvJYe 9cIKD/9WA2btSlpmORr/DIwmTGaCGpjc5dayuUbBHZzNKFufCjEzN6k3DsHbZikaXb0d45qT8ff FDfX8eL7RSsih0AwoBmeCYqLlRW4oegCJ4spZ7ou1sDBfPAyf9nrlNFXiZuo4zOTbA17jz8JvFb uYdfJaTdKwFuuMoLlOZ+ZGnimsDNyu+wV1g3VObPF5t0Gn7Bq9R87XDQof6KQCtuO447QaF9zzU s8gXz8BDH3SDDK09DRLjzuUpJ9Vl+rUsTlkKFP3oyM5MGONl+NV5ujx/IGQ2BVkWS6QhjbTBz6Y JFDUTWXBoRkvurU1Qkh3JWHOrMtNDydPnUvc9Zrq/dHcNxcDH/U7J4j3wWH1rLFse6+EhmiFTmv ykNFB0UyPcVe3jIPNkyu5UY3MYXuCvip9tJasYoEO+viwbjlU3AmZiyEKZZz1Uae5M10GX8dgbV c2DvJ1BE/56nzxTgEJfg+fncyUcClbk/IlBhqJgEixWW/78bFsTnwjv0cCpKggoPyxBggVSx6ut baZTD4/mU0ysVx2yLF88Q7+gczC82GPc0KY6wBK8Jsy3n8xCnnTEhdAtOaPZSzUNIvwVCcwC+AK Q324Mlf/os76A9W0O4xSbH3aKKesahgNkz6dzGREzaV7qDCzOSMdEAzmhqLAyWyXGISQVCmj3d/ 5xsHtjCSyB2tahw== X-Developer-Key: i=tomi.valkeinen@ideasonboard.com; a=openpgp; fpr=C4380C3E965EFD81079FF3A7FA3DAA8CBC961EF5 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Tomi Valkeinen Currently the driver always writes DPTSR when setting up the hardware. However, writing the register is only meaningful when the second source for a plane is used, and the register is not even documented for SoCs that do not have the second source. So move the write behind a condition. Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart Tested-by: Laurent Pinchart # On R-Car M3-N --- drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c index 2ccd2581f544..1ec806c8e013 100644 --- a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c +++ b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c @@ -185,11 +185,21 @@ static void rcar_du_group_setup(struct rcar_du_group *rgrp) dorcr |= DORCR_PG1T | DORCR_DK1S | DORCR_PG1D_DS1; rcar_du_group_write(rgrp, DORCR, dorcr); - /* Apply planes to CRTCs association. */ - mutex_lock(&rgrp->lock); - rcar_du_group_write(rgrp, DPTSR, (rgrp->dptsr_planes << 16) | - rgrp->dptsr_planes); - mutex_unlock(&rgrp->lock); + /* + * DPTSR is used to select the source for the planes of a group. The + * first source is chosen by writing 0 to the respective bits, and this + * is always the default value of the register. In other words, writing + * DPTSR is only needed if the SoC supports choosing the second source. + * + * The SoCs documentations seems to confirm this, as the DPTSR register + * is not documented if only the first source exists on that SoC. + */ + if (rgrp->channels_mask & BIT(1)) { + mutex_lock(&rgrp->lock); + rcar_du_group_write(rgrp, DPTSR, (rgrp->dptsr_planes << 16) | + rgrp->dptsr_planes); + mutex_unlock(&rgrp->lock); + } } /* From patchwork Fri Dec 13 14:02:59 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 13907142 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 6AE6FE77180 for ; Fri, 13 Dec 2024 14:03:26 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E66F510F02C; Fri, 13 Dec 2024 14:03:25 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="PAgpesZM"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4B59810F01A for ; Fri, 13 Dec 2024 14:03:22 +0000 (UTC) Received: from [127.0.1.1] (91-157-155-49.elisa-laajakaista.fi [91.157.155.49]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 6AA11D53; Fri, 13 Dec 2024 15:02:45 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734098566; bh=yMXL7ef74+Rsd5fAmiBKorgMPkSnb9HmF+N5rIwhjCM=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=PAgpesZMmzADJifGEJTC+exrF4k2d/zpa0Wbi/S5nUZgdh3rpKc1vtd+Yu4/35mN1 LRRaeSoxzK4ewSd1AY6IvvkF4KL6cEQQDx64SCljxg9GJV8uR6TdZ+aDk8/k2vl10P Rjd0He0P/1qZg7c5bdEuGphfw2dY8AhJViol4DbI= From: Tomi Valkeinen Date: Fri, 13 Dec 2024 16:02:59 +0200 Subject: [PATCH v4 3/7] dt-bindings: display: renesas,du: Add missing maxItems MIME-Version: 1.0 Message-Id: <20241213-rcar-gh-dsi-v4-3-f8e41425207b@ideasonboard.com> References: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> In-Reply-To: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> To: Laurent Pinchart , Kieran Bingham , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Michael Turquette , Stephen Boyd , LUU HOAI , Jagan Teki , Sam Ravnborg , Biju Das Cc: Laurent Pinchart , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart , linux-clk@vger.kernel.org, Tomi Valkeinen X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1884; i=tomi.valkeinen@ideasonboard.com; h=from:subject:message-id; bh=v+qXxJbhngvJ+5f8hZKCC2lQ2TNaw5dkcLJWzHn5v0s=; b=owEBbQKS/ZANAwAIAfo9qoy8lh71AcsmYgBnXD6g3MHksETjLkCJlPbHtKr9YP1gT77uZzE1I vbgd5SHOh+JAjMEAAEIAB0WIQTEOAw+ll79gQef86f6PaqMvJYe9QUCZ1w+oAAKCRD6PaqMvJYe 9TSHEACKdkm6C4AH9LRaRdOlO6kqv7vz5TCD9OjUJSZNZbTcz969yDysspKzrWm/Th9P6KnTxeC Bgg/v+kDJjDQjjstiUv9WtDXvZ+pICEkehI3CBgBSwCRtovmRtAZ5Q8uEMdXjUlIMBqqFYe3SdU Rh11WDSvSYLDe91Nq+Zz+gAA3v+dq0xbVzOMjQa//itxom3LNjFCPxIIbZIPX83xp6gjF18vBL+ ikpzokPFtBV/CMctcyGZ9wul5ykGn+fIfrGozQ0pE79oy63RUqN5npjgHSJZXmRLlIg6Ovpujwk lxtWVNP2fyVuzFZiqQm2sKAnR1h1dqqvWZQz8hznbkhQIDgu+46AXf4+uNNT+w2qQ3A2Y2khZx3 ftAOyHJnaH98m4nsgcH2ZUjTzOOGi+jbD90BApFkcamY33jGCPK4D38qH5fO6WvYmrvB5/Fo+ox djoVWzYuB0DxDA1b14Ayl0PmviVedIzbMouYYxkF+EQ6OCbF47l8PRQNRAV5Ot9R47tEQCz7WrB Nn/iYEbRHNMWPyEzXAoDhcudbRJqK2o0Ur11iAdFfbwB9uZgVMdtZp+pAaVPmerf/4C0YZZjXxl 679TEz6I8uWM9D/XrTvO3AhC+dTldCs6P2MK5YbdCk+pfpzkkFHAcl6StGoa4fU+3FZjGsVx4Xm FZs9CFR57k8JMfw== X-Developer-Key: i=tomi.valkeinen@ideasonboard.com; a=openpgp; fpr=C4380C3E965EFD81079FF3A7FA3DAA8CBC961EF5 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Tomi Valkeinen The binding is missing maxItems for all renesas,cmms and renesas,vsps properties. As the amount of cmms or vsps is always a fixed amount, set the maxItems to match the minItems. Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart --- Documentation/devicetree/bindings/display/renesas,du.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Documentation/devicetree/bindings/display/renesas,du.yaml b/Documentation/devicetree/bindings/display/renesas,du.yaml index c5b9e6812bce..e5fbc4ffe29c 100644 --- a/Documentation/devicetree/bindings/display/renesas,du.yaml +++ b/Documentation/devicetree/bindings/display/renesas,du.yaml @@ -489,9 +489,11 @@ allOf: renesas,cmms: minItems: 4 + maxItems: 4 renesas,vsps: minItems: 4 + maxItems: 4 required: - clock-names @@ -558,9 +560,11 @@ allOf: renesas,cmms: minItems: 3 + maxItems: 3 renesas,vsps: minItems: 3 + maxItems: 3 required: - clock-names @@ -627,9 +631,11 @@ allOf: renesas,cmms: minItems: 3 + maxItems: 3 renesas,vsps: minItems: 3 + maxItems: 3 required: - clock-names @@ -684,6 +690,7 @@ allOf: renesas,vsps: minItems: 1 + maxItems: 1 required: - clock-names @@ -746,9 +753,11 @@ allOf: renesas,cmms: minItems: 2 + maxItems: 2 renesas,vsps: minItems: 2 + maxItems: 2 required: - clock-names @@ -799,6 +808,7 @@ allOf: renesas,vsps: minItems: 2 + maxItems: 2 required: - clock-names From patchwork Fri Dec 13 14:03:00 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 13907143 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 ED781E7717F for ; Fri, 13 Dec 2024 14:03:26 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 49B4A10F02E; Fri, 13 Dec 2024 14:03:26 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="OK/K0M/g"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id 092A210F01A for ; Fri, 13 Dec 2024 14:03:24 +0000 (UTC) Received: from [127.0.1.1] (91-157-155-49.elisa-laajakaista.fi [91.157.155.49]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 23C8DF89; Fri, 13 Dec 2024 15:02:47 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734098568; bh=s8GnwIastABqRYEgykdh0qV/3mI75TJf2ezU8ZRKyls=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=OK/K0M/gdrW8l2SKVhlE4xSB7HFjh3NAUDxd7Su+XtFDnpWo1NXFUctBuR1Mwp55Y UQGu/nqBUV+mKjLq1w7PVftoHrJGxu3tDzA+b3W8WYKz9/6db4ST9LNzBjXazOn0oW dPAu0wUOm1+jvUJQPT4zMw46uk3zelobtWFVEVCo= From: Tomi Valkeinen Date: Fri, 13 Dec 2024 16:03:00 +0200 Subject: [PATCH v4 4/7] dt-bindings: display: renesas,du: Add r8a779h0 MIME-Version: 1.0 Message-Id: <20241213-rcar-gh-dsi-v4-4-f8e41425207b@ideasonboard.com> References: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> In-Reply-To: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> To: Laurent Pinchart , Kieran Bingham , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Michael Turquette , Stephen Boyd , LUU HOAI , Jagan Teki , Sam Ravnborg , Biju Das Cc: Laurent Pinchart , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart , linux-clk@vger.kernel.org, Tomi Valkeinen X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2567; i=tomi.valkeinen@ideasonboard.com; h=from:subject:message-id; bh=DlMcRdYcnOPSOXZIM2VtaP0Ahd5x/Ya+ls1XSUX4y2M=; b=owEBbQKS/ZANAwAIAfo9qoy8lh71AcsmYgBnXD6glDgmqkhLH0IZeJC6ZrUOcPFWbnQ8ITbod zDTExHobMOJAjMEAAEIAB0WIQTEOAw+ll79gQef86f6PaqMvJYe9QUCZ1w+oAAKCRD6PaqMvJYe 9eQgD/0TndBrULvtWLewQlxlpLdHIAMKwdolvYhHdA0mb7+bQqGmB61hZi7nPPFJyH3z1IeqM9d jq1+D6h6xPtY8O5wa7ESWEelrLMnukisV7zv8+zGAeb3N7VOdS7qNdxhcYsMjMHfH7r3Xxkj+xX Ge1ttqhiNuVbhvi/Lm3A8QW2wD3NVWNTeL2GgawKFVrmK19QRQ6taIuY2oQ7vy8oV7AsW+FpWTB Zx5KPfhtGlqIrLU1r19bZuOt33em/6Qn9c+EsGIBTpORaaOxRqxqdEIUJKSt1xGR403MZIzGXz3 y35KGsiDWsdlXAtCzs9UqPv4Cesv4zJZQbKlG4eHfPIfE8EDrV0VXdt0N9nBiS99nwat5YbyAiW 8WR2ocArMjBg8vTB0eJHYlyVr5uGmVm4ddnpYXmLjzb8IvjFhNBW9EGO37DyThwztgE4EiX9fC4 TV/KJjGmWJZD9SXFqDdTKyxUV4uR5AhzBRQ/OnxBAkCEF5U5ky6mzEFDGuBhXWV8evWYj7gOdMq u43jWUskHcRYe5efqRzYtE5ZM1RCtT1bu0puJSyKmECmR/BWLeA/gSqnUAh+3lg3Errqo4fsy8o Zlfk0EiAN/EHQkiIyMLDZol01nqr/MUxo9VAo8nPH5g12EaaoQOtGAiaz1/JEzGEF6QQQeQDlmn /3NM6jTJpsvAChQ== X-Developer-Key: i=tomi.valkeinen@ideasonboard.com; a=openpgp; fpr=C4380C3E965EFD81079FF3A7FA3DAA8CBC961EF5 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Tomi Valkeinen Extend the Renesas DU display bindings to support the r8a779h0 V4M. Note that we remove the requirement for two ports from the global part of the bindings, as each conditional part defines the number of required ports already. This came up with r8a779h0 as it's the first one that has only one port. Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart Tested-by: Geert Uytterhoeven --- .../devicetree/bindings/display/renesas,du.yaml | 53 ++++++++++++++++++++-- 1 file changed, 49 insertions(+), 4 deletions(-) diff --git a/Documentation/devicetree/bindings/display/renesas,du.yaml b/Documentation/devicetree/bindings/display/renesas,du.yaml index e5fbc4ffe29c..1b4cd8fac825 100644 --- a/Documentation/devicetree/bindings/display/renesas,du.yaml +++ b/Documentation/devicetree/bindings/display/renesas,du.yaml @@ -41,6 +41,7 @@ properties: - renesas,du-r8a77995 # for R-Car D3 compatible DU - renesas,du-r8a779a0 # for R-Car V3U compatible DU - renesas,du-r8a779g0 # for R-Car V4H compatible DU + - renesas,du-r8a779h0 # for R-Car V4M compatible DU reg: maxItems: 1 @@ -69,10 +70,6 @@ properties: $ref: /schemas/graph.yaml#/properties/port unevaluatedProperties: false - required: - - port@0 - - port@1 - unevaluatedProperties: false renesas,cmms: @@ -817,6 +814,54 @@ allOf: - reset-names - renesas,vsps + - if: + properties: + compatible: + contains: + enum: + - renesas,du-r8a779h0 + then: + properties: + clocks: + items: + - description: Functional clock + + clock-names: + items: + - const: du.0 + + interrupts: + maxItems: 1 + + resets: + maxItems: 1 + + reset-names: + items: + - const: du.0 + + ports: + properties: + port@0: + description: DSI 0 + port@1: false + port@2: false + port@3: false + + required: + - port@0 + + renesas,vsps: + minItems: 1 + maxItems: 1 + + required: + - clock-names + - interrupts + - resets + - reset-names + - renesas,vsps + additionalProperties: false examples: From patchwork Fri Dec 13 14:03:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 13907146 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 172F9E7717F for ; Fri, 13 Dec 2024 14:03:32 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 24CA910F033; Fri, 13 Dec 2024 14:03:31 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="fyQmb9XB"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id BED2410F032 for ; Fri, 13 Dec 2024 14:03:25 +0000 (UTC) Received: from [127.0.1.1] (91-157-155-49.elisa-laajakaista.fi [91.157.155.49]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id D629C1449; Fri, 13 Dec 2024 15:02:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734098570; bh=7hzw0SzmxWLVIEQik4mqnwQiiO+6a15pjXhcBTuLaI8=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=fyQmb9XBr/KAVtLsxKMmpK5T7jynP6fNu5yVrokyFbxih2hAGPla4aDn8xDRMUi6N 8tvMWdmxemBINW6OC6POvx/bQeqMuHXMukZthtV6lw6nX5b3yKM+hkz62gupuyys1U dKDw2mtZI6mzTtoJ5p/H83qXAv8yDZPCQOBu+Ylw= From: Tomi Valkeinen Date: Fri, 13 Dec 2024 16:03:01 +0200 Subject: [PATCH v4 5/7] dt-bindings: display: bridge: renesas,dsi-csi2-tx: Add r8a779h0 MIME-Version: 1.0 Message-Id: <20241213-rcar-gh-dsi-v4-5-f8e41425207b@ideasonboard.com> References: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> In-Reply-To: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> To: Laurent Pinchart , Kieran Bingham , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Michael Turquette , Stephen Boyd , LUU HOAI , Jagan Teki , Sam Ravnborg , Biju Das Cc: Laurent Pinchart , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart , linux-clk@vger.kernel.org, Tomi Valkeinen , Krzysztof Kozlowski X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1073; i=tomi.valkeinen@ideasonboard.com; h=from:subject:message-id; bh=dTprj9jjuLmoedubnDT5F4e9cHFBPmdT8w1PeMV2wF8=; b=owEBbQKS/ZANAwAIAfo9qoy8lh71AcsmYgBnXD6hMnD+fNBuer1EFdM2qFSzwqoddiP7q/OFJ MHLM3o3Q5aJAjMEAAEIAB0WIQTEOAw+ll79gQef86f6PaqMvJYe9QUCZ1w+oQAKCRD6PaqMvJYe 9QQlD/9aI20lPyFuchw04t+kA5up3ZVXMi/KrRy4dcPnErcXfePBeF3TSXvA73kH5QXBal2O+0T /VYyYkrKw5YKybdqAVZP1WPPdV4akre0o0y9IKDQFias9lZyUvJImiM/ZHlEt+c0GrLWo3Yn5k8 hjk4I5+mu5MWNgzoLXsa+KBmtAYaMJ/wlthnu9nWxclbphDl9gZ7wxR/pk9uIgAUcHn7bMQ2kz3 I7YNx6ln5s1BFSBwNTiLvYDid5iBLmSL1uJe2HT0yrQrXKA9CLnqdrZDsTfYVLDDN7kofzQYxro vNNQGIE1IUtwEgtNFjJfkV+5n2jGJlquLVOynccuTqqQ1++iANMAw4rCA4VJWtlVVmoBNB0fU9T snsiP4XFffFg7B0kYwFxLNnM/ml7ojwojGxjeZdDUP8YUh53MOO2GKrPZ5hmRBimeEaXmRqUA0C Z/REmDCmxvApWrBclAVa+UC7lQY5XGfQMfUrR75ozMd6eLd2dPGB4ByyCwVZj6fxs5Zs/Vr0Wyu hu87KH2BqfX+qj5uWRXkKxhvB3SM6c1DXcwWrWdh9J3/ua2BpvY2Vp/FI8E9P3TAKCp8y+pSZSQ tdtkv6B2nNlNManlWiAR0KcUKDkikf/DdTUsikWBxF8FvB3dy4Gcqe1knyUvTagCiHIFOq4YiQV DKRlUGbw+pe+RCA== X-Developer-Key: i=tomi.valkeinen@ideasonboard.com; a=openpgp; fpr=C4380C3E965EFD81079FF3A7FA3DAA8CBC961EF5 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Tomi Valkeinen Extend the Renesas DSI display bindings to support the r8a779h0 V4M. Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart Acked-by: Krzysztof Kozlowski Tested-by: Geert Uytterhoeven --- .../devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml b/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml index d33026f85e19..c167795c63f6 100644 --- a/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml +++ b/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml @@ -19,6 +19,7 @@ properties: enum: - renesas,r8a779a0-dsi-csi2-tx # for V3U - renesas,r8a779g0-dsi-csi2-tx # for V4H + - renesas,r8a779h0-dsi-csi2-tx # for V4M reg: maxItems: 1 From patchwork Fri Dec 13 14:03:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 13907144 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 908C6E7717D for ; Fri, 13 Dec 2024 14:03:30 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0622210F031; Fri, 13 Dec 2024 14:03:30 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="Df/1B3yA"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8679310F031 for ; Fri, 13 Dec 2024 14:03:27 +0000 (UTC) Received: from [127.0.1.1] (91-157-155-49.elisa-laajakaista.fi [91.157.155.49]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 9F9EA752; Fri, 13 Dec 2024 15:02:50 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734098572; bh=47sDiubgqaQkaDbcosAByaG1Ni6cOzGOKnQlTVO76og=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=Df/1B3yAi+Gp2hpeqto3JEPA85Rp3SE+AeOYjXPaLhgfx9XlSK2iUQDdkWs1TLKse VOzzNrZ+z0pygHy5a+lhAU+S7srC/ybRdhAIumf24f17nrSzxsAiBnBZm2sdv1jis5 WtCdRycB8wWmEAIB8IuOKk8EisMzOKBCbB9v0DqA= From: Tomi Valkeinen Date: Fri, 13 Dec 2024 16:03:02 +0200 Subject: [PATCH v4 6/7] drm/rcar-du: dsi: Add r8a779h0 support MIME-Version: 1.0 Message-Id: <20241213-rcar-gh-dsi-v4-6-f8e41425207b@ideasonboard.com> References: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> In-Reply-To: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> To: Laurent Pinchart , Kieran Bingham , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Michael Turquette , Stephen Boyd , LUU HOAI , Jagan Teki , Sam Ravnborg , Biju Das Cc: Laurent Pinchart , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart , linux-clk@vger.kernel.org, Tomi Valkeinen X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1132; i=tomi.valkeinen@ideasonboard.com; h=from:subject:message-id; bh=dOcoxtMfzjVQWbNdCVgHPfsgULtxlauUf/dbpEGcHa8=; b=owEBbQKS/ZANAwAIAfo9qoy8lh71AcsmYgBnXD6hYuVq4r0AVmh8DHjN9dFuFHrlXwKPcJ+aR rGqYLKdF42JAjMEAAEIAB0WIQTEOAw+ll79gQef86f6PaqMvJYe9QUCZ1w+oQAKCRD6PaqMvJYe 9d/UEACMGNHHrrQVhtbcd1SgDmfQXs1wf0pixw1JaWvyMpACYc/sNrvZD02FitS4XVh2VISfGdD 8nP57aAlNL1AgjNABcJRjVznJg1StoPBsjwgZUgiAskuqpRW0nMTov1IrWXamPd8YmT3vI/r7OW K/ofqL3icJvhJcgnKG5tY+27tWHjiFa80JzTLm4f4CBGTnJpeJvud3RErqxUdwHYPiMUP7ZJzMA l9SmqJbKHJVi2GpLZXyVC0LeJEYXPl6GpdYat+HTAl96unhDQmT5eE6Dxh5w3fH2/Hdt85AHr9N 0skT64kC7KM2Yru7GAC1RZy048jbfZqg+3wIMhj4UBn34+ACuFAfyWWoSQ9T6Pk3n2AmgZHxBXo jWykSx1nwybEwMnU9i+WFbKV3KrxEQF7UnvytjwkUjegRdiEh0Nq8jB/cARTcq+lhtYj8gvt9Tu uGBWm/VtKriRg60dX2n5oUOP2/7cuYLvisj6Kp34nFqSdGEJt35lP44xejj2Tuq7ZeIxuM0yymT mLy4r1jjuuJc3aw08qj14sJF1pZibQ2ZJZXy1dvCUvRUfaEZ90Oij3S9V/PSNrLSK11RqojWiNE lTK9JCJyHp/WvgQ+IEKrpLty4xfs8uyO7w+L68Shuq13TLfyP+goF+/iigegJEiJeXlWtjvDaPL LUDaiS+66mJjTBQ== X-Developer-Key: i=tomi.valkeinen@ideasonboard.com; a=openpgp; fpr=C4380C3E965EFD81079FF3A7FA3DAA8CBC961EF5 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Tomi Valkeinen Add support for DSI on r8a779h0. As it is identical to DSI on r8a779g0, all we need is to handle the compatible string. Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart Tested-by: Geert Uytterhoeven --- drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c index 92f4261305bd..36e902601f84 100644 --- a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c +++ b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c @@ -1081,6 +1081,8 @@ static const struct rcar_mipi_dsi_device_info v4h_data = { static const struct of_device_id rcar_mipi_dsi_of_table[] = { { .compatible = "renesas,r8a779a0-dsi-csi2-tx", .data = &v3u_data }, { .compatible = "renesas,r8a779g0-dsi-csi2-tx", .data = &v4h_data }, + /* DSI in r8a779h0 is identical to r8a779g0 */ + { .compatible = "renesas,r8a779h0-dsi-csi2-tx", .data = &v4h_data }, { } }; From patchwork Fri Dec 13 14:03:03 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 13907145 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 220B7E77180 for ; Fri, 13 Dec 2024 14:03:31 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6E40610F032; Fri, 13 Dec 2024 14:03:30 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="Lcb1XEUy"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3B6B410F031 for ; Fri, 13 Dec 2024 14:03:29 +0000 (UTC) Received: from [127.0.1.1] (91-157-155-49.elisa-laajakaista.fi [91.157.155.49]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 5FCD49CE; Fri, 13 Dec 2024 15:02:52 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734098573; bh=HJjdaetRXcuLU24F2z7EC0FJKWFygfWcwCkCu8S7T2c=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=Lcb1XEUyL25uCRWVcOxKHRpt8tf5Lm9nUEvc6EnHL2jeFNfoSXDRA4e2Iryej08rG kqXch5z3ESVpdL4SvABlsUffqi/Fdx0uoccMEJc3XhHqC1XJ54FU7sgMssApvOoMhB fdy1G7HYGouG8Sb+Wxbq7VMSS4ESB+Qk504/vb0M= From: Tomi Valkeinen Date: Fri, 13 Dec 2024 16:03:03 +0200 Subject: [PATCH v4 7/7] drm/rcar-du: Add support for r8a779h0 MIME-Version: 1.0 Message-Id: <20241213-rcar-gh-dsi-v4-7-f8e41425207b@ideasonboard.com> References: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> In-Reply-To: <20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com> To: Laurent Pinchart , Kieran Bingham , Andrzej Hajda , Neil Armstrong , Robert Foss , Jonas Karlman , Jernej Skrabec , David Airlie , Simona Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Geert Uytterhoeven , Magnus Damm , Michael Turquette , Stephen Boyd , LUU HOAI , Jagan Teki , Sam Ravnborg , Biju Das Cc: Laurent Pinchart , dri-devel@lists.freedesktop.org, linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart , linux-clk@vger.kernel.org, Tomi Valkeinen X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2759; i=tomi.valkeinen@ideasonboard.com; h=from:subject:message-id; bh=Bg7AGqZhWjHR0bYNz/CL0hPBvLMMsgBEIiurfa4R0Mk=; b=owEBbQKS/ZANAwAIAfo9qoy8lh71AcsmYgBnXD6hMiE6LpTIejFqPVMLTkxlgOIQMUKapjsSR 9ZGNhvk1f6JAjMEAAEIAB0WIQTEOAw+ll79gQef86f6PaqMvJYe9QUCZ1w+oQAKCRD6PaqMvJYe 9X5CD/9/+IaIB6QQdHs+R4b1yIh5AlHt1wcoocrP37/+xWxLh1TJn/XCCVcOfqVI8ebJgMW6NGQ eyBrFitS4zaFINOBBOmH098m2T4+Mehwa2E0iRfH5eVRMoTvBoF8P/iooO/ZUDzAgyMn4GT6YjS 8valhQjZQg4Ce1zITReFRsfA69tMnfyXTW8kMvrM/aPyd+YyioYpLVtDRKThI8skd5Xbpq0qKgi FbeHJVRju4lr0w7KYFYYwOdu5i8ZHw/OK/EN+IotOJC+bS7ZKN23CZtmLHMoEMy8Xv+ZbL157S3 uHbnd2a5sO84ocRo0j9fnVdSpENHNtG93HviHJrUKK5XGIUWe1iQhDZNQZCy3aG8oYw9bKwgksD Yjxm9OJ5xJxiqusUS2kmMzq+a1ckzsWuSmD9nSElebGjwMAvveovktUF8uipd/LZNVAoOCZTT0G aGJkFLYLsZDEX0UJ95OBhsbWsGR3wazyyd9xQUn0wksw5wXP71tkTdHMrBHKBVwPJ6F/GIHWCzA F7AJNzmWPFI3ZFVjwPxCoVg1Z3ZGNPzFbd0ns2QCZQYRIJHVK7cVLxI0xxWXwYeEbqsqKPEU7aD op3vh1gFAyhG2NZ3T/SvbnBOtbrjfNcXB7J+y/Hhpqy09RdSJ2lgF917TkDN6Wn83MP9H4Q/fg4 mJ25WNW7A9QuqNQ== X-Developer-Key: i=tomi.valkeinen@ideasonboard.com; a=openpgp; fpr=C4380C3E965EFD81079FF3A7FA3DAA8CBC961EF5 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Tomi Valkeinen Add support for r8a779h0. It is very similar to r8a779g0, but has only one output. Signed-off-by: Tomi Valkeinen Tested-by: Geert Uytterhoeven Reviewed-by: Laurent Pinchart --- drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c | 18 ++++++++++++++++++ drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c | 4 +++- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c b/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c index fb719d9aff10..7858e10839f2 100644 --- a/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c +++ b/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c @@ -545,6 +545,23 @@ static const struct rcar_du_device_info rcar_du_r8a779g0_info = { .dsi_clk_mask = BIT(1) | BIT(0), }; +static const struct rcar_du_device_info rcar_du_r8a779h0_info = { + .gen = 4, + .features = RCAR_DU_FEATURE_CRTC_IRQ + | RCAR_DU_FEATURE_VSP1_SOURCE + | RCAR_DU_FEATURE_NO_BLENDING, + .channels_mask = BIT(0), + .routes = { + /* R8A779H0 has one MIPI DSI output. */ + [RCAR_DU_OUTPUT_DSI0] = { + .possible_crtcs = BIT(0), + .port = 0, + }, + }, + .num_rpf = 5, + .dsi_clk_mask = BIT(0), +}; + static const struct of_device_id rcar_du_of_table[] = { { .compatible = "renesas,du-r8a7742", .data = &rcar_du_r8a7790_info }, { .compatible = "renesas,du-r8a7743", .data = &rzg1_du_r8a7743_info }, @@ -571,6 +588,7 @@ static const struct of_device_id rcar_du_of_table[] = { { .compatible = "renesas,du-r8a77995", .data = &rcar_du_r8a7799x_info }, { .compatible = "renesas,du-r8a779a0", .data = &rcar_du_r8a779a0_info }, { .compatible = "renesas,du-r8a779g0", .data = &rcar_du_r8a779g0_info }, + { .compatible = "renesas,du-r8a779h0", .data = &rcar_du_r8a779h0_info }, { } }; diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c index 1ec806c8e013..068c106e586c 100644 --- a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c +++ b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c @@ -107,10 +107,12 @@ static void rcar_du_group_setup_didsr(struct rcar_du_group *rgrp) */ rcrtc = rcdu->crtcs; num_crtcs = rcdu->num_crtcs; - } else if (rcdu->info->gen >= 3 && rgrp->num_crtcs > 1) { + } else if ((rcdu->info->gen == 3 && rgrp->num_crtcs > 1) || + rcdu->info->gen == 4) { /* * On Gen3 dot clocks are setup through per-group registers, * only available when the group has two channels. + * On Gen4 the registers are there for single channel too. */ rcrtc = &rcdu->crtcs[rgrp->index * 2]; num_crtcs = rgrp->num_crtcs;