We recently added an extra component on our custom carrier board for TX2. This new component is an equivalent of the i2c expender tca9539. As a result, all our GPIO numbers got shifted in the system.
Is there a way we can reallocate those numbers or just ignore the new component for now ? We would like to keep the same GPIO numbers for our different board versions. We tried to modify the device tree but did not find the good location so far.
Previous GPIOs setup:
nvidia@tegra-ubuntu:~$ sudo cat /sys/kernel/debug/gpio
GPIOs 240-247, i2c/0-0020, mcp23008, can sleep:
gpio-240 P0.0 (sysfs ) out hi
gpio-243 P0.3 (sysfs ) out hi
GPIOs 248-255, platform/max77620-gpio, max77620-gpio, can sleep:
gpio-248 ( |external-connection:) in lo
gpio-253 ( |spmic_gpio_input_5 ) in lo
gpio-254 ( |spmic_gpio_input_6 ) in hi
GPIOs 256-319, platform/c2f0000.gpio, tegra-gpio-aon:
gpio-272 ( |temp_alert ) in hi
gpio-312 ( |Power ) in hi
gpio-313 ( |Volume Up ) in hi
gpio-314 ( |Volume Down ) in hi
gpio-315 ( |wifi-wake-ap ) in lo
gpio-316 ( |bt_host_wake ) in lo
GPIOs 320-511, platform/2200000.gpio, tegra-gpio:
gpio-332 ( |sysfs ) out lo
gpio-334 ( |sysfs ) out hi
gpio-381 ( |reset_gpio ) out lo
gpio-398 ( |vdd-fan ) out lo
gpio-412 ( |vdd-usb0-5v ) out lo
gpio-413 ( |vdd-usb1-5v ) out lo
gpio-420 ( |eqos_phy_reset ) out hi
gpio-421 ( |eqos_phy_intr ) in hi
gpio-424 ( |wlan_pwr ) out hi
gpio-426 ( |cam1-pwdn ) out lo
gpio-441 ( |hdmi2.0_hpd ) in lo
gpio-444 ( |wp ) in hi
gpio-445 ( |cd ) in hi
gpio-446 ( |en-vdd-sd ) out lo
gpio-456 ( |cam0-pwdn ) out lo
gpio-457 ( |cam1-rst ) out lo
gpio-461 ( |cam0-rst ) out lo
gpio-478 ( |sysfs ) out hi
gpio-479 ( |external-connection:) in lo
gpio-484 ( |bt_ext_wake ) out hi
gpio-486 ( |sysfs ) in hi
New GPIO setup:
nvidia@tegra-ubuntu:~$ cat /sys/kernel/debug/gpio
GPIOs 224-231, i2c/0-0020, mcp23008, can sleep:
GPIOs 232-239, platform/max77620-gpio, max77620-gpio, can sleep:
gpio-232 ( |external-connection:) in lo
gpio-237 ( |spmic_gpio_input_5 ) in hi
gpio-238 ( |spmic_gpio_input_6 ) in hi
GPIOs 240-255, i2c/0-0074, tca9539, can sleep:
gpio-240 ( |vdd-usb2-5v ) out hi
gpio-241 ( |en-vdd-ts-1v8 ) out hi
gpio-242 ( |en-vdd-ts-hv-3v3 ) out hi
gpio-243 ( |en-vdd-disp-3v3 ) out lo
gpio-247 ( |en-mdm-pwr-3v7 ) out lo
gpio-249 ( |en-vdd-disp-1v8 ) out lo
gpio-250 ( |dis-vdd-1v2 ) out hi
gpio-252 ( |vdd-hdmi ) out hi
gpio-253 ( |en-vdd-cam-hv-2v8 ) out lo
GPIOs 256-319, platform/c2f0000.gpio, tegra-gpio-aon:
gpio-272 ( |temp_alert ) in hi
gpio-312 ( |Power ) in hi
gpio-313 ( |Volume Up ) in hi
gpio-314 ( |Volume Down ) in hi
gpio-315 ( |wifi-wake-ap ) in lo
gpio-316 ( |bt_host_wake ) in lo
GPIOs 320-511, platform/2200000.gpio, tegra-gpio:
gpio-332 ( |sysfs ) out hi
gpio-334 ( |sysfs ) out hi
gpio-381 ( |reset_gpio ) out lo
gpio-398 ( |vdd-fan ) out lo
gpio-412 ( |vdd-usb0-5v ) out lo
gpio-413 ( |vdd-usb1-5v ) out lo
gpio-420 ( |eqos_phy_reset ) out hi
gpio-421 ( |eqos_phy_intr ) in hi
gpio-424 ( |wlan_pwr ) out hi
gpio-426 ( |cam1-pwdn ) out lo
gpio-441 ( |hdmi2.0_hpd ) in lo
gpio-444 ( |wp ) in hi
gpio-445 ( |cd ) in hi
gpio-446 ( |en-vdd-sd ) out lo
gpio-456 ( |cam0-pwdn ) out lo
gpio-457 ( |cam1-rst ) out lo
gpio-461 ( |cam0-rst ) out lo
gpio-478 ( |sysfs ) out hi
gpio-479 ( |external-connection:) in lo
gpio-484 ( |bt_ext_wake ) out hi
gpio-486 ( |sysfs ) in hi