Hi all,
I have a question about device tree customization for a custom carrier board.
Configuration:
- Module: Colibri IMX7D 1GB
- Base image: torizon-core-docker-colibri-imx7-emmc-Tezi_5.6.0+build.13
This is what I have done (using the aster carrier board board as a base since our board is not too far off that one).
-
copied “imx7-colibri-emmc-aster.dts” and called it “imx7-colibri-emmc-interferometer.dts”
-
copied “imx7-colibri-aster.dtsi” and called it “imx7-colibri-interferometer.dtsi”
The torizoncore-builder will take the new .dts file as a start for building my image -
In these two “interferometer” files, I disabled UART B (uart2), GPIO bank 2 and ECSPI3 since they will be used by the M4 core.
The UARTs and SPI were simply done by setting their status to “disabled” in the .dts file. “disabling” GPIO bank 2 is done by removing “&pinctrl_gpio2” in the “&iomuxc” definition in the .dtsi file.
=> first question, is this enough to let Linux forget about these three “devices” ?
On our carrier board, I also need to reconfigure the handshake lines of UART A (uart1) into basic GPIO lines.
In order to de-associate the handshake lines from uart1, I modified imx7-colibri.dtsi (27.0 KB) which defines &uart1. The line that defines pinctrl-0 is modified and the line “UART-has-rtscts;” is removed as well. (you can easily find my modifications by searching for //@@)
Building a new image works but when I try to control GPIO6.IO[19] (SODIMM pin 25, formerly “uart1.CTS_B”) via the console, I do not see any change on the pin (Linux pin number (6 - 1) * 32 + 19 = 179) :
echo 179 > /sys/class/gpio/export
echo “out” > /sys/class/gpio/gpio179/direction
echo 0 > /sys/class/gpio/gpio179/value
echo 1 > /sys/class/gpio/gpio179/value
Same with GPIO6.IO[20] (SODIMM pin 27, formerly “uart1.RTS_B”)…
My questions are:
=> Is modifying "imx7-colibri.dtsi"the right way to go or shall I redefine the &uart1 structure in my top “interferometer.dtsi” file ?
=> What else must I modify (and where) in order to be able to use the handshake pins as GPIO ?
Your help is very much appreciated, as ever !
Jeroen