i want find out nx gpio03 is which chip, i want control /sys/class/gpio
however，i found the gpio is GPIO3_PCC.01 , what is CC mean?
please refer to L4T sources package for public release sources.
you may check the header file for the details of Tegra’s GPIO IDs.
/* GPIOs implemented by main GPIO controller */ ... #define TEGRA_MAIN_GPIO_PORT_CC 22
you should also check your kernel init messages for the allocation ranges for these GPIO chips, such as MAIN, AON,… etc
nvidia@nvidia-desktop:~$ dmesg | grep "registered GPIOs" [ 0.778328] gpiochip_setup_dev: registered GPIOs 288 to 511 on device: gpiochip0 (tegra-gpio) [ 0.786632] gpiochip_setup_dev: registered GPIOs 248 to 287 on device: gpiochip1 (tegra-gpio-aon) [ 0.934262] gpiochip_setup_dev: registered GPIOs 240 to 247 on device: gpiochip2 (max77620-gpio)
according to the formula below
#define TEGRA_MAIN_GPIO(port, offset) ((TEGRA_MAIN_GPIO_PORT_##port * 8) + offset)
that GPIO3_PCC.01 means port CC with offset 1, here’s the GPIO number calculation results.
288 + ((22* 8) + 1 ) = 465
It is working ,thankyou