Understanding Pinmux and DTB for TX2

All,

I wanted to take a moment to quickly (hopefully) summarize my understanding of the pinmux process for the Tegra TX2 and have people comment back.

The overall pinmux and padvoltage configuration is achieved through a cascading / overwriting process where changes on the first step can be overwritten by the last dtb load. For example:

Power On ----> 1. Boot Room (MB1) ----> 2. uBoot DTB ----> 3. kernel DTB

  1. From reading NVIDIA Tegra Linux Driver Package documentation the first pinmux configurations are achieved through the early stage boot loaders, specifically the MB1. The method for modifying pinmux at this stage is to modify an excel spreadsheet, use an excel macro to generate a DTSI file, then use python in Linux to convert the DTSI file to a pinmux.cfg file. This pinmux cfg file is copied to a particular directory which a flash tool can be used to flash it to the Tegra in recovery mode.

  2. Uboot itself has a DTB file that it can load and configure the pinmux as needed. I have not dug much into this option.

  3. Before Uboot goes away it will load a DTB file from the boot partition based on it’s findings in extlinux.conf under the /boot folder in rootfs. In extlinux.conf you can specify a line with FDT and the path to a .dtb file. Uboot loads this DTB and configures hardware peripherals including pinmux configurations.

In my past I have only messed with #3 for the TX1. I wanted to put this out there and have the experts pick it apart or add to.

From what I understand, the FDT option is now considered “deprecated” and you should really build the DTBs for u-boot and kernel and flash it using flash.sh.

Thank you snarky, This is the method I am trying now.

Thanks snarky. Please also refer to http://elinux.org/Jetson/TX2_DTB

@DaneLLL , I am unsure on how to change the pinmux configuration on the TX2. On an older version of Jetpack using the TX1, it was a matter of compiling a new dtb file using dtsi files generated by a spreadsheet and pointing to the dtb file with the flashtool.

Now, I use the spreadsheet to generate 3 dtsi files for the TX2 (Using Jetpack 28.2) and 1.05 spreadsheet.
I am unsure on what I need to do next to ensure the changes are there when the kernel is loaded.

  1. I can use the dtsTocfg Tool to generate the configs for the MB1 boot stage and use them to set the pinmux at the stage.

  2. Should I also compile a new dtb using these dtsi files? When doing this, I run into syntax errors which disappear when I replace TEGRA_GPIO with TEGRA_MAIN_GPIO and TEGRA_AON_GPIO are used in the gpio-default.dtsi file.