* [Query] : DT: Adding mezzanine board @ 2020-02-19 11:42 Lad, Prabhakar 2020-02-19 12:08 ` Laurent Pinchart 0 siblings, 1 reply; 5+ messages in thread From: Lad, Prabhakar @ 2020-02-19 11:42 UTC (permalink / raw) To: Hans Verkuil, Laurent Pinchart, Sakari Ailus; +Cc: linux-media Hi, I am working Renesas RZ/Gx platforms, these boards have support for connecting MIPI adapter mezzanine board [1]. To enable this support I am planning to create a dtsi which will include the board file and enable the necessary VIN/CSI and the camera endpoint. For example: to add support for G2E board I would create a file named r8a774c0-cat874-mipi-adapter.dtsi which will include the board file r8a774c0.dtsi and enable necessary VIN/CSI/Camera endpoint and when user wants to enable this support for the G2E board he could just include r8a774c0-cat874-mipi-adapter.dtsi to r8a774c0-cat874.dts Would this be a good approach or is there an alternative way which I am missing. [1] https://github.com/Kevin-WSCU/96Boards-Camera/blob/master/AISTARVISION%20MIPI%20Adapter%20V2.1/AISTARVISION%20MIPI%20Adapter%20V2.1.pdf Cheers, --Prabhakar Lad ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Query] : DT: Adding mezzanine board 2020-02-19 11:42 [Query] : DT: Adding mezzanine board Lad, Prabhakar @ 2020-02-19 12:08 ` Laurent Pinchart 2020-02-19 12:25 ` Lad, Prabhakar 0 siblings, 1 reply; 5+ messages in thread From: Laurent Pinchart @ 2020-02-19 12:08 UTC (permalink / raw) To: Lad, Prabhakar; +Cc: Hans Verkuil, Sakari Ailus, linux-media Hi Prabhakar, On Wed, Feb 19, 2020 at 11:42:42AM +0000, Lad, Prabhakar wrote: > Hi, > > I am working Renesas RZ/Gx platforms, these boards have support for > connecting MIPI adapter mezzanine board [1]. To enable this support I > am planning to create a dtsi which will include the board file and > enable the necessary VIN/CSI and the camera endpoint. > > For example: to add support for G2E board I would create a file named > r8a774c0-cat874-mipi-adapter.dtsi which will include the board file > r8a774c0.dtsi and enable necessary VIN/CSI/Camera endpoint and when > user wants to enable this support for the G2E board he could just > include r8a774c0-cat874-mipi-adapter.dtsi to r8a774c0-cat874.dts > > Would this be a good approach or is there an alternative way which I am missing. DT overlays are another option. They can't be applied on a running system though. It doesn't seem like the mezzanine boards can be detected by the boot loader, so overlays can't be applied automatically before the kernel is started. One option would still be to provide them to U-Boot and apply a selected overlay based on environment variables. Another option would be to apply overlays as part of the build process, which shouldn't require modifying the DT sources to #include the .dtsi file for the mezzanine board. > [1] https://github.com/Kevin-WSCU/96Boards-Camera/blob/master/AISTARVISION%20MIPI%20Adapter%20V2.1/AISTARVISION%20MIPI%20Adapter%20V2.1.pdf -- Regards, Laurent Pinchart ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Query] : DT: Adding mezzanine board 2020-02-19 12:08 ` Laurent Pinchart @ 2020-02-19 12:25 ` Lad, Prabhakar 2020-02-19 12:32 ` Laurent Pinchart 0 siblings, 1 reply; 5+ messages in thread From: Lad, Prabhakar @ 2020-02-19 12:25 UTC (permalink / raw) To: Laurent Pinchart; +Cc: Hans Verkuil, Sakari Ailus, linux-media Hi Laurent, On Wed, Feb 19, 2020 at 12:08 PM Laurent Pinchart <laurent.pinchart@ideasonboard.com> wrote: > > Hi Prabhakar, > > On Wed, Feb 19, 2020 at 11:42:42AM +0000, Lad, Prabhakar wrote: > > Hi, > > > > I am working Renesas RZ/Gx platforms, these boards have support for > > connecting MIPI adapter mezzanine board [1]. To enable this support I > > am planning to create a dtsi which will include the board file and > > enable the necessary VIN/CSI and the camera endpoint. > > > > For example: to add support for G2E board I would create a file named > > r8a774c0-cat874-mipi-adapter.dtsi which will include the board file > > r8a774c0.dtsi and enable necessary VIN/CSI/Camera endpoint and when > > user wants to enable this support for the G2E board he could just > > include r8a774c0-cat874-mipi-adapter.dtsi to r8a774c0-cat874.dts > > > > Would this be a good approach or is there an alternative way which I am missing. > > DT overlays are another option. They can't be applied on a running > system though. It doesn't seem like the mezzanine boards can be detected > by the boot loader, so overlays can't be applied automatically before > the kernel is started. One option would still be to provide them to > U-Boot and apply a selected overlay based on environment variables. > Another option would be to apply overlays as part of the build process, > which shouldn't require modifying the DT sources to #include the .dtsi > file for the mezzanine board. > Thank you for the insight, overlay is something which I wanted to avoid and have the dtb as part of kernel itself. How about just creating r8a774c0-cat874-mipi-adapter.dts which would include r8a774c0-cat874.dts file and enable the VIN/CSI/Camera endpoint, so the user would just use r8a774c0-cat874-mipi-adapter.dtb file when the mipi adapter is connected ? Cheers, --Prabhakar > > [1] https://github.com/Kevin-WSCU/96Boards-Camera/blob/master/AISTARVISION%20MIPI%20Adapter%20V2.1/AISTARVISION%20MIPI%20Adapter%20V2.1.pdf > > -- > Regards, > > Laurent Pinchart ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Query] : DT: Adding mezzanine board 2020-02-19 12:25 ` Lad, Prabhakar @ 2020-02-19 12:32 ` Laurent Pinchart 2020-02-19 13:56 ` Lad, Prabhakar 0 siblings, 1 reply; 5+ messages in thread From: Laurent Pinchart @ 2020-02-19 12:32 UTC (permalink / raw) To: Lad, Prabhakar; +Cc: Hans Verkuil, Sakari Ailus, linux-media Hi Prabhakar, On Wed, Feb 19, 2020 at 12:25:37PM +0000, Lad, Prabhakar wrote: > On Wed, Feb 19, 2020 at 12:08 PM Laurent Pinchart wrote: > > On Wed, Feb 19, 2020 at 11:42:42AM +0000, Lad, Prabhakar wrote: > > > Hi, > > > > > > I am working Renesas RZ/Gx platforms, these boards have support for > > > connecting MIPI adapter mezzanine board [1]. To enable this support I > > > am planning to create a dtsi which will include the board file and > > > enable the necessary VIN/CSI and the camera endpoint. > > > > > > For example: to add support for G2E board I would create a file named > > > r8a774c0-cat874-mipi-adapter.dtsi which will include the board file > > > r8a774c0.dtsi and enable necessary VIN/CSI/Camera endpoint and when > > > user wants to enable this support for the G2E board he could just > > > include r8a774c0-cat874-mipi-adapter.dtsi to r8a774c0-cat874.dts > > > > > > Would this be a good approach or is there an alternative way which I am missing. > > > > DT overlays are another option. They can't be applied on a running > > system though. It doesn't seem like the mezzanine boards can be detected > > by the boot loader, so overlays can't be applied automatically before > > the kernel is started. One option would still be to provide them to > > U-Boot and apply a selected overlay based on environment variables. > > Another option would be to apply overlays as part of the build process, > > which shouldn't require modifying the DT sources to #include the .dtsi > > file for the mezzanine board. > > Thank you for the insight, overlay is something which I wanted to > avoid and have the dtb as part of kernel itself. How about just > creating r8a774c0-cat874-mipi-adapter.dts which would include > r8a774c0-cat874.dts file and enable the VIN/CSI/Camera endpoint, so > the user would just use r8a774c0-cat874-mipi-adapter.dtb file when the > mipi adapter is connected ? That would restrict usage of the mezzanine board to a particular base board, while in the general case there could be different types of base boards compatible with a set of mezzanines. The reason why I mentioned overlay isn't really to apply them dynamically, but for the set of tools around them. Bootloaders can apply overlays, and we can also apply overlays to a DTB as part of a build process, without patching the source. Is there a particular reason why you would prefer avoiding them ? > > > [1] https://github.com/Kevin-WSCU/96Boards-Camera/blob/master/AISTARVISION%20MIPI%20Adapter%20V2.1/AISTARVISION%20MIPI%20Adapter%20V2.1.pdf -- Regards, Laurent Pinchart ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Query] : DT: Adding mezzanine board 2020-02-19 12:32 ` Laurent Pinchart @ 2020-02-19 13:56 ` Lad, Prabhakar 0 siblings, 0 replies; 5+ messages in thread From: Lad, Prabhakar @ 2020-02-19 13:56 UTC (permalink / raw) To: Laurent Pinchart; +Cc: Hans Verkuil, Sakari Ailus, linux-media Hi Laurent, On Wed, Feb 19, 2020 at 12:33 PM Laurent Pinchart <laurent.pinchart@ideasonboard.com> wrote: > > Hi Prabhakar, > > On Wed, Feb 19, 2020 at 12:25:37PM +0000, Lad, Prabhakar wrote: > > On Wed, Feb 19, 2020 at 12:08 PM Laurent Pinchart wrote: > > > On Wed, Feb 19, 2020 at 11:42:42AM +0000, Lad, Prabhakar wrote: > > > > Hi, > > > > > > > > I am working Renesas RZ/Gx platforms, these boards have support for > > > > connecting MIPI adapter mezzanine board [1]. To enable this support I > > > > am planning to create a dtsi which will include the board file and > > > > enable the necessary VIN/CSI and the camera endpoint. > > > > > > > > For example: to add support for G2E board I would create a file named > > > > r8a774c0-cat874-mipi-adapter.dtsi which will include the board file > > > > r8a774c0.dtsi and enable necessary VIN/CSI/Camera endpoint and when > > > > user wants to enable this support for the G2E board he could just > > > > include r8a774c0-cat874-mipi-adapter.dtsi to r8a774c0-cat874.dts > > > > > > > > Would this be a good approach or is there an alternative way which I am missing. > > > > > > DT overlays are another option. They can't be applied on a running > > > system though. It doesn't seem like the mezzanine boards can be detected > > > by the boot loader, so overlays can't be applied automatically before > > > the kernel is started. One option would still be to provide them to > > > U-Boot and apply a selected overlay based on environment variables. > > > Another option would be to apply overlays as part of the build process, > > > which shouldn't require modifying the DT sources to #include the .dtsi > > > file for the mezzanine board. > > > > Thank you for the insight, overlay is something which I wanted to > > avoid and have the dtb as part of kernel itself. How about just > > creating r8a774c0-cat874-mipi-adapter.dts which would include > > r8a774c0-cat874.dts file and enable the VIN/CSI/Camera endpoint, so > > the user would just use r8a774c0-cat874-mipi-adapter.dtb file when the > > mipi adapter is connected ? > > That would restrict usage of the mezzanine board to a particular base > board, while in the general case there could be different types of base > boards compatible with a set of mezzanines. > > The reason why I mentioned overlay isn't really to apply them > dynamically, but for the set of tools around them. Bootloaders can apply > overlays, and we can also apply overlays to a DTB as part of a build > process, without patching the source. Is there a particular reason why > you would prefer avoiding them ? > Just didnt wanted to maintain to the DT overlay separately, but looks like overlay itself would be a way to go. Thank you for the inputs. Cheers, --Prabhakar > > > > [1] https://github.com/Kevin-WSCU/96Boards-Camera/blob/master/AISTARVISION%20MIPI%20Adapter%20V2.1/AISTARVISION%20MIPI%20Adapter%20V2.1.pdf > > -- > Regards, > > Laurent Pinchart ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2020-02-19 13:57 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2020-02-19 11:42 [Query] : DT: Adding mezzanine board Lad, Prabhakar 2020-02-19 12:08 ` Laurent Pinchart 2020-02-19 12:25 ` Lad, Prabhakar 2020-02-19 12:32 ` Laurent Pinchart 2020-02-19 13:56 ` Lad, Prabhakar
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox