From patchwork Thu Feb 23 15:10:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 656097 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id F145EC636D6 for ; Thu, 23 Feb 2023 15:11:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233538AbjBWPLH (ORCPT ); Thu, 23 Feb 2023 10:11:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52398 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233218AbjBWPLG (ORCPT ); Thu, 23 Feb 2023 10:11:06 -0500 Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F1E0F46179 for ; Thu, 23 Feb 2023 07:11:04 -0800 (PST) Received: from tr.lan (ip-86-49-120-218.bb.vodafone.cz [86.49.120.218]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 651B9855D9; Thu, 23 Feb 2023 16:11:01 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1677165062; bh=vWEmkLnIooQEZCnln3t2jGOofe00iKxI4EQz8yJqswM=; h=From:To:Cc:Subject:Date:From; b=VDs+i6hJ56rYYe6aoOMMJFtRcQFy8aAxHMABOhUP68Tn5M1mkuCdPP8aPLQRBu8Aq a/zhAKwSnNjGQZb9NJggY76d4BbXzk1/H2j6Zde6fDIWBLzzFe3Y7olHFAIcv7Gp/e rMyzclybBP2/F+u0KtiJkMkCjU0gLhKeHRa+WbWVczEd8ouBg+vJaJ4ks8HmomA4At YGsY9v1HM83jU21VIG5oPSpmWlMeDvv8OIUbguuU8OyqBOjRr1IkeFNOUth/y8wzSI ojyWQPbbTwQL2eKkq7SmoBMkUTpL4WbQiowuYNiUK1l+JJjGJVcLm63jGC4M5ViN9T eFQoqfiI/Vd0g== From: Marek Vasut To: linux-arm-kernel@lists.infradead.org Cc: Marek Vasut , Krzysztof Kozlowski , Liu Ying , Alexander Stein , Fabio Estevam , Krzysztof Kozlowski , Laurent Pinchart , Lucas Stach , NXP Linux Team , Paul Elder , Peng Fan , Pengutronix Kernel Team , Richard Cochran , Richard Zhu , Rob Herring , Sascha Hauer , Shawn Guo , devicetree@vger.kernel.org Subject: [PATCH v4 1/4] dt-bindings: soc: imx8mp-media-blk-ctrl: Align block controller example name Date: Thu, 23 Feb 2023 16:10:40 +0100 Message-Id: <20230223151043.41548-1-marex@denx.de> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Align the block controller example node name with Linux imx8mp.dtsi . No functional change. Acked-by: Krzysztof Kozlowski Reviewed-by: Liu Ying Signed-off-by: Marek Vasut Reviewed-by: Alexander Stein Reviewed-by: Alexander Stein Tested-by: Alexander Stein --- Cc: Alexander Stein Cc: Fabio Estevam Cc: Krzysztof Kozlowski Cc: Laurent Pinchart Cc: Lucas Stach Cc: NXP Linux Team Cc: Paul Elder Cc: Peng Fan Cc: Pengutronix Kernel Team Cc: Richard Cochran Cc: Richard Zhu Cc: Rob Herring Cc: Sascha Hauer Cc: Shawn Guo Cc: devicetree@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org --- V2: Adjust the label too V3: - Add RB from Liu - Drop the label V4: Add AB from Krzysztof --- .../devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml b/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml index dadb6108e3213..a0f7c73510d04 100644 --- a/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml +++ b/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml @@ -94,7 +94,7 @@ examples: #include #include - media_blk_ctl: blk-ctl@32ec0000 { + blk-ctrl@32ec0000 { compatible = "fsl,imx8mp-media-blk-ctrl", "syscon"; reg = <0x32ec0000 0x138>; power-domains = <&mediamix_pd>, <&mipi_phy1_pd>, <&mipi_phy1_pd>, From patchwork Thu Feb 23 15:10:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 657323 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 95B6AC61DA4 for ; Thu, 23 Feb 2023 15:11:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233839AbjBWPLH (ORCPT ); Thu, 23 Feb 2023 10:11:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52406 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233330AbjBWPLG (ORCPT ); Thu, 23 Feb 2023 10:11:06 -0500 Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F1FD5474C0 for ; Thu, 23 Feb 2023 07:11:04 -0800 (PST) Received: from tr.lan (ip-86-49-120-218.bb.vodafone.cz [86.49.120.218]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 4CACA85738; Thu, 23 Feb 2023 16:11:02 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1677165063; bh=3p7lEBx3cIlD6Fy4DRROkU3fCFOEpLdEeY6/gslm4+A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=b7O3zgr0/UOXYx2wBRTcjnYS7Hjbq35Fb+8CTiOMIk+7QfLvJ8+fpxfHlmvkAnyyc oYSmx7OdpO4GTUno9NxIoNBx7kgBUDvD5xr1xAgEV5b9wIbqGrLIpvSeu5m7f+3pMc I+w0FWOEyQMBYhElGjAPmcVw1JSyTgMwsJB32FeueSuQpx1vzUDYv+9XP/eYu92bnA go07MwMiZxlGkGIgaxeUGMSQw0Yy45JmQKeiDDH63mwB/FBR0OPMPMCPX0xOzAky71 nUSFIuA9gGLS08wXrdozZc0eY1BynaX1vooSieXx9tDGD1exUcED6lWw96+1mwlQE1 l1ZkazSqvH/Iw== From: Marek Vasut To: linux-arm-kernel@lists.infradead.org Cc: Marek Vasut , Krzysztof Kozlowski , Liu Ying , Alexander Stein , Fabio Estevam , Krzysztof Kozlowski , Laurent Pinchart , Lucas Stach , NXP Linux Team , Paul Elder , Peng Fan , Pengutronix Kernel Team , Richard Cochran , Richard Zhu , Rob Herring , Sascha Hauer , Shawn Guo , devicetree@vger.kernel.org Subject: [PATCH v4 2/4] dt-bindings: soc: imx8mp-media-blk-ctrl: Add LDB subnode into schema and example Date: Thu, 23 Feb 2023 16:10:41 +0100 Message-Id: <20230223151043.41548-2-marex@denx.de> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230223151043.41548-1-marex@denx.de> References: <20230223151043.41548-1-marex@denx.de> MIME-Version: 1.0 X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Document the LDB bridge subnode and add the subnode into the example. For the subnode to work, the block control must scan its subnodes and bind drivers to them, do not misuse either simple-bus or simple-mfd here. Reviewed-by: Krzysztof Kozlowski Reviewed-by: Liu Ying Signed-off-by: Marek Vasut --- Cc: Alexander Stein Cc: Fabio Estevam Cc: Krzysztof Kozlowski Cc: Laurent Pinchart Cc: Lucas Stach Cc: NXP Linux Team Cc: Paul Elder Cc: Peng Fan Cc: Pengutronix Kernel Team Cc: Richard Cochran Cc: Richard Zhu Cc: Rob Herring Cc: Sascha Hauer Cc: Shawn Guo Cc: devicetree@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org --- V2: Add RB from Liu V3: - Update commit subject and drop space before fullstop. - Add RB from Krzysztof V4: No change --- .../soc/imx/fsl,imx8mp-media-blk-ctrl.yaml | 51 +++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml b/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml index a0f7c73510d04..f092916dc8594 100644 --- a/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml +++ b/Documentation/devicetree/bindings/soc/imx/fsl,imx8mp-media-blk-ctrl.yaml @@ -23,6 +23,12 @@ properties: reg: maxItems: 1 + '#address-cells': + const: 1 + + '#size-cells': + const: 1 + '#power-domain-cells': const: 1 @@ -78,9 +84,16 @@ properties: - const: isp1 - const: dwe + bridge@5c: + type: object + $ref: /schemas/display/bridge/fsl,ldb.yaml# + unevaluatedProperties: false + required: - compatible - reg + - '#address-cells' + - '#size-cells' - '#power-domain-cells' - power-domains - power-domain-names @@ -114,5 +127,43 @@ examples: clock-names = "apb", "axi", "cam1", "cam2", "disp1", "disp2", "isp", "phy"; #power-domain-cells = <1>; + #address-cells = <1>; + #size-cells = <1>; + + bridge@5c { + compatible = "fsl,imx8mp-ldb"; + clocks = <&clk IMX8MP_CLK_MEDIA_LDB>; + clock-names = "ldb"; + reg = <0x5c 0x4>, <0x128 0x4>; + reg-names = "ldb", "lvds"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + ldb_from_lcdif2: endpoint { + remote-endpoint = <&lcdif2_to_ldb>; + }; + }; + + port@1 { + reg = <1>; + + ldb_lvds_ch0: endpoint { + remote-endpoint = <&ldb_to_lvdsx4panel>; + }; + }; + + port@2 { + reg = <2>; + + ldb_lvds_ch1: endpoint { + }; + }; + }; + }; }; ... From patchwork Thu Feb 23 15:10:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 656096 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DBEB2C64ED8 for ; Thu, 23 Feb 2023 15:11:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233218AbjBWPLI (ORCPT ); Thu, 23 Feb 2023 10:11:08 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52412 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233393AbjBWPLG (ORCPT ); Thu, 23 Feb 2023 10:11:06 -0500 Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 945FE48E33 for ; Thu, 23 Feb 2023 07:11:05 -0800 (PST) Received: from tr.lan (ip-86-49-120-218.bb.vodafone.cz [86.49.120.218]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 2D1A98574F; Thu, 23 Feb 2023 16:11:03 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1677165063; bh=16xbgJCTo5sTBDrtuR0KQuDS4zF7hRZbmCwulnyc40w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uY74j56PRyRx8q2zDB/bx1WGePGPgJ2peTuxb3yOALzqb1SyDm7iMbttlrWyZUQl8 wtEKurJaEHwku572bRyfz+FNXutWuiUBfMjaoEjcpZA/zCLXGj3BgVV4x1BkobqHgu oH3vdlfiAU7fp3VXKT9MORlAcGB+8c4lfRoGsJyaBFsZwfvNcF6b98OYTiGRDrawJL y019nETx3ZkwNhPttOhh5bjuS7W5H5gCezn0spKvWzS9fHyMsG+1EAUQSmfvpmYp2p JBRIMPh4EfX0n5FzqWtXuYw3n97Ixa41O+7aQQQcZhnnOXBAYDKml8g0rHs9fTc7PP MlDbLct2zfG+g== From: Marek Vasut To: linux-arm-kernel@lists.infradead.org Cc: Marek Vasut , Alexander Stein , Fabio Estevam , Krzysztof Kozlowski , Laurent Pinchart , Lucas Stach , NXP Linux Team , Paul Elder , Peng Fan , Pengutronix Kernel Team , Richard Cochran , Richard Zhu , Rob Herring , Sascha Hauer , Shawn Guo , devicetree@vger.kernel.org Subject: [PATCH v4 3/4] soc: imx: imx8m-blk-ctrl: Scan subnodes and bind drivers to them Date: Thu, 23 Feb 2023 16:10:42 +0100 Message-Id: <20230223151043.41548-3-marex@denx.de> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230223151043.41548-1-marex@denx.de> References: <20230223151043.41548-1-marex@denx.de> MIME-Version: 1.0 X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This particular block can have DT subnodes describing the LVDS LDB bridge. Instead of misusing simple-bus to scan for those nodes, do the scan within the driver. Fixes: 94e6197dadc9 ("arm64: dts: imx8mp: Add LCDIF2 & LDB nodes") Signed-off-by: Marek Vasut --- Cc: Alexander Stein Cc: Fabio Estevam Cc: Krzysztof Kozlowski Cc: Laurent Pinchart Cc: Lucas Stach Cc: NXP Linux Team Cc: Paul Elder Cc: Peng Fan Cc: Pengutronix Kernel Team Cc: Richard Cochran Cc: Richard Zhu Cc: Rob Herring Cc: Sascha Hauer Cc: Shawn Guo Cc: devicetree@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org --- V2: - Turn this into 3/4 - Warn and continue in case of error V3: Add RB from Liu V4: - Use devm_of_platform_populate() - Remove RB from Liu --- drivers/soc/imx/imx8m-blk-ctrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/soc/imx/imx8m-blk-ctrl.c b/drivers/soc/imx/imx8m-blk-ctrl.c index 399cb85105a18..77e7dc4eb8cff 100644 --- a/drivers/soc/imx/imx8m-blk-ctrl.c +++ b/drivers/soc/imx/imx8m-blk-ctrl.c @@ -310,7 +310,7 @@ static int imx8m_blk_ctrl_probe(struct platform_device *pdev) dev_set_drvdata(dev, bc); - return 0; + return devm_of_platform_populate(dev); cleanup_provider: of_genpd_del_provider(dev->of_node); From patchwork Thu Feb 23 15:10:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 657322 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A75A0C677F1 for ; Thu, 23 Feb 2023 15:11:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233393AbjBWPLJ (ORCPT ); Thu, 23 Feb 2023 10:11:09 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52480 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233330AbjBWPLI (ORCPT ); Thu, 23 Feb 2023 10:11:08 -0500 Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C6FD946179 for ; Thu, 23 Feb 2023 07:11:06 -0800 (PST) Received: from tr.lan (ip-86-49-120-218.bb.vodafone.cz [86.49.120.218]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 0299685831; Thu, 23 Feb 2023 16:11:03 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1677165064; bh=5+SqeNuDll1+A0cT51RRG6pnuQ0c1roVFERlrFacWsU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=yU7jQa1E8t0/02cOBcnR+VrpxTigN0VBJQFYYymxXfcQFMMWqSrXqzxaUyyzpsyFJ YpyUzvVnHeMl3PN97e6xS49PXgkHWtwXtlEiHR4xlWrljvqpMrnzu+CDpG/8Opyuij Mb+BPpj1j4CsUmOXCyMeWomFKetByM8c5vnT8Al6TGdmfPrbcnASXagOgOTJbHeGpD pn7QH/A1Vb477k53adkos//52PnoTqzKlhZa2cU/PS2Q5fOGDFXvARLgEP+bTM4Tns ECoGQt/e5fHEUT4kHG9JuIt11lgfGpj5GL8fRFNjia3Gho7KuskMHPwhlIUn0oPZmq FsKBFgzPV5Ipg== From: Marek Vasut To: linux-arm-kernel@lists.infradead.org Cc: Marek Vasut , Liu Ying , Alexander Stein , Fabio Estevam , Krzysztof Kozlowski , Laurent Pinchart , Lucas Stach , NXP Linux Team , Paul Elder , Peng Fan , Pengutronix Kernel Team , Richard Cochran , Richard Zhu , Rob Herring , Sascha Hauer , Shawn Guo , devicetree@vger.kernel.org Subject: [PATCH v4 4/4] arm64: dts: imx8mp: Drop simple-bus from fsl,imx8mp-media-blk-ctrl Date: Thu, 23 Feb 2023 16:10:43 +0100 Message-Id: <20230223151043.41548-4-marex@denx.de> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230223151043.41548-1-marex@denx.de> References: <20230223151043.41548-1-marex@denx.de> MIME-Version: 1.0 X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This block should not be compatible with simple-bus and misuse it that way. Instead, the driver should scan its subnodes and bind drivers to them. Reviewed-by: Liu Ying Fixes: 94e6197dadc9 ("arm64: dts: imx8mp: Add LCDIF2 & LDB nodes") Signed-off-by: Marek Vasut --- Cc: Alexander Stein Cc: Fabio Estevam Cc: Krzysztof Kozlowski Cc: Laurent Pinchart Cc: Lucas Stach Cc: NXP Linux Team Cc: Paul Elder Cc: Peng Fan Cc: Pengutronix Kernel Team Cc: Richard Cochran Cc: Richard Zhu Cc: Rob Herring Cc: Sascha Hauer Cc: Shawn Guo Cc: devicetree@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org --- V2: Turn this into 4/4 V3: Add RB from Liu V4: No change --- arch/arm64/boot/dts/freescale/imx8mp.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi index 2dd60e3252f35..ca8093ee4d0e4 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi @@ -1151,7 +1151,7 @@ lcdif2_to_ldb: endpoint { media_blk_ctrl: blk-ctrl@32ec0000 { compatible = "fsl,imx8mp-media-blk-ctrl", - "simple-bus", "syscon"; + "syscon"; reg = <0x32ec0000 0x10000>; #address-cells = <1>; #size-cells = <1>;