mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson
synced 2025-09-01 15:14:52 +00:00

Similar to the TI K3-AM62x Soc commit ce27f7f9e3
("arm64: dts: ti: k3-am62-wakeup: Configure ti-sysc for wkup_uart0")
The devices in the wkup domain are capable of waking up the system from
suspend. We can configure the wkup domain devices in a generic way using
the ti-sysc interconnect target module driver like we have done with the
earlier TI SoCs.
As ti-sysc manages the SYSCONFIG related registers independent of the
child hardware device, the wake-up configuration is also set even if
wkup_uart0 is reserved by sysfw.
The wkup_uart0 device has interconnect target module register mapping like
dra7 wkup uart. There is a 1 MB interconnect target range with one uart IP
block in the target module. The power domain and clock affects the whole
interconnect target module.
Note we change the functional clock name to follow the ti-sysc binding
and use "fck" instead of "fclk".
Also note that we need to disable the target module reset as noted by
Markus. Otherwise the sysfw using wkup_uart0 can get confused on some
devices leading to boot time issues such as mbox timeouts.
Signed-off-by: Vibhore Vardhan <vibhore@ti.com>
Signed-off-by: Kendall Willis <k-willis@ti.com>
Reviewed-by: Dhruva Gole <d-gole@ti.com>
Link: https://lore.kernel.org/r/20250212215248.746838-1-k-willis@ti.com
Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
142 lines
3.6 KiB
Plaintext
142 lines
3.6 KiB
Plaintext
// SPDX-License-Identifier: GPL-2.0-only OR MIT
|
|
/*
|
|
* Device Tree file for the WAKEUP domain peripherals shared by AM62P and J722S
|
|
*
|
|
* Copyright (C) 2023-2025 Texas Instruments Incorporated - https://www.ti.com/
|
|
*/
|
|
|
|
#include <dt-bindings/bus/ti-sysc.h>
|
|
|
|
&cbass_wakeup {
|
|
wkup_conf: bus@43000000 {
|
|
compatible = "simple-bus";
|
|
reg = <0x00 0x43000000 0x00 0x20000>;
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
ranges = <0x00 0x00 0x43000000 0x20000>;
|
|
bootph-all;
|
|
|
|
chipid: chipid@14 {
|
|
compatible = "ti,am654-chipid";
|
|
reg = <0x14 0x4>;
|
|
bootph-all;
|
|
};
|
|
|
|
opp_efuse_table: syscon@18 {
|
|
compatible = "ti,am62-opp-efuse-table", "syscon";
|
|
reg = <0x18 0x4>;
|
|
};
|
|
|
|
cpsw_mac_syscon: ethernet-mac-syscon@200 {
|
|
compatible = "ti,am62p-cpsw-mac-efuse", "syscon";
|
|
reg = <0x200 0x8>;
|
|
};
|
|
|
|
usb0_phy_ctrl: syscon@4008 {
|
|
compatible = "ti,am62-usb-phy-ctrl", "syscon";
|
|
reg = <0x4008 0x4>;
|
|
};
|
|
|
|
usb1_phy_ctrl: syscon@4018 {
|
|
compatible = "ti,am62-usb-phy-ctrl", "syscon";
|
|
reg = <0x4018 0x4>;
|
|
};
|
|
};
|
|
|
|
target-module@2b300050 {
|
|
compatible = "ti,sysc-omap2", "ti,sysc";
|
|
reg = <0 0x2b300050 0 0x4>,
|
|
<0 0x2b300054 0 0x4>,
|
|
<0 0x2b300058 0 0x4>;
|
|
reg-names = "rev", "sysc", "syss";
|
|
ti,sysc-mask = <(SYSC_OMAP2_ENAWAKEUP |
|
|
SYSC_OMAP2_SOFTRESET |
|
|
SYSC_OMAP2_AUTOIDLE)>;
|
|
ti,sysc-sidle = <SYSC_IDLE_FORCE>,
|
|
<SYSC_IDLE_NO>,
|
|
<SYSC_IDLE_SMART>,
|
|
<SYSC_IDLE_SMART_WKUP>;
|
|
ti,syss-mask = <1>;
|
|
ti,no-reset-on-init;
|
|
power-domains = <&k3_pds 114 TI_SCI_PD_EXCLUSIVE>;
|
|
clocks = <&k3_clks 114 0>;
|
|
clock-names = "fck";
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
ranges = <0 0 0x2b300000 0x100000>;
|
|
|
|
wkup_uart0: serial@0 {
|
|
compatible = "ti,am64-uart", "ti,am654-uart";
|
|
reg = <0 0x100>;
|
|
interrupts = <GIC_SPI 186 IRQ_TYPE_LEVEL_HIGH>;
|
|
status = "disabled";
|
|
};
|
|
};
|
|
|
|
wkup_i2c0: i2c@2b200000 {
|
|
compatible = "ti,am64-i2c", "ti,omap4-i2c";
|
|
reg = <0x00 0x2b200000 0x00 0x100>;
|
|
interrupts = <GIC_SPI 165 IRQ_TYPE_LEVEL_HIGH>;
|
|
#address-cells = <1>;
|
|
#size-cells = <0>;
|
|
power-domains = <&k3_pds 107 TI_SCI_PD_EXCLUSIVE>;
|
|
clocks = <&k3_clks 107 4>;
|
|
clock-names = "fck";
|
|
status = "disabled";
|
|
};
|
|
|
|
wkup_rtc0: rtc@2b1f0000 {
|
|
compatible = "ti,am62-rtc";
|
|
reg = <0x00 0x2b1f0000 0x00 0x100>;
|
|
interrupts = <GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>;
|
|
clocks = <&k3_clks 117 6> , <&k3_clks 117 0>;
|
|
clock-names = "vbus", "osc32k";
|
|
power-domains = <&k3_pds 117 TI_SCI_PD_EXCLUSIVE>;
|
|
wakeup-source;
|
|
};
|
|
|
|
wkup_rti0: watchdog@2b000000 {
|
|
compatible = "ti,j7-rti-wdt";
|
|
reg = <0x00 0x2b000000 0x00 0x100>;
|
|
clocks = <&k3_clks 132 0>;
|
|
power-domains = <&k3_pds 132 TI_SCI_PD_EXCLUSIVE>;
|
|
assigned-clocks = <&k3_clks 132 0>;
|
|
assigned-clock-parents = <&k3_clks 132 2>;
|
|
/* Used by DM firmware */
|
|
status = "reserved";
|
|
};
|
|
|
|
wkup_vtm0: temperature-sensor@b00000 {
|
|
compatible = "ti,j7200-vtm";
|
|
reg = <0x00 0xb00000 0x00 0x400>,
|
|
<0x00 0xb01000 0x00 0x400>;
|
|
power-domains = <&k3_pds 95 TI_SCI_PD_EXCLUSIVE>;
|
|
#thermal-sensor-cells = <1>;
|
|
};
|
|
|
|
wkup_r5fss0: r5fss@78000000 {
|
|
compatible = "ti,am62-r5fss";
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
ranges = <0x78000000 0x00 0x78000000 0x8000>,
|
|
<0x78100000 0x00 0x78100000 0x8000>;
|
|
power-domains = <&k3_pds 119 TI_SCI_PD_EXCLUSIVE>;
|
|
status = "disabled";
|
|
|
|
wkup_r5fss0_core0: r5f@78000000 {
|
|
compatible = "ti,am62-r5f";
|
|
reg = <0x78000000 0x00008000>,
|
|
<0x78100000 0x00008000>;
|
|
reg-names = "atcm", "btcm";
|
|
ti,sci = <&dmsc>;
|
|
ti,sci-dev-id = <121>;
|
|
ti,sci-proc-ids = <0x01 0xff>;
|
|
resets = <&k3_reset 121 1>;
|
|
firmware-name = "am62-wkup-r5f0_0-fw";
|
|
ti,atcm-enable = <1>;
|
|
ti,btcm-enable = <1>;
|
|
ti,loczrama = <1>;
|
|
};
|
|
};
|
|
};
|