How to configure SPI1 in slave mode in JetPack6.x

Hi NV_Team,

We need to use SPI1 in slave mode in JetPack6.x.

when we add ‘compatible = “nvidia,tegra186-spi-slave”; ‘ in 5.x and compile is okay, but in 6.x compile error.


spi@3210000{ /* SPI1 in 40 pin conn */
	status = "okay";
	compatible = “nvidia,tegra186-spi-slave”;
	spi@0 { /* chip select 0 */
		compatible = "tegra-spidev";
		reg = <0x0>;
		spi-max-frequency = <50000000>;
	};
	spi@1 { /* chips select 1 */
		status = "disabled";
		compatible = "tegra-spidev";
		reg = <0x1>;
		spi-max-frequency = <50000000>;
	};
};

*** Please note that this reply is generated by LLM automatically ***

The question seems unrelated to the provided context, which is about flashing the rootfs storage on Jetson devices. However, I’ll try to provide a comprehensive answer based on the question.

The issue you’re facing is related to using SPI1 in slave mode on Jetson AGX Orin with JetPack 6.x. You’ve successfully added the compatible string “nvidiategra186spislave” in JetPack 5.x and compiled without errors. However, when you try to do the same in JetPack 6.x, you’re encountering a compile error.

To resolve this issue, you’ll need to investigate the changes between JetPack 5.x and 6.x that might be causing the compile error. Here are some potential steps to help you troubleshoot:

  1. Check the kernel configuration: Compare the kernel configuration files (e.g., .config) between JetPack 5.x and 6.x to see if there are any differences in the SPI-related configurations.
  2. Verify the device tree: Ensure that the device tree files (e.g., tegra186.dtsi) are correctly configured for SPI1 in slave mode. You might need to update the device tree files to match the changes in JetPack 6.x.
  3. Review the kernel patches: Check if there are any kernel patches applied in JetPack 6.x that might be causing the compile error. You can try to revert or modify these patches to resolve the issue.
  4. Consult the NVIDIA documentation: Refer to the official NVIDIA documentation for JetPack 6.x and Jetson AGX Orin to see if there are any specific requirements or changes for using SPI1 in slave mode.
  5. Seek community support: Reach out to the NVIDIA developer community or forums to see if others have encountered similar issues and found solutions.

In summary, the provided context does not directly relate to the question, but by following these troubleshooting steps, you should be able to identify and resolve the issue with using SPI1 in slave mode on Jetson AGX Orin with JetPack 6.x.

As for the context, it seems to be a repetition of the same information, which is about flashing the rootfs storage on Jetson devices using the l4t_initrd_flash.sh script. The script is used to flash the rootfs storage on Jetson devices, and the context provides examples for different Jetson devices and storage types (eMMC and NVMe).

*** Please give the thumbs up if you get answers you like. Or provide feedback to help us improve the answer. ***

Hi,

It doesn’t solve my problem.

JetPack6.x can not support SPI slave mode ?

Hi Luna2020,

Are you using the devkit or custom board for AGX Orin?
What’s the exact Jetpack version in use?

What compile error do you get?

Could you share the log and the result of the following command on your board for further check?

$ sudo lsmod|grep spi