From patchwork Thu May 17 12:50:30 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rui Miguel Silva X-Patchwork-Id: 136153 Delivered-To: patch@linaro.org Received: by 2002:a2e:9706:0:0:0:0:0 with SMTP id r6-v6csp155557lji; Thu, 17 May 2018 05:51:19 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoCmk6X8+8eBg8SKAPgpaN+bYust3gwf9nsr8I05i9MgRNhzaAJSiwAIqXztXJtRdR4LKTP X-Received: by 2002:a62:f909:: with SMTP id o9-v6mr5079926pfh.256.1526561479484; Thu, 17 May 2018 05:51:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526561479; cv=none; d=google.com; s=arc-20160816; b=hUcHPv4bHCSQhQMQBAEkSbjh7QrMbz+6Pqum3STjfQfrXat5R8M94CVAAW9H1MAbn8 xobTPIZHKU2uq3u5jjUvhGRKo30XduX7WjQ96uMvrY95uYHlSizyxCQGQ2QDtOHtqvYr mjrUdJsYHGe9MpUTxhOWTZwWRZW+nIjkHPqRCP5DpsKn1Y4S2BXUXUrrdeNB0QKtsqmo ZDRkoMAfcJbnkeVNLO9JaJatMi3pDW2NYyg3HHu7D3KGwQpJt23GGXlpa4zvjymOfZrz 1ZrX+xfBnFZno/zHaYwBHSZCJTbu7ZV4MtWP1qhRSGPrMXyWCIpfKp5feHFn0or8uFLC VsfQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=wjxDYbAz4IU4olfozatAjZ8MNt7cy7PprEy/RfcHVFg=; b=XQ6c07WNbK7ofHdLyCf/58F79HzlDl7RzXH2eEP6i0zoaFHjg/Pr3fw9GJkqIcGuVi E2iFgbDO78rFhGoxVrlbT3DusEWC0XF792Do/KTq1upvWsUIimEahVJV1Xkh5OCmpmmv g+AlzGkzwz/Cwyn2/WYSCBGc5VXgSbGhvSqDHxyPYtLqmTBqrsUY7MaFDi7rdAdK0jK4 +4x8/wgaJLpjPpdjToQq+YNKUwRz/EUd5mszsZeqfG+EzOW2ySlsHCFtm5dux2w2J/EW KL9v3USGdQ6wu/XnW+Kb9RxgIwywwyyV1SefPJiljso/Kr2T9tekCbD5FgCLySyetriN poGA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=LL/EUlzv; spf=pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z1-v6si4876508plb.558.2018.05.17.05.51.19; Thu, 17 May 2018 05:51:19 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=LL/EUlzv; spf=pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751999AbeEQMvQ (ORCPT + 4 others); Thu, 17 May 2018 08:51:16 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:55023 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750938AbeEQMvP (ORCPT ); Thu, 17 May 2018 08:51:15 -0400 Received: by mail-wm0-f67.google.com with SMTP id f6-v6so8198313wmc.4 for ; Thu, 17 May 2018 05:51:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=wjxDYbAz4IU4olfozatAjZ8MNt7cy7PprEy/RfcHVFg=; b=LL/EUlzvPVgSruDo0OO88/x6hMOME1npF0PBJLhETZpssC1uXXs8SP/VfagUEChcfr dYvuhbBhkuCIvmAkn16Wu7wB/N4IGAo7r+x0uGqvlG8FsTiSjXILG+UjxbppGLepRbmE 87QgTFgTVWhpXJCEm5ql8g6SMAVHLSGxv9Kyw= 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:in-reply-to :references; bh=wjxDYbAz4IU4olfozatAjZ8MNt7cy7PprEy/RfcHVFg=; b=nsY4gt76zRHAT+/TCnGCwn0GUmDe8SR/KRGmDINZQ1K0PmkNP3JpvnjNxW7PxSdwFr xPdoqwiTmy5D+hrXd11xis022zEh2cG+NfogqSzmZKnt8zkeCibQPWaUEqdJSVMx2Zk4 9HTuzmBeOv7POystyMdJBFi6z3hznz2Q3gS4xqrLlaiWqB/id0sdQtq1IxPm7+Xse9dU 5VST1u23cbikcdA78oa9i6CZqnZXOBsoDTWT7J+0QaxV6kOopFmRz28wnglWs2FSMXkY zV9WFZ4OTEUwtdHEFvhGLrUeu8U46KYVLeBqdWBOhQ+xdSgOZqhyO6zgo+jjg9rry5zq NLKg== X-Gm-Message-State: ALKqPwdxS/dUOICsbxXG5lx79yhpbC6hH86/mkWJbxexkVqjUPocNEmy eat7VXNCFceuwds6ULRW7qwnnA== X-Received: by 2002:a1c:ee95:: with SMTP id j21-v6mr1737368wmi.16.1526561474055; Thu, 17 May 2018 05:51:14 -0700 (PDT) Received: from localhost.localdomain ([2001:8a0:6606:9100:b159:5390:182d:7dce]) by smtp.gmail.com with ESMTPSA id 33-v6sm6077665wrs.5.2018.05.17.05.51.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 17 May 2018 05:51:13 -0700 (PDT) From: Rui Miguel Silva To: mchehab@kernel.org, sakari.ailus@linux.intel.com, Steve Longerbeam , Philipp Zabel , Rob Herring Cc: linux-media@vger.kernel.org, devel@driverdev.osuosl.org, Shawn Guo , Fabio Estevam , devicetree@vger.kernel.org, Greg Kroah-Hartman , Ryan Harkin , Rui Miguel Silva Subject: [PATCH v4 09/12] ARM: dts: imx7: Add video mux, csi and mipi_csi and connections Date: Thu, 17 May 2018 13:50:30 +0100 Message-Id: <20180517125033.18050-10-rui.silva@linaro.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180517125033.18050-1-rui.silva@linaro.org> References: <20180517125033.18050-1-rui.silva@linaro.org> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org This patch adds the device tree nodes for csi, video multiplexer and mipi-csi besides the graph connecting the necessary endpoints to make the media capture entities to work in imx7 Warp board. Also add the pin control related with the mipi_csi in that board. Signed-off-by: Rui Miguel Silva --- arch/arm/boot/dts/imx7s-warp.dts | 51 ++++++++++++++++++++++++++++++++ arch/arm/boot/dts/imx7s.dtsi | 28 ++++++++++++++++++ 2 files changed, 79 insertions(+) -- 2.17.0 diff --git a/arch/arm/boot/dts/imx7s-warp.dts b/arch/arm/boot/dts/imx7s-warp.dts index 8a30b148534d..cb175ee2fc9d 100644 --- a/arch/arm/boot/dts/imx7s-warp.dts +++ b/arch/arm/boot/dts/imx7s-warp.dts @@ -310,6 +310,57 @@ status = "okay"; }; +&gpr { + csi_mux { + compatible = "video-mux"; + mux-controls = <&mux 0>; + #address-cells = <1>; + #size-cells = <0>; + + port@1 { + reg = <1>; + + csi_mux_from_mipi_vc0: endpoint { + remote-endpoint = <&mipi_vc0_to_csi_mux>; + }; + }; + + port@2 { + reg = <2>; + + csi_mux_to_csi: endpoint { + remote-endpoint = <&csi_from_csi_mux>; + }; + }; + }; +}; + +&csi { + status = "okay"; + + port { + csi_from_csi_mux: endpoint { + remote-endpoint = <&csi_mux_to_csi>; + }; + }; +}; + +&mipi_csi { + clock-frequency = <166000000>; + status = "okay"; + #address-cells = <1>; + #size-cells = <0>; + fsl,csis-hs-settle = <3>; + + port@1 { + reg = <1>; + + mipi_vc0_to_csi_mux: endpoint { + remote-endpoint = <&csi_mux_from_mipi_vc0>; + }; + }; +}; + &wdog1 { pinctrl-names = "default"; pinctrl-0 = <&pinctrl_wdog>; diff --git a/arch/arm/boot/dts/imx7s.dtsi b/arch/arm/boot/dts/imx7s.dtsi index 3590dab529f9..0bae41f2944c 100644 --- a/arch/arm/boot/dts/imx7s.dtsi +++ b/arch/arm/boot/dts/imx7s.dtsi @@ -46,6 +46,7 @@ #include #include #include +#include #include "imx7d-pinfunc.h" / { @@ -738,6 +739,17 @@ status = "disabled"; }; + csi: csi@30710000 { + compatible = "fsl,imx7-csi"; + reg = <0x30710000 0x10000>; + interrupts = ; + clocks = <&clks IMX7D_CLK_DUMMY>, + <&clks IMX7D_CSI_MCLK_ROOT_CLK>, + <&clks IMX7D_CLK_DUMMY>; + clock-names = "axi", "mclk", "dcic"; + status = "disabled"; + }; + lcdif: lcdif@30730000 { compatible = "fsl,imx7d-lcdif", "fsl,imx28-lcdif"; reg = <0x30730000 0x10000>; @@ -747,6 +759,22 @@ clock-names = "pix", "axi"; status = "disabled"; }; + + mipi_csi: mipi-csi@30750000 { + compatible = "fsl,imx7-mipi-csi2"; + reg = <0x30750000 0x10000>; + interrupts = ; + clocks = <&clks IMX7D_IPG_ROOT_CLK>, + <&clks IMX7D_MIPI_CSI_ROOT_CLK>, + <&clks IMX7D_MIPI_DPHY_ROOT_CLK>; + clock-names = "pclk", "wrap", "phy"; + power-domains = <&pgc_mipi_phy>; + phy-supply = <®_1p0d>; + resets = <&src IMX7_RESET_MIPI_PHY_MRST>; + reset-names = "mrst"; + bus-width = <2>; + status = "disabled"; + }; }; aips3: aips-bus@30800000 {