I want to adapt Linux for Tegra 28.1 for our custom carrier board having the TX2 module. I’ve found Tegra_Linux_Driver_Package_TX2_Adaptation_Guide.pdf
I’ve successfully modified the NVidia provided XLSM, generated the device tree sources. Now what? Where shall I copy them? Which files should I overwrite?
Which files should I modify in the flasher?
I’ve actually tried to adapt the jetson-tx2.conf and the p2771-0000.conf.common files, basically copying the originals (and the referenced configuration and device tree files) to the same file name, except replacing “quill” with our custom board’s name. So I’ve copied the files and done a clever search and replace in the files.
The interesting thing is that with the same - just renamed (and replaced in the source) - configuration files the flashing fails:
flash.sh fails with “Cannot open USB”.
On the Tegra serial console I see:
C> I2C command failed
C> block index = (1) and rail_id = (4)
C> Addr: Reg = [0x72:0x07]: 336166925
C> Failed to bringup SRAM rails
C> ERROR: Highest Layer Module = 0x28, Lowest Layer Module = 0x26, Aux Info = 0x0, Reason = 0xd
The interesting thing is that with the original configuration (jetson-tx2.conf) the flashing is successful.
please converts those DTS files into .cfg format for flashing,
check [U-Boot Customization]-> [TX2 Configuring Pinmux GPIO and PAD] for more details.
thanks
It has been done already. (Altough the flasher modifies the name of the boot config files you set in p2771-0000.conf.common based on an EEPROM value - so a different file is used instead what you set which is confusing…)
But shouldn’t these generated device tree files be included in the main dts? If not, why does the pinmux XLSM generate DTSIs instead the boot config files?
On a jetson TX2 using Jetpack 28.2 ) and the PinMux spreadsheet (1.05).
Using the default values, I generate the 3 dtsi files. I then use pinmux-dts2cfg.py to generate
tegra186-mb1-bct-pinmux-quill-p3310-1000-c03.cfg and
tegra186-mb1-bct-pad-quill-p3310-1000-c03.cfg.
I copy these to the BCT folder within the bootloader and can flash them over.
Using the original tegra186-quill-p3310-1000-c03-00-base.dtb file, the board boots fine.
If I recompile the DTB file by #including the 3 dtsi files in the tegra186-quill-p3310-1000-c03-00-base.dts file , then I get the following errors and CPU lockup.
may i have confirmation that following the steps in the document works,
but you met an issue if “recompile the DTB file by including these generated dtsi files”
thanks
That is correct. Just using the .cfg files generated for MB1, boots correctly. However if a dtb compiled using the generated dtsi files is also flashed over, the errors occur.
What I want to achieve: I want to use some pins of the TX2 as GPIOs - so I turned off the functionality of them. I also want to turn on SPI2 of the TX2 SOM.
What we see:
without including the generated DTSI files in the DTS the kernel boots, however when we do some SPI transmission from the TX2 nothing changes on the MOSI/SCLK/CS signals
So the question again: Should we include the generated DTSI files in the kernel DTS or not. If yes, where?
Without the pinmux DTSI included in the device tree, the pins does not seem to be configured as SPI2 (we do not see any change on the signals during the transmission).
With the pinmux DTSI the kernel crashes.
please check the difference between the default DTB file and the customize one.
you could use below commands to disassembler the dtb file into txt file for comparison.
thanks
JerryChang, please, we know what is the difference between the two device tree files, since we made that difference in the first place: in the working one the 3 generated dtsi files are not included, in the crashing one they are.
(Also, if you want to compare device tree files you should really add the switch -s to the dtc command which sorts the nodes and properties - it makes the outputs diffable (see man dtc).)