SPI detection in IMX8QXP

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

SPI detection in IMX8QXP

297件の閲覧回数
Gokula_Kannan
Contributor I

Hi Team,


Board : imx8qxp
We made below dts changes for SPI. but could't get the node detection.

Cloud you please suggest solution for this issue.

&lpspi0 {
fsl,spi-num-chipselects = <1>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_lpspi0>;
status = "okay";
};

&lpspi2 {
fsl,spi-num-chipselects = <1>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_lpspi2>;
status = "okay";
};

&lpspi3 {
fsl,spi-num-chipselects = <1>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_lpspi3>;
status = "okay";
};


pinctrl_lpspi0: lpspi0grp {
fsl,pins = <
IMX8QXP_SPI0_CS0_ADMA_SPI0_CS0 0x06000021
IMX8QXP_SPI0_SCK_ADMA_SPI0_SCK 0x06000021
IMX8QXP_SPI0_SDI_ADMA_SPI0_SDI 0x00000021
IMX8QXP_SPI0_SDO_ADMA_SPI0_SDO 0x06000021
>;
};
pinctrl_lpspi2: lpspi2grp {
fsl,pins = <
IMX8QXP_SPI2_CS0_ADMA_SPI2_CS0 0x06000040
IMX8QXP_SPI2_SCK_ADMA_SPI2_SCK 0x06000021
IMX8QXP_SPI2_SDI_ADMA_SPI2_SDI 0x00000021
IMX8QXP_SPI2_SDO_ADMA_SPI2_SDO 0x06000021
>;
};
pinctrl_lpspi3: lpspi3grp {
fsl,pins = <
IMX8QXP_SPI3_CS0_ADMA_SPI3_CS0 0x00000060
IMX8QXP_SPI3_SCK_ADMA_SPI3_SCK 0x00000060
IMX8QXP_SPI3_SDI_ADMA_SPI3_SDI 0x00000060
IMX8QXP_SPI3_SDO_ADMA_SPI3_SDO 0x00000060
>;
};

 

0 件の賞賛
5 返答(返信)

272件の閲覧回数
Alejandro_Salas
NXP TechSupport
NXP TechSupport

Hello @Gokula_Kannan 

 

Pleas try following the SPI example in device tree kernel:

https://github.com/nxp-imx/linux-imx/blob/lf-6.6.y/arch/arm64/boot/dts/freescale/imx8x-mek.dtsi#L861

I hope this can helps to you.

 

Best regards.

Salas.

0 件の賞賛

251件の閲覧回数
ranjithkumar_kv
Contributor II

Hi Salas,

We've created the SPI nodes as per your suggestion but we're not able to see the spidev node and we're seeing errors in the dmesg logs. We are attaching the changes we've done in the dtsi file and dmesg error logs.

Regards,

Ranjith.

0 件の賞賛

237件の閲覧回数
Alejandro_Salas
NXP TechSupport
NXP TechSupport

Hello @ranjithkumar_kv 

 

Please look this post.

 

There is explained how to add new nodes of SPI in i.MX8QXP.

 

Best regards.

Salas.

0 件の賞賛

203件の閲覧回数
ranjithkumar_kv
Contributor II

Hi Salas,

After adding the slave to the spi nodes I'm able to see the spidev node in the /dev/ folder. But when I'm trying to transfer any data, it's showing like the image attached below. Attaching the spi node addition also below.

ranjithkumar_kv_0-1716806724566.png 

ranjithkumar_kv_2-1716806932621.png

 

Also in the dmesg logs we're getting the following error even though we followed the steps mentioned by you in the previous post.

ranjithkumar_kv_1-1716806784552.png

Please look into it and help us to resolve the issue.

 

Regards,
Ranjith Kumar.

0 件の賞賛

122件の閲覧回数
ranjithkumar_kv
Contributor II

Hi Salas,

 

Any update on our query?

 

Regards,

Ranjith Kumar

0 件の賞賛