arm64: dts: ti: Refactor and alignment of VAR-SOM-AM62P
Subsystems (2)
cover arm64: dts: ti: Refactor and alignment of VAR-SOM-AM62P
This patch series introduces updates to the VAR-SOM-AM62P device tree:
- Patch 1 refactors the IPC configuration to align with upstream changes by including the new common k3-am62p-ti-ipc-firmware.dtsi.
- Patch 2 adds support for the WM8904 audio codec, enabling audio playback and capture.
- Patch 3 adds support for the ADS7846 touchscreen controller available on the SOM.
These changes have been tested on the VAR-SOM-AM62P platform with Symphony Carrier Board.
Stefano Radaelli (3):
arm64: dts: ti: var-som-am62p: Refactor IPC configuration into common
dtsi
arm64: dts: ti: var-som-am62p: Add support for WM8904 audio codec
arm64: dts: ti: var-som-am62p: Add support for ADS7846 touchscreen
arch/arm64/boot/dts/ti/k3-am62p5-var-som.dtsi | 148 ++++++++++++------ 1 file changed, 98 insertions(+), 50 deletions(-)
base-commit: 58809f614e0e3f4e12b489bddf680bfeb31c0a20
Signature · 1 line
2.47.3
PATCH 1/3 arm64: dts: ti: var-som-am62p: Refactor IPC configuration into common dtsi
Update the VAR-SOM-AM62P dtsi to align with the refactor introduced by k3-am62p-ti-ipc-firmware.dtsi common file, allowing to remove the IPC nodes from the board file including the new common dtsi.
No functional changes intended.
--- arch/arm64/boot/dts/ti/k3-am62p5-var-som.dtsi | 52 +------------------ 1 file changed, 2 insertions(+), 50 deletions(-)
arch/arm64/boot/dts/ti/k3-am62p5-var-som.dtsi +2 -50
@@ -63,18 +63,6 @@ rtos_ipc_memory_region: rtos-ipc-memory@9b500000 { no-map; }; - mcu_r5fss0_core0_dma_memory_region: mcu-r5fss-dma-memory-region@9b800000 { - compatible = "shared-dma-pool"; - reg = <0x00 0x9b800000 0x00 0x00100000>; - no-map; - }; - - mcu_r5fss0_core0_memory_region: mcu-r5fss-memory-region@9b900000 { - compatible = "shared-dma-pool"; - reg = <0x00 0x9b900000 0x00 0x00f00000>; - no-map; - }; - wkup_r5fss0_core0_dma_memory_region: r5f-dma-memory@9c800000 { compatible = "shared-dma-pool"; reg = <0x00 0x9c800000 0x00 0x00100000>;
@@ -320,44 +308,6 @@ &usbss1 { ti,vbus-divider; }; -&mailbox0_cluster0 { - status = "okay"; - - mbox_r5_0: mbox-r5-0 { - ti,mbox-rx = <0 0 0>; - ti,mbox-tx = <1 0 0>; - }; -}; - -&mailbox0_cluster1 { - status = "okay"; - - mbox_mcu_r5_0: mbox-mcu-r5-0 { - ti,mbox-rx = <0 0 0>; - ti,mbox-tx = <1 0 0>; - }; -}; - -&mcu_r5fss0 { - status = "okay"; -}; - -&mcu_r5fss0_core0 { - mboxes = <&mailbox0_cluster1 &mbox_mcu_r5_0>; - memory-region = <&mcu_r5fss0_core0_dma_memory_region>, - <&mcu_r5fss0_core0_memory_region>; -}; - -&wkup_r5fss0 { - status = "okay"; -}; - -&wkup_r5fss0_core0 { - mboxes = <&mailbox0_cluster0 &mbox_r5_0>; - memory-region = <&wkup_r5fss0_core0_dma_memory_region>, - <&wkup_r5fss0_core0_memory_region>; -}; - /* mcu_gpio0 and mcu_gpio_intr are reserved for mcu firmware usage */ &mcu_gpio0 { status = "reserved";
@@ -385,3 +335,5 @@ &main_uart1 { /* Main UART1 is used by TIFS firmware */ status = "reserved"; }; + +#include "k3-am62p-ti-ipc-firmware.dtsi"
Signature · 1 line
2.47.3
PATCH 2/3 arm64: dts: ti: var-som-am62p: Add support for WM8904 audio codec
In reply to Stefano RadaelliThe VAR-SOM-AM62P can integrate the WM8904, a high-performance ultra-low-power stereo codec optimized for portable audio applications.
This patch adds the WM8904 device to the appropriate I2C bus, enables the McASP1 peripheral, and introduces the sound node to expose the sound card to the system.
--- arch/arm64/boot/dts/ti/k3-am62p5-var-som.dtsi | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+)
arch/arm64/boot/dts/ti/k3-am62p5-var-som.dtsi +72 -0
@@ -112,6 +112,38 @@ reg_3v3_phy: regulator-3v3-phy { enable-active-high; regulator-always-on; }; + + sound { + compatible = "simple-audio-card"; + simple-audio-card,bitclock-master = <&codec_dai>; + simple-audio-card,format = "dsp_b"; + simple-audio-card,frame-master = <&codec_dai>; + simple-audio-card,name = "wm8904-audio"; + simple-audio-card,mclk-fs = <256>; + simple-audio-card,routing = + "Headphone Jack", "HPOUTL", + "Headphone Jack", "HPOUTR", + "IN2L", "Line In Jack", + "IN2R", "Line In Jack", + "IN1L", "Microphone Jack", + "IN1R", "Microphone Jack"; + simple-audio-card,widgets = + "Microphone", "Microphone Jack", + "Headphone", "Headphone Jack", + "Line", "Line In Jack"; + + codec_dai: simple-audio-card,codec { + sound-dai = <&wm8904>; + }; + + simple-audio-card,cpu { + sound-dai = <&mcasp1>; + }; + }; +}; + +&audio_refclk1 { + assigned-clock-rates = <100000000>; }; &cpsw3g {
@@ -149,6 +181,19 @@ &main_i2c2 { pinctrl-0 = <&pinctrl_i2c2>; clock-frequency = <400000>; status = "okay"; + + wm8904: audio-codec@1a { + compatible = "wlf,wm8904"; + reg = <0x1a>; + #sound-dai-cells = <0>; + clocks = <&audio_refclk1>; + clock-names = "mclk"; + AVDD-supply = <®_1v8>; + CPVDD-supply = <®_1v8>; + DBVDD-supply = <®_3v3>; + DCVDD-supply = <®_1v8>; + MICVDD-supply = <®_1v8>; + }; }; &main_i2c3 {
@@ -179,6 +224,16 @@ AM62PX_IOPAD(0x01d4, PIN_INPUT_PULLUP, 2) /* (C22) UART0_RTSn.I2C3_SDA */ >; }; + pinctrl_mcasp1: main-mcasp1-default-pins { + pinctrl-single,pins = < + AM62PX_IOPAD(0x0090, PIN_INPUT, 2) /* (U24) GPMC0_BE0n_CLE.MCASP1_ACLKX */ + AM62PX_IOPAD(0x0098, PIN_INPUT, 2) /* (AA24) GPMC0_WAIT0.MCASP1_AFSX */ + AM62PX_IOPAD(0x008c, PIN_OUTPUT, 2) /* (T25) GPMC0_WEn.MCASP1_AXR0 */ + AM62PX_IOPAD(0x0084, PIN_INPUT, 2) /* (R25) GPMC0_ADVn_ALE.MCASP1_AXR2 */ + AM62PX_IOPAD(0x00a0, PIN_OUTPUT, 1) /* (P24) GPMC0_WPn.AUDIO_EXT_REFCLK1 */ + >; + }; + pinctrl_mdio1: main-mdio1-default-pins { pinctrl-single,pins = < AM62PX_IOPAD(0x0160, PIN_OUTPUT, 0) /* (F17) MDIO0_MDC */
@@ -280,6 +335,23 @@ bluetooth { }; }; +&mcasp1 { + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_mcasp1>; + op-mode = <0>; /* MCASP_IIS_MODE */ + serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */ + 1 0 2 0 + 0 0 0 0 + 0 0 0 0 + 0 0 0 0 + >; + tdm-slots = <2>; + tx-num-evt = <0>; + rx-num-evt = <0>; + #sound-dai-cells = <0>; + status = "okay"; +}; + &sdhci0 { /* On-module eMMC */ ti,driver-strength-ohm = <50>;
Signature · 1 line
2.47.3
PATCH 3/3 arm64: dts: ti: var-som-am62p: Add support for ADS7846 touchscreen
In reply to Stefano RadaelliThe VAR-SOM-AM62P integrates an ADS7846 resistive touchscreen controller. The controller is physically located on the SOM, and its signals are routed to the SOM pins, allowing carrier boards to make use of it.
This patch adds the ADS7846 node under the appropriate SPI controller.
--- arch/arm64/boot/dts/ti/k3-am62p5-var-som.dtsi | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+)
arch/arm64/boot/dts/ti/k3-am62p5-var-som.dtsi +24 -0
@@ -322,6 +322,30 @@ &main_spi0 { pinctrl-0 = <&pinctrl_spi0>; ti,pindir-d0-out-d1-in; status = "okay"; + + /* Resistive touch controller */ + ads7846: touchscreen@0 { + compatible = "ti,ads7846"; + reg = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_restouch>; + interrupt-parent = <&main_gpio0>; + interrupts = <48 IRQ_TYPE_EDGE_FALLING>; + spi-max-frequency = <1500000>; + pendown-gpio = <&main_gpio0 48 GPIO_ACTIVE_LOW>; + ti,x-min = /bits/ 16 <125>; + ti,x-max = /bits/ 16 <4008>; + ti,y-min = /bits/ 16 <282>; + ti,y-max = /bits/ 16 <3864>; + ti,x-plate-ohms = /bits/ 16 <180>; + ti,pressure-max = /bits/ 16 <255>; + ti,debounce-max = /bits/ 16 <10>; + ti,debounce-tol = /bits/ 16 <3>; + ti,debounce-rep = /bits/ 16 <1>; + ti,settle-delay-usec = /bits/ 16 <150>; + ti,keep-vref-on; + wakeup-source; + }; }; &main_uart5 {
Signature · 1 line
2.47.3
Hi Stefano Radaelli,
Quoted 10 lines · Stefano Radaelli
This patch series introduces updates to the VAR-SOM-AM62P device tree:
- Patch 1 refactors the IPC configuration to align with upstream changes by including the new common
k3-am62p-ti-ipc-firmware.dtsi.
- Patch 2 adds support for the WM8904 audio codec, enabling audio playback and capture.
- Patch 3 adds support for the ADS7846 touchscreen controller available on the SOM.[...]
I have applied the following to branch ti-next on [1]. Thank you!
[1/3] arm64: dts: ti: var-som-am62p: Refactor IPC configuration into common dtsi
commit: 1d10e0e78c2eb91ea62e0a497de1d29f535351f9
[2/3] arm64: dts: ti: var-som-am62p: Add support for WM8904 audio codec
commit: 6f41007cf80d94b689fe4d7e07535dcd427802e7
[3/3] arm64: dts: ti: var-som-am62p: Add support for ADS7846 touchscreen
commit: 397dae3cecd7bfa8e77fa18edc38a69b9459811cAll being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent up the chain during the next merge window (or sooner if it is a relevant bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
[1] https://git.kernel.org/pub/scm/linux/kernel/git/ti/linux.git
--
Vignesh