Pin number identification for i2c

Hello Everyone ,
I need some help. I need to set SDA pin to low for my I2C device to start.
From the GPIO pinout link mention in the documentation here [VIM3 GPIO Pinout | Khadas Documentation]. I see that pin 23 is I2C_M3_SDA but How can i identify which pin number to use in my code for I2C_M3_SDA based on this out put on android 11 ? How do i map ?

vim3:/ $ cat /sys/kernel/debug/pinctrl/ff800000.sys-ctrl:pinctrl@14-pinctrl-meson/pins
registered pins: 15
pin 0 (GPIOAO_0) ff800000.sys-ctrl:pinctrl@14
pin 1 (GPIOAO_1) ff800000.sys-ctrl:pinctrl@14
pin 2 (GPIOAO_2) ff800000.sys-ctrl:pinctrl@14
pin 3 (GPIOAO_3) ff800000.sys-ctrl:pinctrl@14
pin 4 (GPIOAO_4) ff800000.sys-ctrl:pinctrl@14
pin 5 (GPIOAO_5) ff800000.sys-ctrl:pinctrl@14
pin 6 (GPIOAO_6) ff800000.sys-ctrl:pinctrl@14
pin 7 (GPIOAO_7) ff800000.sys-ctrl:pinctrl@14
pin 8 (GPIOAO_8) ff800000.sys-ctrl:pinctrl@14
pin 9 (GPIOAO_9) ff800000.sys-ctrl:pinctrl@14
pin 10 (GPIOAO_10) ff800000.sys-ctrl:pinctrl@14
pin 11 (GPIOAO_11) ff800000.sys-ctrl:pinctrl@14
pin 12 (GPIOE_0) ff800000.sys-ctrl:pinctrl@14
pin 13 (GPIOE_1) ff800000.sys-ctrl:pinctrl@14
pin 14 (GPIOE_2) ff800000.sys-ctrl:pinctrl@14

