Received: by 2002:a05:6a10:6d25:0:0:0:0 with SMTP id gq37csp1592338pxb; Mon, 13 Sep 2021 00:48:32 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzPTMPjy+o+cyRh8ZKRKyIMH9BcV7f1Et5MsEyvLnqjQlkSO/JOyeIJ18hiLJtXrm1Wr2zB X-Received: by 2002:a17:907:785a:: with SMTP id lb26mr11351696ejc.77.1631519312262; Mon, 13 Sep 2021 00:48:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631519312; cv=none; d=google.com; s=arc-20160816; b=REC0n2KnjHRpbtiw7xSj0JGXg5BStZ7XyvUkvUqRaPCxhzaUtVFp6+xqXmxQ7RZ51K N1/xXBJnO5zCx9cGNNLzvgeyxTPcMM8eVIr3thxTOW6COITw/o4aLZAHalgSYd7shlmZ LDsw1euvFdBQNi0oibdqGTOVI+LavE3LZ7X3P0hTnsV8Y9iyRi8XP3Dlau+l6sYaDsxk gTyNX9sM35Lf/HdZhVNbOIakQU/JSHcf1PhxqS6q1mm3rLy/VYHTC+8GUg0cNnIaqpau rO7lKr4IsQFoE+jY1Q9Nd/I3HGipwIfIa7JbOd3cBDpEOeIgopVVgSeEK+EfS5pWBNj2 veGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=bEMblMRFwq54y/wqo9quzxvYPqVTM9hzU6YhTTtJHxc=; b=ODoB5iKt8LC6ck+T0IvDiqEvufH0/G0fuWsRRJmIsKrpROIwMQIFn3QxOWvkxiPoEL 3Aik0y8XXzI11gqRdiEcYXwNVyBRwG6PemPMKQIS1VDW7tgByITfx5zj3jLzmyzLamdC HkAtAdPU07Glv0fxp8voMbyB6m3xS5W0Wm4YjWfthQYw9R+xfPXCnOtV8a92C50jQglq R9MW1O8geTGtlgC7dVPGP9F6GI2xBGo492hzT59V7kNp7AbK+rJC7YfeUkD0b9wznkFa 2EhP6r07Cjg6or7ov+yVGTkh+lh29SOR+tbK7VqJxQ7P4OuqPC57+yWkEuLRAbQzuro7 DN6Q== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f21si6255143edf.336.2021.09.13.00.48.07; Mon, 13 Sep 2021 00:48:32 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237714AbhIMHpw (ORCPT + 99 others); Mon, 13 Sep 2021 03:45:52 -0400 Received: from relay11.mail.gandi.net ([217.70.178.231]:45969 "EHLO relay11.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237599AbhIMHpv (ORCPT ); Mon, 13 Sep 2021 03:45:51 -0400 Received: (Authenticated sender: paul.kocialkowski@bootlin.com) by relay11.mail.gandi.net (Postfix) with ESMTPSA id 6AD0F100018; Mon, 13 Sep 2021 07:44:23 +0000 (UTC) Date: Mon, 13 Sep 2021 09:44:22 +0200 From: Paul Kocialkowski To: Samuel Holland Cc: Yong Deng , Mauro Carvalho Chehab , Rob Herring , Maxime Ripard , Sakari Ailus , Hans Verkuil , Chen-Yu Tsai , Jernej Skrabec , Greg Kroah-Hartman , Helen Koike , Laurent Pinchart , Thomas Petazzoni , linux-media@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, linux-phy@lists.infradead.org, linux-clk@vger.kernel.org, linux-staging@lists.linux.dev Subject: Re: [PATCH 09/22] ARM: dts: sun8i: v3s: Add nodes for MIPI CSI-2 support Message-ID: References: <20210910184147.336618-1-paul.kocialkowski@bootlin.com> <20210910184147.336618-10-paul.kocialkowski@bootlin.com> <483288cb-d9fa-4581-7986-d15c4aa27769@sholland.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="QZVQzP+VTAJydr5U" Content-Disposition: inline In-Reply-To: <483288cb-d9fa-4581-7986-d15c4aa27769@sholland.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --QZVQzP+VTAJydr5U Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Samuel, On Fri 10 Sep 21, 21:32, Samuel Holland wrote: > On 9/10/21 1:41 PM, Paul Kocialkowski wrote: > > MIPI CSI-2 is supported on the V3s with an A31-based MIPI CSI-2 bridge > > controller. The controller uses a separate D-PHY, which is the same > > that is otherwise used for MIPI DSI, but used in Rx mode. > >=20 > > On the V3s, the CSI0 controller is dedicated to MIPI CSI-2 as it does > > not have access to any parallel interface pins. > >=20 > > Add all the necessary nodes (CSI0, MIPI CSI-2 bridge and D-PHY) to > > support the MIPI CSI-2 interface. > >=20 > > Note that a fwnode graph link is created between CSI0 and MIPI CSI-2 > > even when no sensor is connected. This will result in a probe failure > > for the controller as long as no sensor is connected but this is fine > > since no other interface is available. > >=20 > > Signed-off-by: Paul Kocialkowski > > --- > > arch/arm/boot/dts/sun8i-v3s.dtsi | 72 ++++++++++++++++++++++++++++++++ > > 1 file changed, 72 insertions(+) > >=20 > > diff --git a/arch/arm/boot/dts/sun8i-v3s.dtsi b/arch/arm/boot/dts/sun8i= -v3s.dtsi > > index a77b63362a1d..ec7fa6459547 100644 > > --- a/arch/arm/boot/dts/sun8i-v3s.dtsi > > +++ b/arch/arm/boot/dts/sun8i-v3s.dtsi > > @@ -612,6 +612,34 @@ spi0: spi@1c68000 { > > #size-cells =3D <0>; > > }; > > =20 > > + csi0: camera@1cb0000 { > > + compatible =3D "allwinner,sun8i-v3s-csi"; > > + reg =3D <0x01cb0000 0x1000>; > > + interrupts =3D ; > > + clocks =3D <&ccu CLK_BUS_CSI>, > > + <&ccu CLK_CSI1_SCLK>, > > + <&ccu CLK_DRAM_CSI>; > > + clock-names =3D "bus", "mod", "ram"; > > + resets =3D <&ccu RST_BUS_CSI>; > > + status =3D "disabled"; > > + > > + assigned-clocks =3D <&ccu CLK_CSI1_SCLK>; > > + assigned-clock-parents =3D <&ccu CLK_PLL_ISP>; > > + > > + ports { > > + #address-cells =3D <1>; > > + #size-cells =3D <0>; > > + > > + port@1 { > > + reg =3D <1>; > > + > > + csi0_in_mipi_csi2: endpoint { > > + remote-endpoint =3D <&mipi_csi2_out_csi0>; > > + }; > > + }; > > + }; > > + }; > > + > > csi1: camera@1cb4000 { > > compatible =3D "allwinner,sun8i-v3s-csi"; > > reg =3D <0x01cb4000 0x3000>; >=20 > All of the new nodes should be added above this one, to maintain unit > address order. Good catch, this was an overlook on my side. Thanks, Paul > Regards, > Samuel >=20 > > @@ -637,5 +665,49 @@ gic: interrupt-controller@1c81000 { > > #interrupt-cells =3D <3>; > > interrupts =3D ; > > }; > > + > > + mipi_csi2: csi@1cb1000 { > > + compatible =3D "allwinner,sun8i-v3s-mipi-csi2", > > + "allwinner,sun6i-a31-mipi-csi2"; > > + reg =3D <0x01cb1000 0x1000>; > > + interrupts =3D ; > > + clocks =3D <&ccu CLK_BUS_CSI>, > > + <&ccu CLK_CSI1_SCLK>; > > + clock-names =3D "bus", "mod"; > > + resets =3D <&ccu RST_BUS_CSI>; > > + status =3D "disabled"; > > + > > + phys =3D <&dphy>; > > + phy-names =3D "dphy"; > > + > > + ports { > > + #address-cells =3D <1>; > > + #size-cells =3D <0>; > > + > > + mipi_csi2_in: port@0 { > > + reg =3D <0>; > > + }; > > + > > + mipi_csi2_out: port@1 { > > + reg =3D <1>; > > + > > + mipi_csi2_out_csi0: endpoint { > > + remote-endpoint =3D <&csi0_in_mipi_csi2>; > > + }; > > + }; > > + }; > > + }; > > + > > + dphy: d-phy@1cb2000 { > > + compatible =3D "allwinner,sun6i-a31-mipi-dphy"; > > + reg =3D <0x01cb2000 0x1000>; > > + clocks =3D <&ccu CLK_BUS_CSI>, > > + <&ccu CLK_MIPI_CSI>; > > + clock-names =3D "bus", "mod"; > > + resets =3D <&ccu RST_BUS_CSI>; > > + allwinner,direction =3D "rx"; > > + status =3D "disabled"; > > + #phy-cells =3D <0>; > > + }; > > }; > > }; > >=20 >=20 --=20 Paul Kocialkowski, Bootlin Embedded Linux and kernel engineering https://bootlin.com --QZVQzP+VTAJydr5U Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEJZpWjZeIetVBefti3cLmz3+fv9EFAmE/AVYACgkQ3cLmz3+f v9EFwAgAlLhO92v/X6G6gs1EKL/Ve3k5WVgSYDcp38cxhVkn9TYIx+u97xSfyDLC P5PABn2O8tERf6e7U1NBmqr64vSzvziaRmeLo6co6sdLEJuNvk4wrp3/9U7+dp/Q 9Pp/tPxadAO4SKID7BW5UKTEzWqzGlsGJf/6p83oKzwWtBCTBXTfK0PjkmESPFy8 kTX1gqi9/Pe0oiWH0PRZJIZzPYDP8PpRNPQNxhPlXivuSnDLFwNAhaSXrMvqOnl2 /Y+tpSRPXTKGPqjIAzRn3G2fTveiHMw0fTLwVgcZqqNIK4dACeQLJYNdSxjTMORZ J1xWZQdStHkESCp9DRxlxV8TLbiItg== =95oz -----END PGP SIGNATURE----- --QZVQzP+VTAJydr5U--