IOMUX Spreadsheet for i.MX8-ULP Hi, I am currently working on the i.MX8ULP device tree files to have the OV5640 camera working with libcamera on the MCIMX8ULP-EVK9 evaluation kit. The modifications Among the changes I have made, I replaced the following in imx8ulp.dtsi: - mipi_csi0: csi@2daf0000 {
- compatible = "fsl,imx8ulp-mipi-csi2", "fsl,mxc-mipi-csi2";
- reg = <0x2daf0000 0x10000>,
- <0x2dad0000 0x10000>;
- clocks = <&pcc5 IMX8ULP_CLK_CSI>,
- <&pcc5 IMX8ULP_CLK_CSI_CLK_UI>,
- <&pcc5 IMX8ULP_CLK_CSI_CLK_ESC>,
- <&pcc5 IMX8ULP_CLK_CSI_REGS>;
- clock-names = "clk_core", "clk_ui", "clk_esc", "clk_regs";
- power-domains = <&scmi_devpd IMX8ULP_PD_MIPI_CSI>;
- assigned-clocks = <&cgc2 IMX8ULP_CLK_PLL4_PFD1>,
- <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV1>,
- <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV2>,
- <&pcc5 IMX8ULP_CLK_CSI>,
- <&pcc5 IMX8ULP_CLK_CSI_CLK_UI>,
- <&pcc5 IMX8ULP_CLK_CSI_CLK_ESC>;
- assigned-clock-parents = <0>, <0>, <0>,
- <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV1>,
- <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV2>,
- <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV2>;
- assigned-clock-rates = <316800000>,
- <316800000>,
- <316800000>,
- <105600000>,
- <79200000>,
- <79200000>;
- runtime_suspend;
- status = "disabled";
+ mipi_csi0: csi@2daf0000 {
+ compatible = "fsl,imx8mp-mipi-csi2", "fsl,imx8mm-mipi-csi2";
+ reg = <0x2daf0000 0x10000>,
+ <0x2dad0000 0x10000>;
+ interrupts = ;
+ clocks = <&cgc2 IMX8ULP_CLK_LPAV_BUS_DIV>,
+ <&pcc5 IMX8ULP_CLK_CSI_CLK_UI>,
+ <&pcc5 IMX8ULP_CLK_CSI>;
+ clock-names = "pclk", "wrap", "phy";
+ power-domains = <&scmi_devpd IMX8ULP_PD_MIPI_CSI>;
+ assigned-clocks = <&cgc2 IMX8ULP_CLK_PLL4_PFD1>,
+ <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV1>,
+ <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV2>,
+ <&pcc5 IMX8ULP_CLK_CSI>,
+ <&pcc5 IMX8ULP_CLK_CSI_CLK_UI>,
+ <&pcc5 IMX8ULP_CLK_CSI_CLK_ESC>;
+ assigned-clock-parents = <0>, <0>, <0>,
+ <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV1>,
+ <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV2>,
+ <&cgc2 IMX8ULP_CLK_PLL4_PFD1_DIV2>;
+ assigned-clock-rates = <316800000>,
+ <316800000>,
+ <316800000>,
+ <105600000>,
+ <79200000>,
+ <79200000>;
+ runtime_suspend;
+ status = "disabled";
+
+ ports {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ port@0 {
+ reg = <0>;
+ };
+
+ port@1 {
+ reg = <1>;
+
+ mipi_csi_0_out: endpoint {
+ remote-endpoint = <&isi_in_0>;
+ };
+ };
};
}; I know those modification are not likely to be enough as they are, but the imx-mipi-csis driver does not support i.MX8ULP so I am trying to baby step towards a working device tree. (I am using this binding documentation https://github.com/nxp-imx/linux-imx/blob/lf-6.6.y/Documentation/devicetree/bindings/media/nxp%2Cimx-mipi-csi2.yaml and looking at the associated driver source code https://github.com/nxp-imx/linux-imx/blob/lf-6.6.y/drivers/media/platform/nxp/imx-mipi-csis.c). The patch is attached to this message (0002-remove-camdev-modify-csi-and-isi-drivers-change-clocks-dtsi.patch) The issue Now, when I flash the imx-image-full to the board, everything boots but the mipi-csi node is not binding. When I check why, I have the following log: root@imx8ulp-9x9-lpddr4-evk:~# dmesg | grep 2daf
[ 2.175433] /soc@0/bus@2d800000/csi@2daf0000: Relaxing link with /i2c-rpbus-0/ov5640_mipi@3c/port/endpoint
[ 2.175476] /i2c-rpbus-0/ov5640_mipi@3c: Relaxing link with /soc@0/bus@2d800000/csi@2daf0000/ports/port@0/endpoint
[ 2.175523] i2c 0-003c: Fixed dependency cycle(s) with /soc@0/bus@2d800000/csi@2daf0000/ports/port@0/endpoint
[ 2.246985] /i2c-rpbus-0/ov5640_mipi@3c Dropping the fwnode link to /soc@0/bus@2d800000/csi@2daf0000/ports/port@0/endpoint
[ 2.247043] /soc@0/bus@2d800000/csi@2daf0000 Linked as a fwnode consumer to /i2c-rpbus-0/ov5640_mipi@3c
[ 2.247072] /soc@0/bus@2d800000/csi@2daf0000 Dropping the fwnode link to /i2c-rpbus-0/ov5640_mipi@3c/port/endpoint
[ 2.247125] device: 'i2c:0-003c--platform:2daf0000.csi': device_add
[ 2.247220] platform 2daf0000.csi: Linked as a sync state only consumer to 0-003c
[ 2.247233] /soc@0/bus@2d800000/csi@2daf0000 Dropping the fwnode link to /i2c-rpbus-0/ov5640_mipi@3c
[ 2.712236] platform 2daf0000.csi: Retrying from deferred list
[ 2.713521] bus: 'platform': __driver_probe_device: matched device 2daf0000.csi with driver imx-mipi-csis
[ 2.713542] bus: 'platform': really_probe: probing driver imx-mipi-csis with device 2daf0000.csi
[ 2.713573] imx-mipi-csis 2daf0000.csi: no pinctrl handle
[ 2.713793] imx-mipi-csis 2daf0000.csi: adding to PM domain MIPI_CSI
[ 2.713809] imx-mipi-csis 2daf0000.csi: genpd_add_device()
[ 2.714562] imx-mipi-csis 2daf0000.csi: error -ENOENT: Failed to get clk 'axi'
[ 2.721895] imx-mipi-csis 2daf0000.csi: removing from PM domain MIPI_CSI
[ 2.721910] imx-mipi-csis 2daf0000.csi: genpd_remove_device()
[ 2.722391] imx-mipi-csis: probe of 2daf0000.csi failed with error -2 The line [ 2.713573] imx-mipi-csis 2daf0000.csi: no pinctrl handle indicates that I should add some pinctrl management in the node. When I look in the IOMUXC chapter of the i.MX8ULP reference manual, an IOMUX spreadsheet that could help me with this is mentioned but I can't find it. Does somebody know where I can get this IOMUX spreadsheet ? Thanks Karim i.MX 8 Family | i.MX 8QuadMax (8QM) | 8QuadPlus Re: IOMUX Spreadsheet for i.MX8-ULP Hi, Thanks for your reply, I was finally able to directly get the spreadsheet attached to the reference manual. Regards, Karim Re: IOMUX Spreadsheet for i.MX8-ULP Hi,
Thank you for your interest in NXP Semiconductor products,
For the DTS side, you can refer to the EVK reference.
For the IOMUX matrix, please install Config Tools:
Download latest exe.
Execute installer and CFG Tools for first time as admin. Make sure your device complies with:
The following lists the minimum system requirements to install and run the software:
One of the following graphical operating systems:
– Microsoft Windows 10 (64-bit)
– Ubuntu 22.04 LTS
Note: Linux-hosted variants of tools are distributed on Linux as 64-bit binaries, which may not work on 32-bit systems.
– Supported desktop environments: GNOME
– Mac OS X (12.x)
4 GB RAM
Display with resolution 1024 x 768
Internet connection for dynamic download from processor database
Regards
View full article