Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp589056ybz; Wed, 15 Apr 2020 14:39:17 -0700 (PDT) X-Google-Smtp-Source: APiQypK7ihTGfSvLXkLKoxj6PIz7N6x3rO5T2/zrViBOi0/Wy4MhGw08m52GSVgqMHDfa+BJKRsM X-Received: by 2002:aa7:d788:: with SMTP id s8mr27130691edq.311.1586986756984; Wed, 15 Apr 2020 14:39:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586986756; cv=none; d=google.com; s=arc-20160816; b=QKi2StJrS/dMFutPTSNEUDk9hj8aWxVlDSaI3tRfMCwSPFAmhPb1TVEvsiIsecUdh/ xgiJjswapcmbBRVRwnKFpjdrIpM3XTkJyep7iXu6xBhk2M9Rzax6Ya7QaF8KG/YO5408 7VuKpLs/KpZc/3Bc2ikimPhQqNp2VpXjt/LnjPcDYAtxA3KgW1QMlmFv+aFpz9EA7aiW DfXl34hoUuHPNyNk1xKfaVLjWsKJbE843ZPp/tC9vJ+Gh9W05vDyVvN60ey4lDg2tlLJ bC87QKcG29S8MOC4a1AQLm12fEgI5YKF42xh+kp3SGaytfjwdCskpYudfWDJ6CzMlTmY Zaww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=lKWowPZo/h8f/+gcGw1AR/F6jwhwqs/c7eJ/AJODfTQ=; b=zrR5urMbB4kvydYa9B5+EsoZoQXFKJar1y82NPH1fQcdMsgqLjq5j7ijPXSVBS1OSF evPvqsoAfBckIPNAw3y7l+xol2i2yU9p2V2i2AGREM2hqouTNmrgTIppn6Ohu32xGtiY nI20gFhdNDEFWTraYcyIpJve/UE0kULC+EuQEXV4MRcR825zO9J1rxbxlrN/Gh8a012v Kszr1I4blw3xt+EZBvJHpLLrEVrBZo9d5+58LdW5w5H7ETrFJpnP+mYeFCQhg4NqhjkG LPEPrPti7kYShXOzozRMJe/XqC1hUGU6ufi0Wf2hiEBwxRsaF3h7onhiytkGMbKvG6+d o0xw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w20si2555537ejq.91.2020.04.15.14.38.53; Wed, 15 Apr 2020 14:39:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388953AbgDNOHG (ORCPT + 99 others); Tue, 14 Apr 2020 10:07:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34814 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1733074AbgDNOGu (ORCPT ); Tue, 14 Apr 2020 10:06:50 -0400 Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e3e3]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6BA28C061A0C; Tue, 14 Apr 2020 07:06:50 -0700 (PDT) Received: from floko.floko.floko (unknown [IPv6:2804:431:e7cc:79a2:b6f7:4033:5775:cc3a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: koike) by bhuna.collabora.co.uk (Postfix) with ESMTPSA id 8DF162A0B2A; Tue, 14 Apr 2020 15:06:44 +0100 (BST) From: Helen Koike To: devicetree@vger.kernel.org, linux-rockchip@lists.infradead.org Cc: kernel@collabora.com, jbx6244@gmail.com, Eddie Cai , Shunqian Zheng , Tomasz Figa , Helen Koike , Heiko Stuebner , linux-kernel@vger.kernel.org, Rob Herring , Mark Rutland , linux-arm-kernel@lists.infradead.org Subject: [PATCH] arm64: dts: rockchip: add isp and sensors for scarlet Date: Tue, 14 Apr 2020 11:06:34 -0300 Message-Id: <20200414140634.915086-1-helen.koike@collabora.com> X-Mailer: git-send-email 2.26.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eddie Cai Enable ISP and camera sensor ov2685 and ov5695 for scarlet. Verified with: make ARCH=arm64 dtbs_check Signed-off-by: Shunqian Zheng Signed-off-by: Eddie Cai Signed-off-by: Tomasz Figa Signed-off-by: Helen Koike --- This patch is based on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/527854 It should be merged after moving the bidings out of staging: https://patchwork.kernel.org/project/linux-media/list/?series=266089 --- .../boot/dts/rockchip/rk3399-gru-scarlet.dtsi | 74 +++++++++++++++++++ 1 file changed, 74 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/rk3399-gru-scarlet.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-gru-scarlet.dtsi index 4373ed732af76..ae08205aa8e24 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-gru-scarlet.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399-gru-scarlet.dtsi @@ -296,6 +296,52 @@ camera: &i2c7 { /* 24M mclk is shared between world and user cameras */ pinctrl-0 = <&i2c7_xfer &test_clkout1>; + + /* Rear-facing camera */ + wcam: camera@36 { + compatible = "ovti,ov5695"; + reg = <0x36>; + pinctrl-names = "default"; + pinctrl-0 = <&wcam_rst>; + + clocks = <&cru SCLK_TESTCLKOUT1>; + clock-names = "xvclk"; + + avdd-supply = <&pp2800_cam>; + dvdd-supply = <&pp1250_cam>; + dovdd-supply = <&pp1800_s0>; + reset-gpios = <&gpio2 5 GPIO_ACTIVE_LOW>; + + port { + wcam_out: endpoint { + remote-endpoint = <&mipi_in_wcam>; + data-lanes = <1 2>; + }; + }; + }; + + /* Front-facing camera */ + ucam: camera@3c { + compatible = "ovti,ov2685"; + reg = <0x3c>; + pinctrl-names = "default"; + pinctrl-0 = <&ucam_rst>; + + clocks = <&cru SCLK_TESTCLKOUT1>; + clock-names = "xvclk"; + + avdd-supply = <&pp2800_cam>; + dovdd-supply = <&pp1800_s0>; + dvdd-supply = <&pp1800_s0>; + reset-gpios = <&gpio2 3 GPIO_ACTIVE_LOW>; + + port { + ucam_out: endpoint { + remote-endpoint = <&mipi_in_ucam>; + data-lanes = <1>; + }; + }; + }; }; &cdn_dp { @@ -353,10 +399,38 @@ &io_domains { gpio1830-supply = <&pp1800_s0>; /* APIO4_VDD; 4c 4d */ }; +&isp0 { + status = "okay"; + + ports { + port@0 { + mipi_in_wcam: endpoint@0 { + reg = <0>; + remote-endpoint = <&wcam_out>; + data-lanes = <1 2>; + }; + + mipi_in_ucam: endpoint@1 { + reg = <1>; + remote-endpoint = <&ucam_out>; + data-lanes = <1>; + }; + }; + }; +}; + +&isp0_mmu { + status = "okay"; +}; + &max98357a { sdmode-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>; }; +&mipi_dphy_rx0 { + status = "okay"; +}; + &mipi_dsi { status = "okay"; clock-master; -- 2.26.0