vim3:/ $ cat /sys/kernel/debug/pinctrl/ff634400.bus:pinctrl@40-pinctrl-meson/pins
registered pins: 85
pin 0 (GPIOZ_0) ff634400.bus:pinctrl@40
pin 1 (GPIOZ_1) ff634400.bus:pinctrl@40
pin 2 (GPIOZ_2) ff634400.bus:pinctrl@40
pin 3 (GPIOZ_3) ff634400.bus:pinctrl@40
pin 4 (GPIOZ_4) ff634400.bus:pinctrl@40
pin 5 (GPIOZ_5) ff634400.bus:pinctrl@40
pin 6 (GPIOZ_6) ff634400.bus:pinctrl@40
pin 7 (GPIOZ_7) ff634400.bus:pinctrl@40
pin 8 (GPIOZ_8) ff634400.bus:pinctrl@40
pin 9 (GPIOZ_9) ff634400.bus:pinctrl@40
pin 10 (GPIOZ_10) ff634400.bus:pinctrl@40
pin 11 (GPIOZ_11) ff634400.bus:pinctrl@40
pin 12 (GPIOZ_12) ff634400.bus:pinctrl@40
pin 13 (GPIOZ_13) ff634400.bus:pinctrl@40
pin 14 (GPIOZ_14) ff634400.bus:pinctrl@40
pin 15 (GPIOZ_15) ff634400.bus:pinctrl@40
pin 16 (GPIOH_0) ff634400.bus:pinctrl@40
pin 17 (GPIOH_1) ff634400.bus:pinctrl@40
pin 18 (GPIOH_2) ff634400.bus:pinctrl@40
pin 19 (GPIOH_3) ff634400.bus:pinctrl@40
pin 20 (GPIOH_4) ff634400.bus:pinctrl@40
pin 21 (GPIOH_5) ff634400.bus:pinctrl@40
pin 22 (GPIOH_6) ff634400.bus:pinctrl@40
pin 23 (GPIOH_7) ff634400.bus:pinctrl@40
pin 24 (GPIOH_8) ff634400.bus:pinctrl@40
pin 25 (BOOT_0) ff634400.bus:pinctrl@40
pin 26 (BOOT_1) ff634400.bus:pinctrl@40
pin 27 (BOOT_2) ff634400.bus:pinctrl@40
pin 28 (BOOT_3) ff634400.bus:pinctrl@40
pin 29 (BOOT_4) ff634400.bus:pinctrl@40
pin 30 (BOOT_5) ff634400.bus:pinctrl@40
pin 31 (BOOT_6) ff634400.bus:pinctrl@40
pin 32 (BOOT_7) ff634400.bus:pinctrl@40
pin 33 (BOOT_8) ff634400.bus:pinctrl@40
pin 34 (BOOT_9) ff634400.bus:pinctrl@40
pin 35 (BOOT_10) ff634400.bus:pinctrl@40
pin 36 (BOOT_11) ff634400.bus:pinctrl@40
pin 37 (BOOT_12) ff634400.bus:pinctrl@40
pin 38 (BOOT_13) ff634400.bus:pinctrl@40
pin 39 (BOOT_14) ff634400.bus:pinctrl@40
pin 40 (BOOT_15) ff634400.bus:pinctrl@40
pin 41 (GPIOC_0) ff634400.bus:pinctrl@40
pin 42 (GPIOC_1) ff634400.bus:pinctrl@40
pin 43 (GPIOC_2) ff634400.bus:pinctrl@40
pin 44 (GPIOC_3) ff634400.bus:pinctrl@40
pin 45 (GPIOC_4) ff634400.bus:pinctrl@40
pin 46 (GPIOC_5) ff634400.bus:pinctrl@40
pin 47 (GPIOC_6) ff634400.bus:pinctrl@40
pin 48 (GPIOC_7) ff634400.bus:pinctrl@40
pin 49 (GPIOA_0) ff634400.bus:pinctrl@40
pin 50 (GPIOA_1) ff634400.bus:pinctrl@40
pin 51 (GPIOA_2) ff634400.bus:pinctrl@40
pin 52 (GPIOA_3) ff634400.bus:pinctrl@40
pin 53 (GPIOA_4) ff634400.bus:pinctrl@40
pin 54 (GPIOA_5) ff634400.bus:pinctrl@40
pin 55 (GPIOA_6) ff634400.bus:pinctrl@40
pin 56 (GPIOA_7) ff634400.bus:pinctrl@40
pin 57 (GPIOA_8) ff634400.bus:pinctrl@40
pin 58 (GPIOA_9) ff634400.bus:pinctrl@40
pin 59 (GPIOA_10) ff634400.bus:pinctrl@40
pin 60 (GPIOA_11) ff634400.bus:pinctrl@40
pin 61 (GPIOA_12) ff634400.bus:pinctrl@40
pin 62 (GPIOA_13) ff634400.bus:pinctrl@40
pin 63 (GPIOA_14) ff634400.bus:pinctrl@40
pin 64 (GPIOA_15) ff634400.bus:pinctrl@40
pin 65 (GPIOX_0) ff634400.bus:pinctrl@40
pin 66 (GPIOX_1) ff634400.bus:pinctrl@40
pin 67 (GPIOX_2) ff634400.bus:pinctrl@40
pin 68 (GPIOX_3) ff634400.bus:pinctrl@40
pin 69 (GPIOX_4) ff634400.bus:pinctrl@40
pin 70 (GPIOX_5) ff634400.bus:pinctrl@40
pin 71 (GPIOX_6) ff634400.bus:pinctrl@40
pin 72 (GPIOX_7) ff634400.bus:pinctrl@40
pin 73 (GPIOX_8) ff634400.bus:pinctrl@40
pin 74 (GPIOX_9) ff634400.bus:pinctrl@40
pin 75 (GPIOX_10) ff634400.bus:pinctrl@40
pin 76 (GPIOX_11) ff634400.bus:pinctrl@40
pin 77 (GPIOX_12) ff634400.bus:pinctrl@40
pin 78 (GPIOX_13) ff634400.bus:pinctrl@40
pin 79 (GPIOX_14) ff634400.bus:pinctrl@40
pin 80 (GPIOX_15) ff634400.bus:pinctrl@40
pin 81 (GPIOX_16) ff634400.bus:pinctrl@40
pin 82 (GPIOX_17) ff634400.bus:pinctrl@40
pin 83 (GPIOX_18) ff634400.bus:pinctrl@40
pin 84 (GPIOX_19) ff634400.bus:pinctrl@40

1 Like

you can check in common/drivers/amlogic/pinctrl/pinctrl-meson-g12a.c

2 Likes

@jasonl Thank you so much.