Can you describe how to find out the pin number we are using through this dts?

The dts configuration for /dev/ttyS0 is show below, but I don’t see any pin number can be calculated from this configuration, although I know the pin number is 236 for tx and 238 for rx. Can you describe how to find out the pin number we are using through this dts?
uarta: serial@3100000 {
compatible = “nvidia,tegra186-hsuart”;
iommus = <&smmu TEGRA_SID_GPCDMA_0>;
reg = <0x0 0x03100000 0x0 0x40>;
reg-shift = <2>;
interrupts = <0 TEGRA186_IRQ_UARTA 0x04>;
nvidia,memory-clients = <14>;
dmas = <&gpcdma 8>, <&gpcdma 8>;
dma-names = “rx”, “tx”;
clocks = <&tegra_car TEGRA186_CLK_UARTA>,
<&tegra_car TEGRA186_CLK_PLLP_OUT0>;
clock-names = “serial”, “parent”;
resets = <&tegra_car TEGRA186_RESET_UARTA>;
reset-names = “serial”;
status = “disabled”;
nvidia,tolerance-low-range = <0>;
nvidia,tolerance-high-range = <4>;
nvidia,adjust-baud-rates = <115200 115200 100>;
};

serial@3100000 {
compatible = “nvidia,tegra20-uart”, “nvidia,tegra186-hsuart”;
console-port;
sqa-automation-port;
/delete-property/ resets;
/delete-property/ reset-names;
status = “okay”;
};

Hi zh09,

Are you using the devkit or custom board for TX2?
What’s your Jetpack version in use?

Please share the result of the following command on your board.

$ sudo cat /sys/kernel/debug/gpio

Hi
Yes, we are using the custom board according devkit for TX2_NX.
But still I don’t know how.
R32.5.1
gpiochip2: GPIOs 248-255, parent: platform/max77620-gpio, max77620-gpio, can sleep:
gpio-253 ( |spmic_gpio_input ) in lo
gpio-254 ( |spmic_gpio_input ) in lo

gpiochip1: GPIOs 256-319, parent: platform/c2f0000.gpio, tegra-gpio-aon:
gpio-302 ( |eqos_phy_reset ) out hi
gpio-312 ( |power-key ) in hi

gpiochip0: GPIOs 320-511, parent: platform/2200000.gpio, tegra-gpio:
gpio-408 ( |w-disable1 ) out lo
gpio-410 ( |w-disable2 ) out lo
gpio-412 ( |external-connection:) in lo
gpio-441 ( |hdmi2.0_hpd ) in lo
gpio-456 ( |camera-control-outpu) out lo
gpio-461 ( |camera-control-outpu) out lo

Since you are using UART0_TXD/UART0_RXD for UART usage.
What do you mean about pin number here and what’s your use case?

Are you using the following UART interface (uartb) on TX2-NX?

Sorry, I took it wrong. And I updated the post. I took /dev/ttyS0, the console serial port for example.

The dts configuration for /dev/ttyS0 is show below, but I don’t see any pin number can be calculated from this configuration, although I know the pin number is 236 for tx and 238 for rx. Can you describe how to find out the pin number we are using through this dts?

uarta: serial@3100000 {
compatible = “nvidia,tegra186-hsuart”;
iommus = <&smmu TEGRA_SID_GPCDMA_0>;
reg = <0x0 0x03100000 0x0 0x40>;
reg-shift = <2>;
interrupts = <0 TEGRA186_IRQ_UARTA 0x04>;
nvidia,memory-clients = <14>;
dmas = <&gpcdma 8>, <&gpcdma 8>;
dma-names = “rx”, “tx”;
clocks = <&tegra_car TEGRA186_CLK_UARTA>,
<&tegra_car TEGRA186_CLK_PLLP_OUT0>;
clock-names = “serial”, “parent”;
resets = <&tegra_car TEGRA186_RESET_UARTA>;
reset-names = “serial”;
status = “disabled”;
nvidia,tolerance-low-range = <0>;
nvidia,tolerance-high-range = <4>;
nvidia,adjust-baud-rates = <115200 115200 100>;
};

serial@3100000 {
compatible = “nvidia,tegra20-uart”, “nvidia,tegra186-hsuart”;
console-port;
sqa-automation-port;
/delete-property/ resets;
/delete-property/ reset-names;
status = “okay”;
};

May I know what do you mean about “pin number” here? (i.e. from the perspective of SW or HW?)

Please also share the full dmesg for further check.

How did you get this?


like this

Do you mean 99 and 101 at left side of your pinmux spreadsheet?
If so, they are the pin number used in the schematic.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.