Message ID | 1560280855-18085-2-git-send-email-luis.oliveira@synopsys.com (mailing list archive) |
---|---|
State | Changes Requested, archived |
Delegated to: | Sakari Ailus |
Headers |
Received: from vger.kernel.org ([209.132.180.67]) by www.linuxtv.org with esmtp (Exim 4.84_2) (envelope-from <linux-media-owner@vger.kernel.org>) id 1hamL6-0004jY-8s; Tue, 11 Jun 2019 19:21:48 +0000 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2407484AbfFKTVQ (ORCPT <rfc822;mkrufky@linuxtv.org> + 1 other); Tue, 11 Jun 2019 15:21:16 -0400 Received: from smtprelay-out1.synopsys.com ([198.182.47.102]:37604 "EHLO smtprelay-out1.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2404789AbfFKTVQ (ORCPT <rfc822;linux-media@vger.kernel.org>); Tue, 11 Jun 2019 15:21:16 -0400 Received: from mailhost.synopsys.com (mdc-mailhost1.synopsys.com [10.225.0.209]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by smtprelay-out1.synopsys.com (Postfix) with ESMTPS id 1610FC014E; Tue, 11 Jun 2019 19:21:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=synopsys.com; s=mail; t=1560280876; bh=tHIJCAqTF+UPHZ5DtLIcgsUdC1LXsknXPaU2PJfFj5E=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=gLcApO+wN86rDTtu12tkhOzLIR/ojbxyBB39+/3vliFulgKmtv48gGR0k9IafoCM7 cVFQ4on43WaeutuTEU8zWRbLqC1oZy7dsne5SlcGatx37gNdRYEktZMmd9reRxlaVq 0o7bN/qKr/ee71pdjr0fivPjXK4NS17PhtwMoejCzgnT5DPgV36SW3CmGagHgjSwg5 e6dyQMwcISQgwdeZOP0LOKoMwu0IwzrqA1TFNmmeq99fcebMptoRQlVd0GvuK3dMJo M9cJv+MW2NlffYV4Q/m9yS+h23g0QnzdUapVddKLl7lATnzLiOEsEmg3pOYi8uIQsU x9qqekphIqOuA== Received: from de02.synopsys.com (de02.internal.synopsys.com [10.225.17.21]) by mailhost.synopsys.com (Postfix) with ESMTP id 6C18BA005D; Tue, 11 Jun 2019 19:21:13 +0000 (UTC) Received: from de02dwia024.internal.synopsys.com (de02dwia024.internal.synopsys.com [10.225.19.81]) by de02.synopsys.com (Postfix) with ESMTP id 4AE9F3F896; Tue, 11 Jun 2019 21:21:13 +0200 (CEST) From: Luis Oliveira <Luis.Oliveira@synopsys.com> To: mchehab@kernel.org, davem@davemloft.net, gregkh@linuxfoundation.org, Jonathan.Cameron@huawei.com, robh@kernel.org, nicolas.ferre@microchip.com, paulmck@linux.ibm.com, mark.rutland@arm.com, kishon@ti.com, devicetree@vger.kernel.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Joao.Pinto@synopsys.com, Luis Oliveira <Luis.Oliveira@synopsys.com> Subject: [v4 1/6] dt-bindings: media: Document bindings for DW MIPI CSI-2 Host Date: Tue, 11 Jun 2019 21:20:50 +0200 Message-Id: <1560280855-18085-2-git-send-email-luis.oliveira@synopsys.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1560280855-18085-1-git-send-email-luis.oliveira@synopsys.com> References: <1560280855-18085-1-git-send-email-luis.oliveira@synopsys.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: <linux-media.vger.kernel.org> X-Mailing-List: linux-media@vger.kernel.org |
Series |
platform: dwc: Adding DesignWare MIPI CSI-2 Host and D-PHY
|
|
Commit Message
Luis de Oliveira
June 11, 2019, 7:20 p.m. UTC
From: Luis Oliveira <lolivei@synopsys.com> Add bindings for Synopsys DesignWare MIPI CSI-2 host. Signed-off-by: Luis Oliveira <lolivei@synopsys.com> --- Changelog v3-v4 - remove "plat" from the block name @rob @laurent - remove "phy-names" when single-entry @rob - remove "snps,output-type" -> went to the driver config @laurent .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt
Comments
Hi Luis, Thank you for the patchset. On Tue, Jun 11, 2019 at 09:20:50PM +0200, Luis Oliveira wrote: > From: Luis Oliveira <lolivei@synopsys.com> > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > --- > Changelog > v3-v4 > - remove "plat" from the block name @rob @laurent > - remove "phy-names" when single-entry @rob > - remove "snps,output-type" -> went to the driver config @laurent > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > 1 file changed, 41 insertions(+) > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > new file mode 100644 > index 0000000..613b7f9 > --- /dev/null > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > @@ -0,0 +1,41 @@ > +Synopsys DesignWare CSI-2 Host controller > + > +Description > +----------- > + > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > +camera. > + > +Required properties: > +- compatible : shall be "snps,dw-csi" > +- reg : physical base address and size of the device memory > + mapped registers; > +- interrupts : DW CSI-2 Host interrupts > +- phys : List of one PHY specifier (as defined in > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > + This PHY is a MIPI DPHY working in RX mode. > +- resets : Reference to a reset controller (optional) > + > +The per-board settings: > + - port sub-node describing a single endpoint connected to the camera as > + described in video-interfaces.txt[1]. Which endpoint properties in video-interfaces.txt are relevant for the hardware? Which values may they have? > + > +Example: > + > + csi2: csi2@3000 { > + compatible = "snps,dw-csi"; > + #address-cells = <1>; > + #size-cells = <0>; > + reg = < 0x03000 0x7FF>; reg = <0x03000 0x7FF>; > + phys = <&mipi_dphy_rx>; > + resets = <&dw_rst 1>; > + interrupts = <2>; > + > + port@0 { > + reg = <0>; You can drop "@0" and the reg property. > + csi_ep1: endpoint { > + remote-endpoint = <&camera_1>; > + data-lanes = <1 2>; > + }; > + }; > + };
Hi Sakari, Thank you for your feedback. I have my comments inline. From: Sakari Ailus <sakari.ailus@iki.fi> Date: Fri, Jun 28, 2019 at 15:13:26 > Hi Luis, > > Thank you for the patchset. > > On Tue, Jun 11, 2019 at 09:20:50PM +0200, Luis Oliveira wrote: > > From: Luis Oliveira <lolivei@synopsys.com> > > > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > > --- > > Changelog > > v3-v4 > > - remove "plat" from the block name @rob @laurent > > - remove "phy-names" when single-entry @rob > > - remove "snps,output-type" -> went to the driver config @laurent > > > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > > 1 file changed, 41 insertions(+) > > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > new file mode 100644 > > index 0000000..613b7f9 > > --- /dev/null > > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > @@ -0,0 +1,41 @@ > > +Synopsys DesignWare CSI-2 Host controller > > + > > +Description > > +----------- > > + > > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > > +camera. > > + > > +Required properties: > > +- compatible : shall be "snps,dw-csi" > > +- reg : physical base address and size of the device memory > > + mapped registers; > > +- interrupts : DW CSI-2 Host interrupts > > +- phys : List of one PHY specifier (as defined in > > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > > + This PHY is a MIPI DPHY working in RX mode. > > +- resets : Reference to a reset controller (optional) > > + > > +The per-board settings: > > + - port sub-node describing a single endpoint connected to the camera as > > + described in video-interfaces.txt[1]. > > Which endpoint properties in video-interfaces.txt are relevant for the > hardware? Which values may they have? > Currently I'm using only two properties "data-lanes" and "bus-width", but I have plans to add blanking info also. I will add more info. > > + > > +Example: > > + > > + csi2: csi2@3000 { > > + compatible = "snps,dw-csi"; > > + #address-cells = <1>; > > + #size-cells = <0>; > > + reg = < 0x03000 0x7FF>; > > reg = <0x03000 0x7FF>; Yes, I've missed that. > > > + phys = <&mipi_dphy_rx>; > > + resets = <&dw_rst 1>; > > + interrupts = <2>; > > + > > + port@0 { > > + reg = <0>; > > You can drop "@0" and the reg property. Ok thank you. > > > + csi_ep1: endpoint { > > + remote-endpoint = <&camera_1>; > > + data-lanes = <1 2>; > > + }; > > + }; > > + }; > > -- > Kind regards, > > Sakari Ailus Best regards, Luis
On 11.06.2019 22:20, Luis Oliveira wrote: > From: Luis Oliveira <lolivei@synopsys.com> > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > --- > Changelog > v3-v4 > - remove "plat" from the block name @rob @laurent > - remove "phy-names" when single-entry @rob > - remove "snps,output-type" -> went to the driver config @laurent > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > 1 file changed, 41 insertions(+) > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > new file mode 100644 > index 0000000..613b7f9 > --- /dev/null > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > @@ -0,0 +1,41 @@ > +Synopsys DesignWare CSI-2 Host controller > + > +Description > +----------- > + > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > +camera. > + > +Required properties: > +- compatible : shall be "snps,dw-csi" > +- reg : physical base address and size of the device memory > + mapped registers; > +- interrupts : DW CSI-2 Host interrupts > +- phys : List of one PHY specifier (as defined in > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > + This PHY is a MIPI DPHY working in RX mode. > +- resets : Reference to a reset controller (optional) > + > +The per-board settings: > + - port sub-node describing a single endpoint connected to the camera as > + described in video-interfaces.txt[1]. > + > +Example: > + > + csi2: csi2@3000 { > + compatible = "snps,dw-csi"; > + #address-cells = <1>; > + #size-cells = <0>; > + reg = < 0x03000 0x7FF>; > + phys = <&mipi_dphy_rx>; > + resets = <&dw_rst 1>; > + interrupts = <2>; > + > + port@0 { > + reg = <0>; > + csi_ep1: endpoint { > + remote-endpoint = <&camera_1>; > + data-lanes = <1 2>; > + }; Hello Luis, Which is the output port (endpoint) : how to connect the output of csi2host to another node ? I mean, the second port of this block, or, how is the data taken from csi2host ? Thanks, Eugen > + }; > + }; >
Hi Eugen, From: Eugen.Hristev@microchip.com <Eugen.Hristev@microchip.com> Date: Tue, Jul 09, 2019 at 15:33:50 > > > On 11.06.2019 22:20, Luis Oliveira wrote: > > From: Luis Oliveira <lolivei@synopsys.com> > > > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > > --- > > Changelog > > v3-v4 > > - remove "plat" from the block name @rob @laurent > > - remove "phy-names" when single-entry @rob > > - remove "snps,output-type" -> went to the driver config @laurent > > > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > > 1 file changed, 41 insertions(+) > > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > new file mode 100644 > > index 0000000..613b7f9 > > --- /dev/null > > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > @@ -0,0 +1,41 @@ > > +Synopsys DesignWare CSI-2 Host controller > > + > > +Description > > +----------- > > + > > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > > +camera. > > + > > +Required properties: > > +- compatible : shall be "snps,dw-csi" > > +- reg : physical base address and size of the device memory > > + mapped registers; > > +- interrupts : DW CSI-2 Host interrupts > > +- phys : List of one PHY specifier (as defined in > > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > > + This PHY is a MIPI DPHY working in RX mode. > > +- resets : Reference to a reset controller (optional) > > + > > +The per-board settings: > > + - port sub-node describing a single endpoint connected to the camera as > > + described in video-interfaces.txt[1]. > > + > > +Example: > > + > > + csi2: csi2@3000 { > > + compatible = "snps,dw-csi"; > > + #address-cells = <1>; > > + #size-cells = <0>; > > + reg = < 0x03000 0x7FF>; > > + phys = <&mipi_dphy_rx>; > > + resets = <&dw_rst 1>; > > + interrupts = <2>; > > + > > + port@0 { > > + reg = <0>; > > + csi_ep1: endpoint { > > + remote-endpoint = <&camera_1>; > > + data-lanes = <1 2>; > > + }; > > Hello Luis, > > Which is the output port (endpoint) : how to connect the output of > csi2host to another node ? > I mean, the second port of this block, or, how is the data taken from > csi2host ? > I understand your question, I think you guessed this is not the complete pipeline (I have a top driver that interacts with this one). I was not planning to submit it, do you think I should? The behavior is very similar with this one ./drivers/media/platform/exynos4-is/media-dev.c > Thanks, > > Eugen > > > + }; > > + }; > > Thanks, Luis
Hi Luis, On Mon, Jul 08, 2019 at 03:21:50PM +0000, Luis de Oliveira wrote: > Hi Sakari, > > Thank you for your feedback. > I have my comments inline. > > From: Sakari Ailus <sakari.ailus@iki.fi> > Date: Fri, Jun 28, 2019 at 15:13:26 > > > Hi Luis, > > > > Thank you for the patchset. > > > > On Tue, Jun 11, 2019 at 09:20:50PM +0200, Luis Oliveira wrote: > > > From: Luis Oliveira <lolivei@synopsys.com> > > > > > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > > > > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > > > --- > > > Changelog > > > v3-v4 > > > - remove "plat" from the block name @rob @laurent > > > - remove "phy-names" when single-entry @rob > > > - remove "snps,output-type" -> went to the driver config @laurent > > > > > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > > > 1 file changed, 41 insertions(+) > > > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > new file mode 100644 > > > index 0000000..613b7f9 > > > --- /dev/null > > > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > @@ -0,0 +1,41 @@ > > > +Synopsys DesignWare CSI-2 Host controller > > > + > > > +Description > > > +----------- > > > + > > > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > > > +camera. > > > + > > > +Required properties: > > > +- compatible : shall be "snps,dw-csi" > > > +- reg : physical base address and size of the device memory > > > + mapped registers; > > > +- interrupts : DW CSI-2 Host interrupts > > > +- phys : List of one PHY specifier (as defined in > > > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > > > + This PHY is a MIPI DPHY working in RX mode. > > > +- resets : Reference to a reset controller (optional) > > > + > > > +The per-board settings: > > > + - port sub-node describing a single endpoint connected to the camera as > > > + described in video-interfaces.txt[1]. > > > > Which endpoint properties in video-interfaces.txt are relevant for the > > hardware? Which values may they have? > > > > Currently I'm using only two properties "data-lanes" and "bus-width", but > I have plans to add blanking info also. > I will add more info. Isn't blanking defined by what the transmitter seneds? Or do you have hardware limitations on the receiver side? I've only heard of one such case before, and it was a very old parallel receiver. If you have a CSI-2 receiver, bus-width isn't relevant --- it's for paralle interfaces only. Please add data-lanes to required endpoint properties.
On 09.07.2019 20:08, Luis de Oliveira wrote: > > Hi Eugen, > > > From: Eugen.Hristev@microchip.com <Eugen.Hristev@microchip.com> > Date: Tue, Jul 09, 2019 at 15:33:50 > >> >> >> On 11.06.2019 22:20, Luis Oliveira wrote: >>> From: Luis Oliveira <lolivei@synopsys.com> >>> >>> Add bindings for Synopsys DesignWare MIPI CSI-2 host. >>> >>> Signed-off-by: Luis Oliveira <lolivei@synopsys.com> >>> --- >>> Changelog >>> v3-v4 >>> - remove "plat" from the block name @rob @laurent >>> - remove "phy-names" when single-entry @rob >>> - remove "snps,output-type" -> went to the driver config @laurent >>> >>> .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ >>> 1 file changed, 41 insertions(+) >>> create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt >>> >>> diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt >>> new file mode 100644 >>> index 0000000..613b7f9 >>> --- /dev/null >>> +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt >>> @@ -0,0 +1,41 @@ >>> +Synopsys DesignWare CSI-2 Host controller >>> + >>> +Description >>> +----------- >>> + >>> +This HW block is used to receive image coming from an MIPI CSI-2 compatible >>> +camera. >>> + >>> +Required properties: >>> +- compatible : shall be "snps,dw-csi" >>> +- reg : physical base address and size of the device memory >>> + mapped registers; >>> +- interrupts : DW CSI-2 Host interrupts >>> +- phys : List of one PHY specifier (as defined in >>> + Documentation/devicetree/bindings/phy/phy-bindings.txt). >>> + This PHY is a MIPI DPHY working in RX mode. >>> +- resets : Reference to a reset controller (optional) >>> + >>> +The per-board settings: >>> + - port sub-node describing a single endpoint connected to the camera as >>> + described in video-interfaces.txt[1]. >>> + >>> +Example: >>> + >>> + csi2: csi2@3000 { >>> + compatible = "snps,dw-csi"; >>> + #address-cells = <1>; >>> + #size-cells = <0>; >>> + reg = < 0x03000 0x7FF>; >>> + phys = <&mipi_dphy_rx>; >>> + resets = <&dw_rst 1>; >>> + interrupts = <2>; >>> + >>> + port@0 { >>> + reg = <0>; >>> + csi_ep1: endpoint { >>> + remote-endpoint = <&camera_1>; >>> + data-lanes = <1 2>; >>> + }; >> >> Hello Luis, >> >> Which is the output port (endpoint) : how to connect the output of >> csi2host to another node ? >> I mean, the second port of this block, or, how is the data taken from >> csi2host ? >> > > I understand your question, I think you guessed this is not the complete > pipeline (I have a top driver that interacts with this one). > I was not planning to submit it, do you think I should? Yes please, you can have the patch with subject DO NOT MERGE if you do not want that patch to be included in the kernel and just for reference. but it would help me in understanding your setup Thanks ! > > The behavior is very similar with this one > ./drivers/media/platform/exynos4-is/media-dev.c > > >> Thanks, >> >> Eugen >> >>> + }; >>> + }; >>> > > Thanks, > Luis >
Hi Sakari, From: Sakari Ailus <sakari.ailus@iki.fi> Date: Tue, Jul 09, 2019 at 19:25:00 > Hi Luis, > > On Mon, Jul 08, 2019 at 03:21:50PM +0000, Luis de Oliveira wrote: > > Hi Sakari, > > > > Thank you for your feedback. > > I have my comments inline. > > > > From: Sakari Ailus <sakari.ailus@iki.fi> > > Date: Fri, Jun 28, 2019 at 15:13:26 > > > > > Hi Luis, > > > > > > Thank you for the patchset. > > > > > > On Tue, Jun 11, 2019 at 09:20:50PM +0200, Luis Oliveira wrote: > > > > From: Luis Oliveira <lolivei@synopsys.com> > > > > > > > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > > > > > > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > > > > --- > > > > Changelog > > > > v3-v4 > > > > - remove "plat" from the block name @rob @laurent > > > > - remove "phy-names" when single-entry @rob > > > > - remove "snps,output-type" -> went to the driver config @laurent > > > > > > > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > > > > 1 file changed, 41 insertions(+) > > > > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > > > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > new file mode 100644 > > > > index 0000000..613b7f9 > > > > --- /dev/null > > > > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > @@ -0,0 +1,41 @@ > > > > +Synopsys DesignWare CSI-2 Host controller > > > > + > > > > +Description > > > > +----------- > > > > + > > > > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > > > > +camera. > > > > + > > > > +Required properties: > > > > +- compatible : shall be "snps,dw-csi" > > > > +- reg : physical base address and size of the device memory > > > > + mapped registers; > > > > +- interrupts : DW CSI-2 Host interrupts > > > > +- phys : List of one PHY specifier (as defined in > > > > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > > > > + This PHY is a MIPI DPHY working in RX mode. > > > > +- resets : Reference to a reset controller (optional) > > > > + > > > > +The per-board settings: > > > > + - port sub-node describing a single endpoint connected to the camera as > > > > + described in video-interfaces.txt[1]. > > > > > > Which endpoint properties in video-interfaces.txt are relevant for the > > > hardware? Which values may they have? > > > > > > > Currently I'm using only two properties "data-lanes" and "bus-width", but > > I have plans to add blanking info also. > > I will add more info. > > Isn't blanking defined by what the transmitter seneds? Or do you have > hardware limitations on the receiver side? > When we use this IP in prototyping we configure blanking at the receiver side. Some cameras don't have blanking configuration capabilities so we configure it on the RX side. > I've only heard of one such case before, and it was a very old parallel > receiver. > > If you have a CSI-2 receiver, bus-width isn't relevant --- it's for paralle > interfaces only. Please add data-lanes to required endpoint properties. > I used bus-width property in the Synopsys IPI (Image Pixel Interface) that enables direct video stream access. This interface is an output that can be 16-bit or 48-bit, that's why I used bus-width property. > -- > Regards, > > Sakari Ailus Thank you, Luis
Hi Eugen, From: Eugen.Hristev@microchip.com <Eugen.Hristev@microchip.com> Date: Wed, Jul 10, 2019 at 07:53:02 > > > On 09.07.2019 20:08, Luis de Oliveira wrote: > > > > > Hi Eugen, > > > > > > From: Eugen.Hristev@microchip.com <Eugen.Hristev@microchip.com> > > Date: Tue, Jul 09, 2019 at 15:33:50 > > > >> > >> > >> On 11.06.2019 22:20, Luis Oliveira wrote: > >>> From: Luis Oliveira <lolivei@synopsys.com> > >>> > >>> Add bindings for Synopsys DesignWare MIPI CSI-2 host. > >>> > >>> Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > >>> --- > >>> Changelog > >>> v3-v4 > >>> - remove "plat" from the block name @rob @laurent > >>> - remove "phy-names" when single-entry @rob > >>> - remove "snps,output-type" -> went to the driver config @laurent > >>> > >>> .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > >>> 1 file changed, 41 insertions(+) > >>> create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > >>> > >>> diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > >>> new file mode 100644 > >>> index 0000000..613b7f9 > >>> --- /dev/null > >>> +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > >>> @@ -0,0 +1,41 @@ > >>> +Synopsys DesignWare CSI-2 Host controller > >>> + > >>> +Description > >>> +----------- > >>> + > >>> +This HW block is used to receive image coming from an MIPI CSI-2 compatible > >>> +camera. > >>> + > >>> +Required properties: > >>> +- compatible : shall be "snps,dw-csi" > >>> +- reg : physical base address and size of the device memory > >>> + mapped registers; > >>> +- interrupts : DW CSI-2 Host interrupts > >>> +- phys : List of one PHY specifier (as defined in > >>> + Documentation/devicetree/bindings/phy/phy-bindings.txt). > >>> + This PHY is a MIPI DPHY working in RX mode. > >>> +- resets : Reference to a reset controller (optional) > >>> + > >>> +The per-board settings: > >>> + - port sub-node describing a single endpoint connected to the camera as > >>> + described in video-interfaces.txt[1]. > >>> + > >>> +Example: > >>> + > >>> + csi2: csi2@3000 { > >>> + compatible = "snps,dw-csi"; > >>> + #address-cells = <1>; > >>> + #size-cells = <0>; > >>> + reg = < 0x03000 0x7FF>; > >>> + phys = <&mipi_dphy_rx>; > >>> + resets = <&dw_rst 1>; > >>> + interrupts = <2>; > >>> + > >>> + port@0 { > >>> + reg = <0>; > >>> + csi_ep1: endpoint { > >>> + remote-endpoint = <&camera_1>; > >>> + data-lanes = <1 2>; > >>> + }; > >> > >> Hello Luis, > >> > >> Which is the output port (endpoint) : how to connect the output of > >> csi2host to another node ? > >> I mean, the second port of this block, or, how is the data taken from > >> csi2host ? > >> > > > > I understand your question, I think you guessed this is not the complete > > pipeline (I have a top driver that interacts with this one). > > I was not planning to submit it, do you think I should? > > Yes please, you can have the patch with subject DO NOT MERGE if you do > not want that patch to be included in the kernel and just for reference. > but it would help me in understanding your setup > > Thanks ! > Ok, thank you. I will included it next. > > > > The behavior is very similar with this one > > ./drivers/media/platform/exynos4-is/media-dev.c > > > > > >> Thanks, > >> > >> Eugen > >> > >>> + }; > >>> + }; > >>> > > > > Thanks, > > Luis > >
Hi Luis, On Wed, Jul 10, 2019 at 10:20:55AM +0000, Luis de Oliveira wrote: > Hi Sakari, > > From: Sakari Ailus <sakari.ailus@iki.fi> > Date: Tue, Jul 09, 2019 at 19:25:00 > > > Hi Luis, > > > > On Mon, Jul 08, 2019 at 03:21:50PM +0000, Luis de Oliveira wrote: > > > Hi Sakari, > > > > > > Thank you for your feedback. > > > I have my comments inline. > > > > > > From: Sakari Ailus <sakari.ailus@iki.fi> > > > Date: Fri, Jun 28, 2019 at 15:13:26 > > > > > > > Hi Luis, > > > > > > > > Thank you for the patchset. > > > > > > > > On Tue, Jun 11, 2019 at 09:20:50PM +0200, Luis Oliveira wrote: > > > > > From: Luis Oliveira <lolivei@synopsys.com> > > > > > > > > > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > > > > > > > > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > > > > > --- > > > > > Changelog > > > > > v3-v4 > > > > > - remove "plat" from the block name @rob @laurent > > > > > - remove "phy-names" when single-entry @rob > > > > > - remove "snps,output-type" -> went to the driver config @laurent > > > > > > > > > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > > > > > 1 file changed, 41 insertions(+) > > > > > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > > > > > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > new file mode 100644 > > > > > index 0000000..613b7f9 > > > > > --- /dev/null > > > > > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > @@ -0,0 +1,41 @@ > > > > > +Synopsys DesignWare CSI-2 Host controller > > > > > + > > > > > +Description > > > > > +----------- > > > > > + > > > > > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > > > > > +camera. > > > > > + > > > > > +Required properties: > > > > > +- compatible : shall be "snps,dw-csi" > > > > > +- reg : physical base address and size of the device memory > > > > > + mapped registers; > > > > > +- interrupts : DW CSI-2 Host interrupts > > > > > +- phys : List of one PHY specifier (as defined in > > > > > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > > > > > + This PHY is a MIPI DPHY working in RX mode. > > > > > +- resets : Reference to a reset controller (optional) > > > > > + > > > > > +The per-board settings: > > > > > + - port sub-node describing a single endpoint connected to the camera as > > > > > + described in video-interfaces.txt[1]. > > > > > > > > Which endpoint properties in video-interfaces.txt are relevant for the > > > > hardware? Which values may they have? > > > > > > > > > > Currently I'm using only two properties "data-lanes" and "bus-width", but > > > I have plans to add blanking info also. > > > I will add more info. > > > > Isn't blanking defined by what the transmitter seneds? Or do you have > > hardware limitations on the receiver side? > > > > When we use this IP in prototyping we configure blanking at the receiver > side. > Some cameras don't have blanking configuration capabilities so we > configure it on the RX side. I haven't come across a CSI-2 connected camera without some kind of blanking configuration capabilities. Even if there was one, you couldn't configure blanking from the receiver side. Please document that the data-lanes property is required, and which values are possible. > > > I've only heard of one such case before, and it was a very old parallel > > receiver. > > > > If you have a CSI-2 receiver, bus-width isn't relevant --- it's for paralle > > interfaces only. Please add data-lanes to required endpoint properties. > > > > I used bus-width property in the Synopsys IPI (Image Pixel Interface) > that enables direct video stream access. > This interface is an output that can be 16-bit or 48-bit, that's why I > used bus-width property. Does this device write the image data to system memory, or is it another device? If there's another one, then you should probably have another port to describe that connection.
Hi Sakari, Thank you for the review, my answers inline. > From: Sakari Ailus <sakari.ailus@iki.fi> > Date: Thu, Jul 25, 2019 at 21:02:11 > > Hi Luis, > > On Wed, Jul 10, 2019 at 10:20:55AM +0000, Luis de Oliveira wrote: > > Hi Sakari, > > > > From: Sakari Ailus <sakari.ailus@iki.fi> > > Date: Tue, Jul 09, 2019 at 19:25:00 > > > > > Hi Luis, > > > > > > On Mon, Jul 08, 2019 at 03:21:50PM +0000, Luis de Oliveira wrote: > > > > Hi Sakari, > > > > > > > > Thank you for your feedback. > > > > I have my comments inline. > > > > > > > > From: Sakari Ailus <sakari.ailus@iki.fi> > > > > Date: Fri, Jun 28, 2019 at 15:13:26 > > > > > > > > > Hi Luis, > > > > > > > > > > Thank you for the patchset. > > > > > > > > > > On Tue, Jun 11, 2019 at 09:20:50PM +0200, Luis Oliveira wrote: > > > > > > From: Luis Oliveira <lolivei@synopsys.com> > > > > > > > > > > > > Add bindings for Synopsys DesignWare MIPI CSI-2 host. > > > > > > > > > > > > Signed-off-by: Luis Oliveira <lolivei@synopsys.com> > > > > > > --- > > > > > > Changelog > > > > > > v3-v4 > > > > > > - remove "plat" from the block name @rob @laurent > > > > > > - remove "phy-names" when single-entry @rob > > > > > > - remove "snps,output-type" -> went to the driver config @laurent > > > > > > > > > > > > .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ > > > > > > 1 file changed, 41 insertions(+) > > > > > > create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > > > > > > > > diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > > new file mode 100644 > > > > > > index 0000000..613b7f9 > > > > > > --- /dev/null > > > > > > +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt > > > > > > @@ -0,0 +1,41 @@ > > > > > > +Synopsys DesignWare CSI-2 Host controller > > > > > > + > > > > > > +Description > > > > > > +----------- > > > > > > + > > > > > > +This HW block is used to receive image coming from an MIPI CSI-2 compatible > > > > > > +camera. > > > > > > + > > > > > > +Required properties: > > > > > > +- compatible : shall be "snps,dw-csi" > > > > > > +- reg : physical base address and size of the device memory > > > > > > + mapped registers; > > > > > > +- interrupts : DW CSI-2 Host interrupts > > > > > > +- phys : List of one PHY specifier (as defined in > > > > > > + Documentation/devicetree/bindings/phy/phy-bindings.txt). > > > > > > + This PHY is a MIPI DPHY working in RX mode. > > > > > > +- resets : Reference to a reset controller (optional) > > > > > > + > > > > > > +The per-board settings: > > > > > > + - port sub-node describing a single endpoint connected to the camera as > > > > > > + described in video-interfaces.txt[1]. > > > > > > > > > > Which endpoint properties in video-interfaces.txt are relevant for the > > > > > hardware? Which values may they have? > > > > > > > > > > > > > Currently I'm using only two properties "data-lanes" and "bus-width", but > > > > I have plans to add blanking info also. > > > > I will add more info. > > > > > > Isn't blanking defined by what the transmitter seneds? Or do you have > > > hardware limitations on the receiver side? > > > > > > > When we use this IP in prototyping we configure blanking at the receiver > > side. > > Some cameras don't have blanking configuration capabilities so we > > configure it on the RX side. > > I haven't come across a CSI-2 connected camera without some kind of > blanking configuration capabilities. Even if there was one, you couldn't > configure blanking from the receiver side. > > Please document that the data-lanes property is required, and which values > are possible. > Ok, I will add the data-lanes property to the Documentation. > > > > > I've only heard of one such case before, and it was a very old parallel > > > receiver. > > > > > > If you have a CSI-2 receiver, bus-width isn't relevant --- it's for paralle > > > interfaces only. Please add data-lanes to required endpoint properties. > > > > > > > I used bus-width property in the Synopsys IPI (Image Pixel Interface) > > that enables direct video stream access. > > This interface is an output that can be 16-bit or 48-bit, that's why I > > used bus-width property. > > Does this device write the image data to system memory, or is it another > device? If there's another one, then you should probably have another port > to describe that connection. > Yes, it is another. I can add that connection port also. > -- > Kind regards, > > Sakari Ailus Thank you, Luis
On 26.07.2019 12:50, Luis de Oliveira wrote: > Hi Sakari, > > Thank you for the review, my answers inline. > >> From: Sakari Ailus <sakari.ailus@iki.fi> >> Date: Thu, Jul 25, 2019 at 21:02:11 >> >> Hi Luis, >> >> On Wed, Jul 10, 2019 at 10:20:55AM +0000, Luis de Oliveira wrote: >>> Hi Sakari, >>> >>> From: Sakari Ailus <sakari.ailus@iki.fi> >>> Date: Tue, Jul 09, 2019 at 19:25:00 >>> >>>> Hi Luis, >>>> >>>> On Mon, Jul 08, 2019 at 03:21:50PM +0000, Luis de Oliveira wrote: >>>>> Hi Sakari, >>>>> >>>>> Thank you for your feedback. >>>>> I have my comments inline. >>>>> >>>>> From: Sakari Ailus <sakari.ailus@iki.fi> >>>>> Date: Fri, Jun 28, 2019 at 15:13:26 >>>>> >>>>>> Hi Luis, >>>>>> >>>>>> Thank you for the patchset. >>>>>> >>>>>> On Tue, Jun 11, 2019 at 09:20:50PM +0200, Luis Oliveira wrote: >>>>>>> From: Luis Oliveira <lolivei@synopsys.com> >>>>>>> >>>>>>> Add bindings for Synopsys DesignWare MIPI CSI-2 host. >>>>>>> >>>>>>> Signed-off-by: Luis Oliveira <lolivei@synopsys.com> >>>>>>> --- >>>>>>> Changelog >>>>>>> v3-v4 >>>>>>> - remove "plat" from the block name @rob @laurent >>>>>>> - remove "phy-names" when single-entry @rob >>>>>>> - remove "snps,output-type" -> went to the driver config @laurent >>>>>>> >>>>>>> .../devicetree/bindings/media/snps,dw-csi.txt | 41 ++++++++++++++++++++++ >>>>>>> 1 file changed, 41 insertions(+) >>>>>>> create mode 100644 Documentation/devicetree/bindings/media/snps,dw-csi.txt >>>>>>> >>>>>>> diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt >>>>>>> new file mode 100644 >>>>>>> index 0000000..613b7f9 >>>>>>> --- /dev/null >>>>>>> +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt >>>>>>> @@ -0,0 +1,41 @@ >>>>>>> +Synopsys DesignWare CSI-2 Host controller >>>>>>> + >>>>>>> +Description >>>>>>> +----------- >>>>>>> + >>>>>>> +This HW block is used to receive image coming from an MIPI CSI-2 compatible >>>>>>> +camera. >>>>>>> + >>>>>>> +Required properties: >>>>>>> +- compatible : shall be "snps,dw-csi" >>>>>>> +- reg : physical base address and size of the device memory >>>>>>> + mapped registers; >>>>>>> +- interrupts : DW CSI-2 Host interrupts >>>>>>> +- phys : List of one PHY specifier (as defined in >>>>>>> + Documentation/devicetree/bindings/phy/phy-bindings.txt). >>>>>>> + This PHY is a MIPI DPHY working in RX mode. >>>>>>> +- resets : Reference to a reset controller (optional) >>>>>>> + >>>>>>> +The per-board settings: >>>>>>> + - port sub-node describing a single endpoint connected to the camera as >>>>>>> + described in video-interfaces.txt[1]. >>>>>> >>>>>> Which endpoint properties in video-interfaces.txt are relevant for the >>>>>> hardware? Which values may they have? >>>>>> >>>>> >>>>> Currently I'm using only two properties "data-lanes" and "bus-width", but >>>>> I have plans to add blanking info also. >>>>> I will add more info. >>>> >>>> Isn't blanking defined by what the transmitter seneds? Or do you have >>>> hardware limitations on the receiver side? >>>> >>> >>> When we use this IP in prototyping we configure blanking at the receiver >>> side. >>> Some cameras don't have blanking configuration capabilities so we >>> configure it on the RX side. >> >> I haven't come across a CSI-2 connected camera without some kind of >> blanking configuration capabilities. Even if there was one, you couldn't >> configure blanking from the receiver side. >> >> Please document that the data-lanes property is required, and which values >> are possible. >> > > Ok, I will add the data-lanes property to the Documentation. > >>> >>>> I've only heard of one such case before, and it was a very old parallel >>>> receiver. >>>> >>>> If you have a CSI-2 receiver, bus-width isn't relevant --- it's for paralle >>>> interfaces only. Please add data-lanes to required endpoint properties. >>>> >>> >>> I used bus-width property in the Synopsys IPI (Image Pixel Interface) >>> that enables direct video stream access. >>> This interface is an output that can be 16-bit or 48-bit, that's why I >>> used bus-width property. >> >> Does this device write the image data to system memory, or is it another >> device? If there's another one, then you should probably have another port >> to describe that connection. >> > > Yes, it is another. I can add that connection port also. Yes please. It is interesting for me to see how to connect the output of this device to another media device, and how to specify the bus in this situation. Thanks, Eugen > > >> -- >> Kind regards, >> >> Sakari Ailus > > Thank you, > > Luis > >
diff --git a/Documentation/devicetree/bindings/media/snps,dw-csi.txt b/Documentation/devicetree/bindings/media/snps,dw-csi.txt new file mode 100644 index 0000000..613b7f9 --- /dev/null +++ b/Documentation/devicetree/bindings/media/snps,dw-csi.txt @@ -0,0 +1,41 @@ +Synopsys DesignWare CSI-2 Host controller + +Description +----------- + +This HW block is used to receive image coming from an MIPI CSI-2 compatible +camera. + +Required properties: +- compatible : shall be "snps,dw-csi" +- reg : physical base address and size of the device memory + mapped registers; +- interrupts : DW CSI-2 Host interrupts +- phys : List of one PHY specifier (as defined in + Documentation/devicetree/bindings/phy/phy-bindings.txt). + This PHY is a MIPI DPHY working in RX mode. +- resets : Reference to a reset controller (optional) + +The per-board settings: + - port sub-node describing a single endpoint connected to the camera as + described in video-interfaces.txt[1]. + +Example: + + csi2: csi2@3000 { + compatible = "snps,dw-csi"; + #address-cells = <1>; + #size-cells = <0>; + reg = < 0x03000 0x7FF>; + phys = <&mipi_dphy_rx>; + resets = <&dw_rst 1>; + interrupts = <2>; + + port@0 { + reg = <0>; + csi_ep1: endpoint { + remote-endpoint = <&camera_1>; + data-lanes = <1 2>; + }; + }; + };