TX2NX SPI transfer fails

1.How can I confirm that Pinmux has switched to SPI function
IN Jetson_TX2_NX_pinmux_config_1.05,we use the group shown in the following figure.


2.in hardware/nvidia/soc/t18x/kernel-dts/tegra186-soc/tegra186-soc-spi.dtsi
aliases {
spi0 = &spi0;
spi1 = &spi1;
spi2 = &spi2;
spi3 = &spi3;
spi4 = &aon_spi;
spi6 = &qspi6;
};

which SPI ( spi0/spi1 ) matches DTS according to the SPI shown in the above figure
3. There is no spi node under tx2nx /dev, but after loading kernel kernel 4.9 drivers spi spidev.ko, the following nodes will appear:
root@mix:/mnt/nfs# ls -l /dev/spidev
spidev0.0 spidev0.1 spidev1.0 spidev1.1
Is there a problem with dynamically loading KO? Do I need to modify some driver configurations? Can the above /dev/spi nodes be used directly? However, when I tested directly operating the above nodes, the oscilloscope did not detect any waveforms

Hi TrevinN,

Are you using the devkit or custom board for TX2 NX?
What’s your Jetpack version in use?

Please check the column of Customer Usage as following.


It seems default used as GPIO before modification for SPI usage.

You could refer to tegra186-soc-spi.dtsi and get the following result:

spi0 = &spi0; //spi0: spi@3210000 {
spi1 = &spi1; //spi1: spi@c260000 {
spi2 = &spi2; //spi2: spi@3230000 {
spi3 = &spi3; //spi3: spi@3240000 {
spi4 = &aon_spi; //aon_spi: aon_spi@c260000 {
spi6 = &qspi6; //qspi6: spi@3270000 {

In your case (module pin 91, 93, 89, 95), it should mapping to spi0.
You could also refer to the following figure from design guide.

It is expected due to SPI driver built as loadable kernel module and should be loaded manually.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.