Hi,
I have the following board layout on my custom board:
The pinmux tool comes up with the following config for pin K18 and L18:
myuart2_pins_default: myuart2_pins_default { pinctrl-single,pins = < AM33XX_IOPAD(0x92c, PIN_INPUT | MUX_MODE1) /* (K18) gmii1_txclk.uart2_rxd */ AM33XX_IOPAD(0x930, PIN_OUTPUT | MUX_MODE1) /* (L18) gmii1_rxclk.uart2_txd */ >; };
When Use this for my Uart config:
&uart2 { pinctrl-names = "default"; pinctrl-0 = <&myuart2_pins_default>; status = "okay"; };
I see the following error during boot:
[ 0.632451] OMAP GPIO hardware version 0.1 [ 0.736053] pinctrl-single 44e10800.pinmux: 142 pins, size 568 [ 1.085993] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled [ 1.094580] omap_uart 44e09000.serial: no wakeirq for uart0 [ 1.095479] 44e09000.serial: ttyO0 at MMIO 0x44e09000 (irq = 29, base_baud = 3000000) is a OMAP UART0 [ 1.645500] printk: console [ttyO0] enabled [ 1.651710] omap_uart 48022000.serial: no wakeirq for uart1 [ 1.658046] 48022000.serial: ttyO1 at MMIO 0x48022000 (irq = 36, base_baud = 3000000) is a OMAP UART1 [ 1.670133] pinctrl-single 44e10800.pinmux: pin PIN75 already requested by 48022000.serial; cannot claim for 48024000.serial [ 1.681965] pinctrl-single 44e10800.pinmux: pin-75 (48024000.serial) status -22 [ 1.689642] pinctrl-single 44e10800.pinmux: could not request pin 75 (PIN75) from group myuart2_pins_default on device pinctrl-single [ 1.702277] omap_uart 48024000.serial: Error applying setting, reverse things back [ 1.710343] omap_uart: probe of 48024000.serial failed with error -22
Running on kernel:
Linux cdx 5.4.51casenio #1 Mon Jul 13 14:08:14 CEST 2020 armv7l GNU/Linux
When I change the syntax from the pinmux tool to this:
myuart2_pins_default: myuart2_pins_default {
pinctrl-single,pins = <
0x92c (PIN_INPUT | MUX_MODE1) /* (K18) gmii1_txclk.uart2_rxd */
0x930 (PIN_OUTPUT | MUX_MODE1) /* (L18) gmii1_rxclk.uart2_txd */
>;
};
I get the following message:
[ 0.632609] OMAP GPIO hardware version 0.1 [ 0.736345] pinctrl-single 44e10800.pinmux: 142 pins, size 568 [ 1.086233] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled [ 1.094664] omap_uart 44e09000.serial: no wakeirq for uart0 [ 1.095572] 44e09000.serial: ttyO0 at MMIO 0x44e09000 (irq = 29, base_baud = 3000000) is a OMAP UART0 [ 1.645602] printk: console [ttyO0] enabled [ 1.651822] omap_uart 48022000.serial: no wakeirq for uart1 [ 1.658148] 48022000.serial: ttyO1 at MMIO 0x48022000 (irq = 36, base_baud = 3000000) is a OMAP UART1 [ 1.670168] pinctrl-single 44e10800.pinmux: mux offset out of range: 0x92c (0x238) [ 1.678094] pinctrl-single 44e10800.pinmux: could not add functions for myuart2_pins_default 2348x [ 1.687832] omap_uart 48024000.serial: no wakeirq for uart2 [ 1.694179] 48024000.serial: ttyO2 at MMIO 0x48024000 (irq = 37, base_baud = 3000000) is a OMAP UART2
There will be a /dev/ttyO2 present but no data is transferred or received.
What is the correct device tree config for uart2 using pins k18 and L18 on a AM3352 processor?
Why does "mux offset out of range" pop up?
UART0,1,3,4,5 work flawlessly