Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp10436712ybi; Thu, 11 Jul 2019 05:19:42 -0700 (PDT) X-Google-Smtp-Source: APXvYqwkc8SExTQcUyZMSWeoB+r+EtiDBuUxYN7zCyhckhm1IFEwxyz11sLKR0nNfWTInZ7z4rNV X-Received: by 2002:a17:90a:7f85:: with SMTP id m5mr4565431pjl.78.1562847581918; Thu, 11 Jul 2019 05:19:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562847581; cv=none; d=google.com; s=arc-20160816; b=h4SqNa9XBhpuQv7I+Mx2PFiDHdAUbtZowmY5KpJtEfHa3h48SoA32pgPukLUh7Vyiw leRGKRiDO7OZB1Cv8deqmgTFWf/qUrHH0nCMVR0v85bU+Pf2NKuV6bkCaItwmLFTq0RJ BHwRq0wRUI+o4br+cMCI0Ov8H+4NBXz1HI81sm7uNk5VixlxCmkXquDaNUDk2xEbVmbX ri2glBu3sCYI1pmYr1gDJ5NrVL+b8PE3y2O++KKeYsquDYhR2oaQ5QkwwxRqX3xbn9o3 lXND2yAOMJYbVGWBwUHvps7lblBdc3eZGM5O89jBtnbAYnoA9QZFpYCECEgwIK/4ftDh aA9A== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=IkIqM4/QC2alW081o95ZYmisLTqSlV2btVHWjqmo/SQ=; b=z2xfE2uckQ/bphuElTJ57R2O4rsm+RRBs02CFYi58hnBRxVLWPkLDvqdJQ3OG4oxrO Ga8eyjgeKSPACUF14Pd8fnWx3m40fQFPIUPa79FOZTExSVCaptTw7IjGUQjvqNbFbVUR 2aI+sYHM+CNlE2OsNmPjpq3HXNcZSREE06Lve7/levbqUW/4mckQfKWeza09Wy+MyCnA bzFl4at2eJsBi05yImy68NItn5Eh2HtbDCEx2xB2L6oSBfiYxTKgIGaGj10RvnNad8Vd r+lydpAtfXtSG1o/ghfVJpiKnlcPxFiIvozD3rIucLtcSjj/vOx4krOzuhx/evvJlxNa smgg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t190si4985380pgd.465.2019.07.11.05.19.21; Thu, 11 Jul 2019 05:19:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728427AbfGKMRr (ORCPT + 99 others); Thu, 11 Jul 2019 08:17:47 -0400 Received: from relay7-d.mail.gandi.net ([217.70.183.200]:35665 "EHLO relay7-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725926AbfGKMRq (ORCPT ); Thu, 11 Jul 2019 08:17:46 -0400 X-Originating-IP: 86.250.200.211 Received: from localhost (lfbn-1-17395-211.w86-250.abo.wanadoo.fr [86.250.200.211]) (Authenticated sender: maxime.ripard@bootlin.com) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 91C6120020; Thu, 11 Jul 2019 12:15:23 +0000 (UTC) From: Maxime Ripard To: Hans Verkuil , Sakari Ailus , Mauro Carvalho Chehab Cc: Thomas Petazzoni , Laurent Pinchart , linux-media@vger.kernel.org, Chen-Yu Tsai , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, Mark Rutland , Rob Herring , Frank Rowand , Maxime Ripard Subject: [PATCH v6 5/5] DO NOT MERGE: ARM: dts: bananapi: Add Camera support Date: Thu, 11 Jul 2019 14:15:07 +0200 Message-Id: X-Mailer: git-send-email 2.21.0 In-Reply-To: References: 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 Signed-off-by: Maxime Ripard --- arch/arm/boot/dts/sun7i-a20-bananapi.dts | 91 +++++++++++++++++++++++++- 1 file changed, 91 insertions(+) diff --git a/arch/arm/boot/dts/sun7i-a20-bananapi.dts b/arch/arm/boot/dts/sun7i-a20-bananapi.dts index 4df921632f7a..cecc4eb26082 100644 --- a/arch/arm/boot/dts/sun7i-a20-bananapi.dts +++ b/arch/arm/boot/dts/sun7i-a20-bananapi.dts @@ -54,6 +54,9 @@ compatible = "lemaker,bananapi", "allwinner,sun7i-a20"; aliases { + i2c0 = &i2c0; + i2c1 = &i2c1; + i2c2 = &i2c2; serial0 = &uart0; serial1 = &uart3; serial2 = &uart7; @@ -63,6 +66,41 @@ stdout-path = "serial0:115200n8"; }; + reg_cam: cam { + compatible = "regulator-fixed"; + regulator-name = "cam"; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + vin-supply = <®_vcc5v0>; + gpio = <&pio 7 16 GPIO_ACTIVE_HIGH>; + enable-active-high; + regulator-always-on; + }; + + reg_cam_avdd: cam-avdd { + compatible = "regulator-fixed"; + regulator-name = "cam500b-avdd"; + regulator-min-microvolt = <2800000>; + regulator-max-microvolt = <2800000>; + vin-supply = <®_cam>; + }; + + reg_cam_dovdd: cam-dovdd { + compatible = "regulator-fixed"; + regulator-name = "cam500b-dovdd"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + vin-supply = <®_cam>; + }; + + reg_cam_dvdd: cam-dvdd { + compatible = "regulator-fixed"; + regulator-name = "cam500b-dvdd"; + regulator-min-microvolt = <1500000>; + regulator-max-microvolt = <1500000>; + vin-supply = <®_cam>; + }; + hdmi-connector { compatible = "hdmi-connector"; type = "a"; @@ -116,6 +154,23 @@ >; }; +&csi0 { + pinctrl-names = "default"; + pinctrl-0 = <&csi0_pins_a>; + status = "okay"; + + port { + csi_from_ov5640: endpoint { + remote-endpoint = <&ov5640_to_csi>; + bus-width = <8>; + hsync-active = <1>; /* Active high */ + vsync-active = <0>; /* Active low */ + data-active = <1>; /* Active high */ + pclk-sample = <1>; /* Rising */ + }; + }; +}; + &de { status = "okay"; }; @@ -161,6 +216,36 @@ }; }; +&i2c1 { + status = "okay"; + + camera: camera@21 { + compatible = "ovti,ov5640"; + reg = <0x21>; + clocks = <&ccu CLK_CSI0>; + clock-names = "xclk"; + assigned-clocks = <&ccu CLK_CSI0>; + assigned-clock-rates = <24000000>; + + reset-gpios = <&pio 7 14 GPIO_ACTIVE_LOW>; + powerdown-gpios = <&pio 7 19 GPIO_ACTIVE_HIGH>; + AVDD-supply = <®_cam_avdd>; + DOVDD-supply = <®_cam_dovdd>; + DVDD-supply = <®_cam_dvdd>; + + port { + ov5640_to_csi: endpoint { + remote-endpoint = <&csi_from_ov5640>; + bus-width = <8>; + hsync-active = <1>; /* Active high */ + vsync-active = <0>; /* Active low */ + data-active = <1>; /* Active high */ + pclk-sample = <1>; /* Rising */ + }; + }; + }; +}; + &i2c2 { status = "okay"; }; @@ -246,6 +331,12 @@ "SPI-MISO", "SPI-CE1", "", "IO-6", "IO-3", "IO-2", "IO-0", "", "", "", "", "", "", "", "", "", "", "", ""; + + csi0_pins_a: csi_pins_a@0 { + pins = "PE0", "PE1", "PE2", "PE3", "PE4", "PE5", + "PE6", "PE7", "PE8", "PE9", "PE10", "PE11"; + function = "csi0"; + }; }; #include "axp209.dtsi" -- git-series 0.9.1