GPIO numbering - mapping to sysfs GPIO for JETSON XAVIER

Hi,

I am little bit confused by the tool “jetson_agx_devkit.xlsm”. Where did it come from? Which release are you using? I just checked all dtsi files in rel-32 kernel and notice that only platforms prior to TX2 are using this file.

As for the gpio range, per checked tegra194-gpio.h

#define TEGRA194_AON_GPIO_PORT_BB 1
→ 1*8+1 and this one is AON_GPIO, w.r.t below gpio ranges

GPIO ranges handled:
0: tegra-gpio GPIOS [288 - 495] PINS [0 - 207]
208: tegra-gpio GPIOS [496 - 511] PINS [248 - 263]
0: tegra-gpio-aon GPIOS [248 - 287] PINS [208 - 247]

The gpio number should be 248 + 1*8+1 = gpio 257 and the pin is mapping to 208+9 = 217.

Please also note that the macro “TEGRA_GPIO” is also used by < TX2 platforms too.