diff --git a/Cargo.toml b/Cargo.toml index 1c737a52..f7b0e8b2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -48,6 +48,7 @@ acpi = "=5.2.0" ############# general ############## iommu = [] # supported by: aarch64 pci = [] # supported by: aarch64, loongarch64 +print_timestamp = [] # print timestamp when logging ############# aarch64 ############## # irqchip driver diff --git a/platform/riscv64/hifive-premier-p550/board.rs b/platform/riscv64/hifive-premier-p550/board.rs index 05cb782a..e7a3d179 100644 --- a/platform/riscv64/hifive-premier-p550/board.rs +++ b/platform/riscv64/hifive-premier-p550/board.rs @@ -19,6 +19,8 @@ use crate::{arch::zone::HvArchZoneConfig, config::*}; pub const BOARD_NAME: &str = "hifive-premier-p550"; pub const BOARD_NCPUS: usize = 4; +pub const TIMEBASE_FREQ: u64 = 0xf4240; // 1MHz + pub const PLIC_BASE: usize = 0xc000000; pub const BOARD_PLIC_INTERRUPTS_NUM: usize = 1023; // except irq 0 pub const SIFIVE_CCACHE_BASE: usize = 0x2010000; // SiFive composable cache controller @@ -140,16 +142,28 @@ pub const ROOT_ZONE_MEMORY_REGIONS: [HvConfigMemoryRegion; 7] = [ // Note: all here's irqs are hardware irqs, // only these irq can be transferred to the physical PLIC. -pub const HW_IRQS: [u32; 3] = [ +pub const HW_IRQS: [u32; 21] = [ + 0x1, 0x2, 0x3, 0x4, // cache controller 0x4f, // emmc 0x51, // sd-card - 0x64 // uart0 + 0x64, // uart0 + 0x164, 0x168, 0x165, 0x166, // iommu + 0x183, // npu + 0x75, 0x77, 0x79, 0x7b, 0x7d, 0x7f, 0x81, 0x83, // mailbox + 0x123, // i2c + // 0x01, 0x03, 0x04, 0x02, // cache controller ]; // irqs belong to the root zone. -pub const ROOT_ZONE_IRQS: [u32; 2] = [ +pub const ROOT_ZONE_IRQS: [u32; 20] = [ + 0x1, 0x2, 0x3, 0x4, // cache controller 0x51, // sd-card - 0x64 // uart0 + 0x64, // uart0 + 0x164, 0x168, 0x165, 0x166, // iommu + 0x183, // npu + 0x75, 0x77, 0x79, 0x7b, 0x7d, 0x7f, 0x81, 0x83, // mailbox + 0x123, // i2c + // 0x01, 0x03, 0x04, 0x02, // cache controller ]; pub const ROOT_ARCH_ZONE_CONFIG: HvArchZoneConfig = HvArchZoneConfig { diff --git a/platform/riscv64/hifive-premier-p550/boot.scr b/platform/riscv64/hifive-premier-p550/boot.scr index b6aff6ab..798ac789 100644 Binary files a/platform/riscv64/hifive-premier-p550/boot.scr and b/platform/riscv64/hifive-premier-p550/boot.scr differ diff --git a/platform/riscv64/hifive-premier-p550/image/dts/eic7700-hifive-premier-p550.dts b/platform/riscv64/hifive-premier-p550/image/dts/eic7700-hifive-premier-p550.dts index fd290b8a..aa6cc1c8 100644 --- a/platform/riscv64/hifive-premier-p550/image/dts/eic7700-hifive-premier-p550.dts +++ b/platform/riscv64/hifive-premier-p550/image/dts/eic7700-hifive-premier-p550.dts @@ -6,7 +6,7 @@ compatible = "sifive,hifive-premier-p550\0eswin,eic7700"; model = "SiFive HiFive Premier P550"; - opp-table@cpu { + opp-table-d0@cpu { compatible = "operating-points-v2"; opp-shared; phandle = <0x04>; @@ -114,9 +114,92 @@ }; }; + opp-table-d1@cpu { + compatible = "operating-points-v2"; + opp-shared; + + opp-24000000 { + opp-hz = <0x00 0x16e3600>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-100000000 { + opp-hz = <0x00 0x5f5e100>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-200000000 { + opp-hz = <0x00 0xbebc200>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-400000000 { + opp-hz = <0x00 0x17d78400>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-500000000 { + opp-hz = <0x00 0x1dcd6500>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-600000000 { + opp-hz = <0x00 0x23c34600>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-700000000 { + opp-hz = <0x00 0x29b92700>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-800000000 { + opp-hz = <0x00 0x2faf0800>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-900000000 { + opp-hz = <0x00 0x35a4e900>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-1000000000 { + opp-hz = <0x00 0x3b9aca00>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-1200000000 { + opp-hz = <0x00 0x47868c00>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-1300000000 { + opp-hz = <0x00 0x4d7c6d00>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + + opp-1400000000 { + opp-hz = <0x00 0x53724e00>; + opp-microvolt = "\0\f5"; + clock-latency-ns = <0x11170>; + }; + }; + opp-table@dsp { compatible = "operating-points-v2"; - phandle = <0x25>; + phandle = <0x22>; opp@520000000 { opp-hz = <0x00 0x1efe9200>; @@ -131,7 +214,7 @@ opp-table@npu { compatible = "operating-points-v2"; - phandle = <0x22>; + phandle = <0x1f>; opp@1040000000 { opp-hz = <0x00 0x3dfd2400>; @@ -146,7 +229,7 @@ opp-table@g2d { compatible = "operating-points-v2"; - phandle = <0x2b>; + phandle = <0x28>; opp@260000000 { opp-hz = <0x00 0xf7f4900>; @@ -171,7 +254,7 @@ opp-table@vi { compatible = "operating-points-v2"; - phandle = <0x6c>; + phandle = <0x63>; opp@800000000 { opp-hz = <0x00 0x2faf0800>; @@ -191,7 +274,7 @@ opp-table@venc { compatible = "operating-points-v2"; - phandle = <0x32>; + phandle = <0x2f>; opp@800000000 { opp-hz = <0x00 0x2faf0800>; @@ -211,7 +294,7 @@ opp-table@vdec { compatible = "operating-points-v2"; - phandle = <0x31>; + phandle = <0x2e>; opp@800000000 { opp-hz = <0x00 0x2faf0800>; @@ -544,6 +627,8 @@ }; cache-controller@2010000 { + #address-cells = <0x02>; + #size-cells = <0x02>; cache-block-size = <0x40>; cache-level = <0x03>; cache-sets = <0x1000>; @@ -552,7 +637,6 @@ compatible = "sifive,ccache1\0cache\0sifive,fu740-c000-ccache"; interrupt-parent = <0x10>; interrupts = <0x01 0x03 0x04 0x02>; - next-level-cache = <0x11 0x12 0x13>; reg = <0x00 0x2010000 0x00 0x4000 0x00 0x8000000 0x00 0x400000>; reg-names = "control\0sideband"; sifive,a-mshr-count = <0x3c>; @@ -561,7 +645,13 @@ sifive,max-master-id = <0x0d>; sifive,perfmon-counters = <0x06>; numa-node-id = <0x00>; - phandle = <0x14>; + ranges; + phandle = <0x11>; + + zero-device@1a000000 { + compatible = "l3,zero-device"; + reg = <0x00 0x1a000000 0x00 0x400000>; + }; }; debug-controller@0 { @@ -579,7 +669,6 @@ error-device@10003000 { compatible = "sifive,error0"; reg = <0x00 0x10003000 0x00 0x1000>; - phandle = <0x11>; }; interrupt-controller@c000000 { @@ -610,7 +699,7 @@ cache-size = <0x40000>; cache-unified; compatible = "sifive,pL2Cache0\0cache"; - next-level-cache = <0x14>; + next-level-cache = <0x11>; reg = <0x00 0x104000 0x00 0x4000>; reg-names = "control"; sifive,ecc-granularity = <0x10>; @@ -626,7 +715,7 @@ cache-size = <0x40000>; cache-unified; compatible = "sifive,pL2Cache0\0cache"; - next-level-cache = <0x14>; + next-level-cache = <0x11>; reg = <0x00 0x108000 0x00 0x4000>; reg-names = "control"; sifive,ecc-granularity = <0x10>; @@ -642,7 +731,7 @@ cache-size = <0x40000>; cache-unified; compatible = "sifive,pL2Cache0\0cache"; - next-level-cache = <0x14>; + next-level-cache = <0x11>; reg = <0x00 0x10c000 0x00 0x4000>; reg-names = "control"; sifive,ecc-granularity = <0x10>; @@ -658,7 +747,7 @@ cache-size = <0x40000>; cache-unified; compatible = "sifive,pL2Cache0\0cache"; - next-level-cache = <0x14>; + next-level-cache = <0x11>; reg = <0x00 0x110000 0x00 0x4000>; reg-names = "control"; sifive,ecc-granularity = <0x10>; @@ -670,13 +759,11 @@ rom@1a000000 { compatible = "ucbbar,cacheable-zero0"; reg = <0x00 0x1a000000 0x00 0x400000>; - phandle = <0x12>; }; rom@3a000000 { compatible = "ucbbar,cacheable-zero0"; reg = <0x00 0x3a000000 0x00 0x400000>; - phandle = <0x13>; }; subsystem_pbus_clock { @@ -748,7 +835,7 @@ reg-io-width = <0x04>; numa-node-id = <0x00>; status = "okay"; - phandle = <0x2a>; + phandle = <0x27>; }; serial@0x50910000 { @@ -805,13 +892,13 @@ #size-cells = <0x02>; reg = <0x00 0x51810000 0x00 0x8000>; numa-node-id = <0x00>; - phandle = <0x17>; + phandle = <0x14>; noc@51810324 { compatible = "eswin,win2030-noc-wdt"; interrupt-parent = <0x10>; interrupts = <0x188 0x189 0x18a 0x18b 0x18c 0x18d 0x18e 0x18f 0x190 0x191 0x192 0x193 0x194 0x195 0x196 0x197 0x198 0x199 0x19a 0x19b 0x19c 0x19d 0x19e 0x19f 0x1a0 0x1a1 0x1a2 0x1a3 0x1a4 0x1a5 0x1a6 0x1a7 0x1a8 0x1a9 0x1aa>; - eswin,syscrg_csr = <0x15 0x100 0xffff>; + eswin,syscrg_csr = <0x12 0x100 0xffff>; status = "okay"; }; }; @@ -820,14 +907,14 @@ compatible = "eswin,win2030-sys-crg\0syscon\0simple-mfd"; reg = <0x00 0x51828000 0x00 0x80000>; numa-node-id = <0x00>; - phandle = <0x15>; + phandle = <0x12>; reset-controller { compatible = "eswin,win2030-reset"; #reset-cells = <0x02>; numa-node-id = <0x00>; status = "okay"; - phandle = <0x18>; + phandle = <0x15>; }; clock-controller { @@ -835,7 +922,7 @@ #clock-cells = <0x01>; numa-node-id = <0x00>; status = "okay"; - cpu-voltage-gpios = <0x16 0x1e 0x00>; + cpu-voltage-gpios = <0x13 0x1e 0x00>; phandle = <0x03>; }; }; @@ -853,29 +940,29 @@ numa-node-id = <0x00>; #size-cells = <0x02>; reg = <0x00 0x50440000 0x00 0x2000>; - phandle = <0x1a>; + phandle = <0x17>; }; iommu@50c00000 { compatible = "arm,smmu-v3"; reg = <0x00 0x50c00000 0x00 0x100000>; - eswin,syscfg = <0x17 0x3fc>; + eswin,syscfg = <0x14 0x3fc>; interrupt-parent = <0x10>; interrupts = <0x164 0x168 0x165 0x166>; interrupt-names = "eventq\0gerror\0priq\0cmdq-sync"; #iommu-cells = <0x01>; - resets = <0x18 0x05 0x01 0x18 0x05 0x02 0x18 0x05 0x10 0x18 0x05 0x20 0x18 0x05 0x40 0x18 0x05 0x80 0x18 0x05 0x100 0x18 0x05 0x200 0x18 0x05 0x400 0x18 0x05 0x800>; + resets = <0x15 0x05 0x01 0x15 0x05 0x02 0x15 0x05 0x10 0x15 0x05 0x20 0x15 0x05 0x40 0x15 0x05 0x80 0x15 0x05 0x100 0x15 0x05 0x200 0x15 0x05 0x400 0x15 0x05 0x800>; reset-names = "axi_rst\0cfg_rst\0tbu0_rst\0tbu1_rst\0tbu2_rst\0tbu3_rst\0tbu4_rst\0tbu5_rst\0tbu6_rst\0tbu7_rst"; status = "okay"; numa-node-id = <0x00>; dma-noncoherent; - phandle = <0x19>; + phandle = <0x16>; }; pmu@50c02000 { compatible = "arm,smmu-v3-pmcg"; reg = <0x00 0x50c02000 0x00 0x1000 0x00 0x50c22000 0x00 0x1000>; - eswin,syscfg = <0x17 0x3fc>; + eswin,syscfg = <0x14 0x3fc>; interrupt-parent = <0x10>; interrupts = <0x16b>; status = "disabled"; @@ -887,7 +974,7 @@ compatible = "riscv,dev-foo-a"; #size-cells = <0x02>; dma-ranges = <0x00 0x20000000 0x00 0xc0000000 0x00 0x40000000>; - iommus = <0x19 0x1c>; + iommus = <0x16 0x1c>; tbus = <0xf00>; status = "okay"; numa-node-id = <0x00>; @@ -994,41 +1081,15 @@ }; }; - dma-controller-hsp@0x50430000 { - compatible = "eswin,eic770x-axi-dma"; - reg = <0x00 0x50430000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x39>; - #dma-cells = <0x02>; - clocks = <0x03 0x2b2 0x03 0x2b3>; - clock-names = "core-clk\0cfgr-clk"; - resets = <0x18 0x07 0x4000 0x18 0x07 0x100000>; - reset-names = "arst\0prst"; - dma-channels = <0x0c>; - snps,dma-masters = <0x01>; - snps,priority = <0x00 0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08 0x09 0x0a 0x0b>; - snps,data-width = <0x02>; - snps,block-size = <0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000>; - snps,axi-max-burst-len = <0x10>; - snps,max-msize = <0x40>; - iommus = <0x19 0x01>; - tbus = <0x02>; - eswin,hsp_sp_csr = <0x1a 0x104c>; - eswin,syscfg = <0x17 0x3004 0x370>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - }; - dma-controller-aon@0x518c0000 { compatible = "eswin,eic770x-axi-dma"; reg = <0x00 0x518c0000 0x00 0x10000>; interrupt-parent = <0x10>; interrupts = <0x121>; - #dma-cells = <0x02>; + #dma-cells = <0x03>; clocks = <0x03 0x266 0x03 0x264>; clock-names = "core-clk\0cfgr-clk"; - resets = <0x18 0x27 0x01 0x18 0x27 0x02>; + resets = <0x15 0x27 0x01 0x15 0x27 0x02>; reset-names = "arst\0prst"; dma-channels = <0x10>; snps,dma-masters = <0x02>; @@ -1036,16 +1097,43 @@ snps,data-width = <0x03>; snps,block-size = <0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000>; snps,axi-max-burst-len = <0x20>; + snps,max-msize = <0x40>; #size-cells = <0x02>; #address-cells = <0x02>; dma-ranges = <0x00 0x80000000 0x00 0x80000000 0x100 0x00>; - iommus = <0x19 0x1a>; + iommus = <0x16 0x1a>; tbus = <0x04>; - eswin,syscfg = <0x17 0x3004 0x370>; + eswin,syscfg = <0x14 0x3004 0x370>; + numa-node-id = <0x00>; + dma-noncoherent; + status = "okay"; + phandle = <0x39>; + }; + + dma-controller-hsp@0x50430000 { + compatible = "eswin,eic770x-axi-dma"; + reg = <0x00 0x50430000 0x00 0x10000>; + interrupt-parent = <0x10>; + interrupts = <0x39>; + #dma-cells = <0x03>; + clocks = <0x03 0x2b2 0x03 0x2b3>; + clock-names = "core-clk\0cfgr-clk"; + resets = <0x15 0x07 0x4000 0x15 0x07 0x100000>; + reset-names = "arst\0prst"; + dma-channels = <0x0c>; + snps,dma-masters = <0x01>; + snps,priority = <0x00 0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08 0x09 0x0a 0x0b>; + snps,data-width = <0x02>; + snps,block-size = <0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000 0x80000>; + snps,axi-max-burst-len = <0x10>; + snps,max-msize = <0x40>; + iommus = <0x16 0x01>; + tbus = <0x02>; + eswin,hsp_sp_csr = <0x17 0x104c>; + eswin,syscfg = <0x14 0x3004 0x370>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x3c>; }; ethernet@50400000 { @@ -1060,18 +1148,18 @@ status = "okay"; clocks = <0x03 0x226 0x03 0x227 0x03 0x228>; clock-names = "app\0stmmaceth\0tx"; - resets = <0x18 0x07 0x4000000>; + resets = <0x15 0x07 0x4000000>; reset-names = "ethrst"; tbus = <0x02>; dma-noncoherent; - eswin,hsp_sp_csr = <0x1a 0x1030 0x100 0x108>; - eswin,syscrg_csr = <0x15 0x148 0x14c>; + eswin,hsp_sp_csr = <0x17 0x1030 0x100 0x108>; + eswin,syscrg_csr = <0x12 0x148 0x14c>; eswin,dly_hsp_reg = <0x114 0x118 0x11c>; - snps,axi-config = <0x1b>; + snps,axi-config = <0x18>; pinctrl-names = "default"; - pinctrl-0 = <0x1c>; - rst-gpios = <0x1d 0x0a 0x01>; - eswin,rgmiisel = <0x1e 0x290 0x03>; + pinctrl-0 = <0x19>; + rst-gpios = <0x1a 0x0a 0x01>; + eswin,rgmiisel = <0x1b 0x290 0x03>; eswin,led-cfgs = <0x6100 0xa40 0x420>; dly-param-1000m = <0x23232323 0x800c8023 0xc0c0c0c>; dly-param-100m = <0x50505050 0x803f8050 0x3f3f3f3f>; @@ -1082,7 +1170,7 @@ snps,rd_osr_lmt = <0x02>; snps,wr_osr_lmt = <0x02>; snps,lpi_en = <0x00>; - phandle = <0x1b>; + phandle = <0x18>; }; }; @@ -1098,18 +1186,18 @@ status = "okay"; clocks = <0x03 0x226 0x03 0x227 0x03 0x229>; clock-names = "app\0stmmaceth\0tx"; - resets = <0x18 0x07 0x2000000>; + resets = <0x15 0x07 0x2000000>; reset-names = "ethrst"; tbus = <0x02>; dma-noncoherent; - eswin,hsp_sp_csr = <0x1a 0x1034 0x200 0x208>; - eswin,syscrg_csr = <0x15 0x148 0x14c>; + eswin,hsp_sp_csr = <0x17 0x1034 0x200 0x208>; + eswin,syscrg_csr = <0x12 0x148 0x14c>; eswin,dly_hsp_reg = <0x214 0x218 0x21c>; - snps,axi-config = <0x1f>; + snps,axi-config = <0x1c>; pinctrl-names = "default"; - pinctrl-0 = <0x20>; - rst-gpios = <0x1d 0x0f 0x01>; - eswin,rgmiisel = <0x1e 0x294 0x03>; + pinctrl-0 = <0x1d>; + rst-gpios = <0x1a 0x0f 0x01>; + eswin,rgmiisel = <0x1b 0x294 0x03>; eswin,led-cfgs = <0x6100 0xa40 0x420>; dly-param-1000m = <0x25252525 0x80268025 0x26262626>; dly-param-100m = <0x48484848 0x80588048 0x58585858>; @@ -1120,7 +1208,7 @@ snps,rd_osr_lmt = <0x02>; snps,wr_osr_lmt = <0x02>; snps,lpi_en = <0x00>; - phandle = <0x1f>; + phandle = <0x1c>; }; }; @@ -2119,37 +2207,37 @@ interrupts = <0x183 0x10>; #size-cells = <0x02>; dma-ranges = <0x01 0x00 0x00 0xc0000000 0x1ff 0x00>; - iommus = <0x19 0x04>; + iommus = <0x16 0x04>; tbus = <0x05>; dsp-avail-num = <0x01>; spram-size = <0x400000>; - npu_mbox = <0x21>; - clocks = <0x03 0x236 0x03 0x237 0x03 0x23c 0x03 0x23d 0x03 0x26 0x03 0x0b 0x03 0x07>; - clock-names = "aclk\0cfg_clk\0core_clk\0e31_core_clk\0mux_u_npu_core_3mux1_gfree\0fixed_rate_clk_spll2_fout2\0fixed_rate_clk_spll1_fout1"; - resets = <0x18 0x06 0x08>; + npu_mbox = <0x1e>; + clocks = <0x03 0x236 0x03 0x237 0x03 0x23c 0x03 0x23a 0x03 0x23d 0x03 0x26 0x03 0x25 0x03 0x0b 0x03 0x07 0x03 0x238 0x03 0x0d>; + clock-names = "aclk\0cfg_clk\0core_clk\0clk_npu_llc_aclk\0e31_core_clk\0mux_u_npu_core_3mux1_gfree\0mux_u_npu_llclk_3mux1_gfree\0fixed_rate_clk_spll2_fout2\0fixed_rate_clk_spll1_fout1\0clk_clk_npu_llc_src0\0fixed_rate_clk_vpll_fout1"; + resets = <0x15 0x06 0x08>; reset-names = "e31_core"; - operating-points-v2 = <0x22>; + operating-points-v2 = <0x1f>; numa-node-id = <0x00>; firmware-name = "eic7700_die0_e31_fw"; dma-noncoherent; #cooling-cells = <0x02>; dynamic-power-coefficient = <0x00>; status = "okay"; - npu-supply = <0x23>; + npu-supply = <0x20>; }; llc@51c00000 { compatible = "eswin,llc"; reg = <0x00 0x51c00000 0x00 0x400000>; - eswin,syscfg = <0x17 0x324>; - eswin,syscrg_csr = <0x15>; + eswin,syscfg = <0x14 0x324>; + eswin,syscrg_csr = <0x12>; clocks = <0x03 0x236 0x03 0x237 0x03 0x23a 0x03 0x23c 0x03 0x26 0x03 0x0b 0x03 0x07>; clock-names = "aclk\0cfg_clk\0llc_clk\0core_clk\0mux_u_npu_core_3mux1_gfree\0fixed_rate_clk_spll2_fout2\0fixed_rate_clk_spll1_fout1"; - resets = <0x18 0x06 0x01 0x18 0x06 0x02 0x18 0x06 0x04 0x18 0x06 0x40>; + resets = <0x15 0x06 0x01 0x15 0x06 0x02 0x15 0x06 0x04 0x15 0x06 0x40>; reset-names = "axi\0cfg\0core\0llc"; numa-node-id = <0x00>; - spram-region = <0x24>; - npu-supply = <0x23>; + spram-region = <0x21>; + npu-supply = <0x20>; status = "okay"; }; @@ -2163,7 +2251,7 @@ compatible = "es-dsp-subsys\0simple-bus"; clocks = <0x03 0x210 0x03 0x20f>; clock-names = "cfg_clk\0aclk"; - resets = <0x18 0x02 0x01 0x18 0x02 0x02 0x18 0x02 0x04 0x18 0x02 0x10 0x18 0x02 0x20 0x18 0x02 0x40 0x18 0x02 0x80>; + resets = <0x15 0x02 0x01 0x15 0x02 0x02 0x15 0x02 0x04 0x15 0x02 0x10 0x15 0x02 0x20 0x15 0x02 0x40 0x15 0x02 0x80>; reset-names = "axi\0cfg\0div4\0div_0\0div_1\0div_2\0div_3"; status = "okay"; @@ -2174,15 +2262,15 @@ ranges = <0x28000000 0x00 0x5b000000 0x8000 0x28100000 0x00 0x5b100000 0x20000 0x28120000 0x00 0x5b120000 0x20000>; clocks = <0x03 0x2a8>; clock-names = "aclk"; - operating-points-v2 = <0x25>; - dsp_mbox = <0x26>; + operating-points-v2 = <0x22>; + dsp_mbox = <0x23>; device-irq = <0x0b 0x50a90000 0x20 0x50a80000 0x01 0x50a40000>; device-uart = <0x50900000>; device-irq-mode = <0x01>; host-irq-mode = <0x01>; firmware-name = "eic7700_dsp_fw"; process-id = <0x00>; - iommus = <0x19 0x12>; + iommus = <0x16 0x12>; tbus = <0x70>; dma-noncoherent; numa-node-id = <0x00>; @@ -2200,15 +2288,15 @@ ranges = <0x28000000 0x00 0x5b008000 0x8000 0x28100000 0x00 0x5b140000 0x20000 0x28120000 0x00 0x5b160000 0x20000>; clocks = <0x03 0x2a9>; clock-names = "aclk"; - operating-points-v2 = <0x25>; - dsp_mbox = <0x27>; + operating-points-v2 = <0x22>; + dsp_mbox = <0x24>; device-irq = <0x0d 0x50ab0000 0x40 0x50aa0000 0x01 0x50a40000>; device-uart = <0x50900000>; device-irq-mode = <0x01>; host-irq-mode = <0x01>; firmware-name = "eic7700_dsp_fw"; process-id = <0x01>; - iommus = <0x19 0x13>; + iommus = <0x16 0x13>; tbus = <0x71>; dma-noncoherent; numa-node-id = <0x00>; @@ -2226,15 +2314,15 @@ ranges = <0x28000000 0x00 0x5b010000 0x8000 0x28100000 0x00 0x5b180000 0x20000 0x28120000 0x00 0x5b1a0000 0x20000>; clocks = <0x03 0x2aa>; clock-names = "aclk"; - operating-points-v2 = <0x25>; - dsp_mbox = <0x28>; + operating-points-v2 = <0x22>; + dsp_mbox = <0x25>; device-irq = <0x0f 0x50ad0000 0x80 0x50ac0000 0x01 0x50a40000>; device-uart = <0x50900000>; device-irq-mode = <0x01>; host-irq-mode = <0x01>; firmware-name = "eic7700_dsp_fw"; process-id = <0x02>; - iommus = <0x19 0x14>; + iommus = <0x16 0x14>; tbus = <0x72>; dma-noncoherent; numa-node-id = <0x00>; @@ -2252,15 +2340,15 @@ ranges = <0x28000000 0x00 0x5b018000 0x8000 0x28100000 0x00 0x5b1c0000 0x20000 0x28120000 0x00 0x5b1e0000 0x20000>; clocks = <0x03 0x2ab>; clock-names = "aclk"; - operating-points-v2 = <0x25>; - dsp_mbox = <0x29>; + operating-points-v2 = <0x22>; + dsp_mbox = <0x26>; device-irq = <0x11 0x50af0000 0x100 0x50ae0000 0x01 0x50a40000>; device-uart = <0x50900000>; device-irq-mode = <0x01>; host-irq-mode = <0x01>; firmware-name = "eic7700_dsp_fw"; process-id = <0x03>; - iommus = <0x19 0x15>; + iommus = <0x16 0x15>; tbus = <0x73>; dma-noncoherent; numa-node-id = <0x00>; @@ -2278,16 +2366,16 @@ compatible = "eswin,sof-dsp"; reg = <0x00 0x5b018000 0x00 0x8000 0x00 0x5b1c0000 0x00 0x40000>; mbox-names = "dsp-mbox"; - mboxes = <0x29 0x00>; + mboxes = <0x26 0x00>; clocks = <0x03 0x2ab>; clock-names = "aclk"; process-id = <0x03>; - iommus = <0x19 0x15>; + iommus = <0x16 0x15>; tbus = <0x73>; dma-noncoherent; mailbox-dsp-to-u84-addr = <0x50af0000>; mailbox-u84-to-dsp-addr = <0x50ae0000>; - dsp-uart = <0x2a>; + dsp-uart = <0x27>; device-uart-mutex = <0x51820000>; numa-node-id = <0x00>; }; @@ -2297,7 +2385,7 @@ compatible = "eswin,galcore_d0"; clocks = <0x03 0x254 0x03 0x255 0x03 0x25a 0x03 0x25b 0x03 0x25c 0x03 0x25d 0x03 0x2b1>; clock-names = "vc_aclk\0vc_cfg\0g2d_cfg\0g2d_st2\0g2d_clk\0g2d_aclk\0mon_pclk"; - resets = <0x18 0x16 0x02 0x18 0x16 0x01 0x18 0x16 0x04 0x18 0x1b 0x01 0x18 0x1b 0x02 0x18 0x1b 0x04>; + resets = <0x15 0x16 0x02 0x15 0x16 0x01 0x15 0x16 0x04 0x15 0x1b 0x01 0x15 0x1b 0x02 0x15 0x1b 0x04>; reset-names = "axi\0cfg\0moncfg\0g2d_core\0g2d_cfg\0g2d_axi"; reg = <0x00 0x50140000 0x00 0x40000 0x00 0x50180000 0x00 0x40000>; reg-names = "core_2d\0core_2d1"; @@ -2309,7 +2397,7 @@ contiguous-size = <0xa00000>; recovery = <0x00>; dma-noncoherent; - operating-points-v2 = <0x2b>; + operating-points-v2 = <0x28>; numa-node-id = <0x00>; status = "okay"; }; @@ -2321,7 +2409,7 @@ reg = <0x00 0x51400000 0x00 0xfffff>; clocks = <0x03 0x20b 0x03 0x20c 0x03 0x20d>; clock-names = "aclk\0gray_clk\0cfg_clk"; - resets = <0x18 0x01 0x01 0x18 0x01 0x02 0x18 0x01 0x04 0x18 0x01 0x08 0x18 0x01 0x10>; + resets = <0x15 0x01 0x01 0x15 0x01 0x02 0x15 0x01 0x04 0x15 0x01 0x08 0x15 0x01 0x10>; reset-names = "axi\0cfg\0gray\0jones\0spu"; interrupt-parent = <0x10>; interrupts = <0x0f>; @@ -2339,19 +2427,19 @@ interrupt-names = "intrq\0msi\0pme"; interrupts = <0x3a 0x3b 0x3c>; ports-implemented = <0x01>; - resets = <0x18 0x07 0x8000000>; + resets = <0x15 0x07 0x8000000>; reset-names = "apb"; #size-cells = <0x02>; - iommus = <0x19 0x0e>; + iommus = <0x16 0x0e>; tbus = <0x02>; dma-ranges = <0x00 0x00 0x00 0xc0000000 0x200 0x00>; - eswin,hsp_sp_csr = <0x1a 0x1050>; - eswin,syscrg_csr = <0x15 0x41c>; + eswin,hsp_sp_csr = <0x17 0x1050>; + eswin,syscrg_csr = <0x12 0x41c>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; pinctrl-names = "default"; - pinctrl-0 = <0x2c>; + pinctrl-0 = <0x29>; }; pcie@0x54000000 { @@ -2359,7 +2447,7 @@ clocks = <0x03 0x232 0x03 0x233 0x03 0x234 0x03 0x235>; clock-names = "pcie_aclk\0pcie_cfg_clk\0pcie_cr_clk\0pcie_aux_clk"; reset-names = "pcie_cfg\0pcie_powerup\0pcie_pwren"; - resets = <0x18 0x08 0x01 0x18 0x08 0x02 0x18 0x08 0x04>; + resets = <0x15 0x08 0x01 0x15 0x08 0x02 0x15 0x08 0x04>; #address-cells = <0x03>; #size-cells = <0x02>; #interrupt-cells = <0x01>; @@ -2374,8 +2462,8 @@ interrupt-parent = <0x10>; interrupt-map-mask = <0x00 0x00 0x00 0x07>; interrupt-map = <0x00 0x00 0x00 0x01 0x10 0xb3 0x00 0x00 0x00 0x02 0x10 0xb4 0x00 0x00 0x00 0x03 0x10 0xb5 0x00 0x00 0x00 0x04 0x10 0xb6>; - iommus = <0x19 0xfe0000>; - iommu-map = <0x00 0x19 0xff0000 0xffffff>; + iommus = <0x16 0xfe0000>; + iommu-map = <0x00 0x16 0xff0000 0xffffff>; tbus = <0x03>; status = "okay"; numa-node-id = <0x00>; @@ -2392,7 +2480,7 @@ clock-names = "clk"; interrupt-parent = <0x10>; interrupts = <0x5b>; - resets = <0x18 0x10 0x01>; + resets = <0x15 0x10 0x01>; reset-names = "spi"; numa-node-id = <0x00>; status = "disabled"; @@ -2409,7 +2497,7 @@ clock-names = "clk"; interrupt-parent = <0x10>; interrupts = <0x5c>; - resets = <0x18 0x10 0x02>; + resets = <0x15 0x10 0x02>; reset-names = "spi"; numa-node-id = <0x00>; status = "disabled"; @@ -2423,15 +2511,15 @@ #size-cells = <0x00>; clocks = <0x03 0x205 0x03 0x204>; clock-names = "cfg_clk\0clk"; - resets = <0x18 0x24 0x02>; + resets = <0x15 0x24 0x02>; reset-names = "rst"; spi-max-frequency = "\0I>"; reg-io-width = <0x04>; numa-node-id = <0x00>; status = "okay"; num-cs = <0x01>; - cs-gpios = <0x1d 0x00 0x01>; - wp-gpios = <0x1d 0x04 0x01>; + cs-gpios = <0x1a 0x00 0x01>; + wp-gpios = <0x1a 0x04 0x01>; spi-flash@0 { compatible = "winbond,w25q128jw\0jedec,spi-nor"; @@ -2454,7 +2542,7 @@ clock-names = "clk_xin\0clk_ahb"; clock-output-names = "emmc_cardclock"; #clock-cells = <0x00>; - resets = <0x18 0x07 0x40 0x18 0x07 0x08 0x18 0x07 0x80000 0x18 0x07 0x800000>; + resets = <0x15 0x07 0x40 0x15 0x07 0x08 0x15 0x07 0x80000 0x15 0x07 0x800000>; reset-names = "txrx_rst\0phy_rst\0prstn\0arstn"; core-clk-reg = <0x51828160>; disable-cqe-dcmd; @@ -2463,11 +2551,11 @@ mmc-hs400-1_8v; max-frequency = <0xbebc200>; #size-cells = <0x02>; - iommus = <0x19 0x0f>; + iommus = <0x16 0x0f>; tbus = <0x02>; dma-ranges = <0x00 0x00 0x00 0xc0000000 0x01 0x00>; - eswin,hsp_sp_csr = <0x1a 0x1038 0x508 0x50c>; - eswin,syscrg_csr = <0x15 0x160 0x148 0x14c>; + eswin,hsp_sp_csr = <0x17 0x1038 0x508 0x50c>; + eswin,syscrg_csr = <0x12 0x160 0x148 0x14c>; status = "okay"; numa-node-id = <0x00>; dma-noncoherent; @@ -2476,7 +2564,7 @@ enable-cmd-pullup; enable-data-pullup; pinctrl-names = "default"; - pinctrl-0 = <0x2d>; + pinctrl-0 = <0x2a>; no-sdio; no-sd; }; @@ -2490,17 +2578,17 @@ clock-names = "clk_xin\0clk_ahb\0clk_spll2_fout3\0clk_mux1_1"; clock-output-names = "sdio0_cardclock"; #clock-cells = <0x00>; - resets = <0x18 0x07 0x80 0x18 0x07 0x10 0x18 0x07 0x40000 0x18 0x07 0x400000>; + resets = <0x15 0x07 0x80 0x15 0x07 0x10 0x15 0x07 0x40000 0x15 0x07 0x400000>; reset-names = "txrx_rst\0phy_rst\0prstn\0arstn"; clock-frequency = <0xc65d400>; max-frequency = <0xc65d400>; #address-cells = <0x01>; #size-cells = <0x00>; dma-ranges = <0x00 0x20000000 0x00 0xc0000000 0x00 0x40000000>; - iommus = <0x19 0x10>; + iommus = <0x16 0x10>; tbus = <0x02>; - eswin,hsp_sp_csr = <0x1a 0x103c 0x608 0x60c>; - eswin,syscrg_csr = <0x15 0x164 0x148 0x14c>; + eswin,hsp_sp_csr = <0x17 0x103c 0x608 0x60c>; + eswin,syscrg_csr = <0x12 0x164 0x148 0x14c>; bus-width = <0x04>; sdio-id = <0x00>; numa-node-id = <0x00>; @@ -2523,17 +2611,17 @@ clock-names = "clk_xin\0clk_ahb\0clk_spll2_fout3\0clk_mux1_1"; clock-output-names = "sdio1_cardclock"; #clock-cells = <0x00>; - resets = <0x18 0x07 0x100 0x18 0x07 0x20 0x18 0x07 0x20000 0x18 0x07 0x200000>; + resets = <0x15 0x07 0x100 0x15 0x07 0x20 0x15 0x07 0x20000 0x15 0x07 0x200000>; reset-names = "txrx_rst\0phy_rst\0prstn\0arstn"; clock-frequency = <0xc65d400>; max-frequency = <0xc65d400>; #address-cells = <0x01>; #size-cells = <0x00>; dma-ranges = <0x00 0x20000000 0x00 0xc0000000 0x00 0x40000000>; - iommus = <0x19 0x11>; + iommus = <0x16 0x11>; tbus = <0x02>; - eswin,hsp_sp_csr = <0x1a 0x1040 0x708 0x70c>; - eswin,syscrg_csr = <0x15 0x168 0x148 0x14c>; + eswin,hsp_sp_csr = <0x17 0x1040 0x708 0x70c>; + eswin,syscrg_csr = <0x12 0x168 0x148 0x14c>; bus-width = <0x04>; sdio-id = <0x01>; numa-node-id = <0x00>; @@ -2551,13 +2639,13 @@ wifi_aw3155@0 { compatible = "aml_w1_sdio"; reg = <0x00>; - interrupt-parent = <0x2e>; + interrupt-parent = <0x2b>; interrupts = <0x0f 0x08>; pinctrl-names = "default\0default"; - pinctrl-0 = <0x2f>; - pinctrl-1 = <0x30>; - irq-gpios = <0x2e 0x0f 0x00>; - rst-gpios = <0x16 0x0f 0x00>; + pinctrl-0 = <0x2c>; + pinctrl-1 = <0x2d>; + irq-gpios = <0x2b 0x0f 0x00>; + rst-gpios = <0x13 0x0f 0x00>; }; }; @@ -2565,17 +2653,17 @@ compatible = "eswin,video-decoder0"; clocks = <0x03 0x254 0x03 0x255 0x03 0x257 0x03 0x259 0x03 0x2e 0x03 0x04 0x03 0x0a 0x03 0x2ae 0x03 0x2b0 0x03 0x2b1>; clock-names = "aclk\0cfg_clk\0jd_clk\0vd_clk\0vc_mux\0spll0_fout1\0spll2_fout1\0jd_pclk\0vd_pclk\0mon_pclk"; - resets = <0x18 0x16 0x02 0x18 0x16 0x01 0x18 0x16 0x04 0x18 0x17 0x01 0x18 0x17 0x02 0x18 0x19 0x01 0x18 0x19 0x02>; + resets = <0x15 0x16 0x02 0x15 0x16 0x01 0x15 0x16 0x04 0x15 0x17 0x01 0x15 0x17 0x02 0x15 0x19 0x01 0x15 0x19 0x02>; reset-names = "axi\0cfg\0moncfg\0jd_cfg\0jd_axi\0vd_cfg\0vd_axi"; - eswin,syscfg = <0x17 0x00 0x04>; - operating-points-v2 = <0x31>; + eswin,syscfg = <0x14 0x00 0x04>; + operating-points-v2 = <0x2e>; vcmd-core = <0x00 0x6c>; axife-core = <0x200 0x100>; vdec-core = <0x800 0xc00>; interrupt-parent = <0x10>; #size-cells = <0x02>; dma-ranges = <0x00 0x00 0x00 0x80000000 0x200 0x00>; - iommus = <0x19 0x02>; + iommus = <0x16 0x02>; vccsr-reg = <0x00 0x501c0000 0x00 0x1000>; numa-node-id = <0x00>; tbus = <0x10 0x13>; @@ -2599,17 +2687,17 @@ compatible = "eswin,video-encoder0"; clocks = <0x03 0x254 0x03 0x255 0x03 0x256 0x03 0x258 0x03 0x2e 0x03 0x04 0x03 0x0a 0x03 0x2ad 0x03 0x2af 0x03 0x2b1>; clock-names = "aclk\0cfg_clk\0je_clk\0ve_clk\0vc_mux\0spll0_fout1\0spll2_fout1\0je_pclk\0ve_pclk\0mon_pclk"; - resets = <0x18 0x16 0x02 0x18 0x16 0x01 0x18 0x16 0x04 0x18 0x18 0x01 0x18 0x18 0x02 0x18 0x1a 0x02 0x18 0x1a 0x01>; + resets = <0x15 0x16 0x02 0x15 0x16 0x01 0x15 0x16 0x04 0x15 0x18 0x01 0x15 0x18 0x02 0x15 0x1a 0x02 0x15 0x1a 0x01>; reset-names = "axi\0cfg\0moncfg\0je_cfg\0je_axi\0ve_cfg\0ve_axi"; - eswin,syscfg = <0x17 0x00 0x04>; - operating-points-v2 = <0x32>; + eswin,syscfg = <0x14 0x00 0x04>; + operating-points-v2 = <0x2f>; vcmd-core = <0x00 0x6c>; axife-core = <0x2000 0x7d0>; venc-core = <0x1000 0x87c>; interrupt-parent = <0x10>; #size-cells = <0x02>; dma-ranges = <0x00 0x00 0x00 0x80000000 0x200 0x00>; - iommus = <0x19 0x03>; + iommus = <0x16 0x03>; vccsr-reg = <0x00 0x501c0000 0x00 0x1000>; numa-node-id = <0x00>; dma-noncoherent; @@ -2638,14 +2726,14 @@ #mbox-cells = <0x01>; clocks = <0x03 0x27e 0x03 0x27f>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x01 0x18 0x0c 0x02>; + resets = <0x15 0x0c 0x01 0x15 0x0c 0x02>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x02>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x33>; + phandle = <0x30>; }; mbox@50a20000 { @@ -2656,14 +2744,14 @@ #mbox-cells = <0x01>; clocks = <0x03 0x280 0x03 0x281>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x04 0x18 0x0c 0x08>; + resets = <0x15 0x0c 0x04 0x15 0x0c 0x08>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x04>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x34>; + phandle = <0x31>; }; mbox@50a40000 { @@ -2674,14 +2762,14 @@ #mbox-cells = <0x01>; clocks = <0x03 0x282 0x03 0x283>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x10 0x18 0x0c 0x20>; + resets = <0x15 0x0c 0x10 0x15 0x0c 0x20>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x08>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x21>; + phandle = <0x1e>; }; mbox@50a60000 { @@ -2692,7 +2780,7 @@ #mbox-cells = <0x01>; clocks = <0x03 0x284 0x03 0x285>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x40 0x18 0x0c 0x80>; + resets = <0x15 0x0c 0x40 0x15 0x0c 0x80>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x10>; @@ -2709,14 +2797,14 @@ #mbox-cells = <0x01>; clocks = <0x03 0x286 0x03 0x287>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x100 0x18 0x0c 0x200>; + resets = <0x15 0x0c 0x100 0x15 0x0c 0x200>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x20>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x26>; + phandle = <0x23>; }; mbox@50aa0000 { @@ -2727,14 +2815,14 @@ #mbox-cells = <0x01>; clocks = <0x03 0x288 0x03 0x289>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x400 0x18 0x0c 0x800>; + resets = <0x15 0x0c 0x400 0x15 0x0c 0x800>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x40>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x27>; + phandle = <0x24>; }; mbox@50ac0000 { @@ -2745,14 +2833,14 @@ #mbox-cells = <0x01>; clocks = <0x03 0x28a 0x03 0x28b>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x1000 0x18 0x0c 0x2000>; + resets = <0x15 0x0c 0x1000 0x15 0x0c 0x2000>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x80>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x28>; + phandle = <0x25>; }; mbox@50ae0000 { @@ -2763,24 +2851,24 @@ #mbox-cells = <0x01>; clocks = <0x03 0x28c 0x03 0x28d>; clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x18 0x0c 0x4000 0x18 0x0c 0x8000>; + resets = <0x15 0x0c 0x4000 0x15 0x0c 0x8000>; reset-names = "rst\0rst_device"; lock-bit = <0x01>; irq-bit = <0x100>; numa-node-id = <0x00>; dma-noncoherent; status = "okay"; - phandle = <0x29>; + phandle = <0x26>; }; ipc@0 { compatible = "eswin,win2030-ipc"; #size-cells = <0x02>; dma-ranges = <0x00 0x80000000 0x00 0xc0000000 0x00 0x80000000>; - iommus = <0x19 0x18 0x19 0x18>; + iommus = <0x16 0x18 0x16 0x18>; tbus = <0x04>; - eswin,syscfg = <0x17 0x1004 0x00 0x17 0x4004 0x00>; - mboxes = <0x33 0x00>; + eswin,syscfg = <0x14 0x1004 0x00 0x14 0x4004 0x00>; + mboxes = <0x30 0x00>; mbox-names = "u84_scpu"; numa-node-id = <0x00>; dma-noncoherent; @@ -2792,13 +2880,13 @@ clocks = <0x03 0x209 0x03 0x20a>; clock-names = "core_clk\0bus_clk"; reset-names = "core_rst\0bus_rst\0dbg_rst"; - resets = <0x18 0x15 0x01 0x18 0x15 0x02 0x18 0x15 0x04>; + resets = <0x15 0x15 0x01 0x15 0x15 0x02 0x15 0x15 0x04>; #size-cells = <0x02>; dma-ranges = <0x00 0xb0000000 0x00 0xc0000000 0x00 0x50000000>; - iommus = <0x19 0x19>; - eswin,syscfg = <0x17 0x2004 0x00>; + iommus = <0x16 0x19>; + eswin,syscfg = <0x14 0x2004 0x00>; tbus = <0x04>; - mboxes = <0x34 0x00>; + mboxes = <0x31 0x00>; mbox-names = "u84_lpcpu"; numa-node-id = <0x00>; status = "okay"; @@ -2809,7 +2897,7 @@ compatible = "eswin,eswin-pvt-cpu"; clocks = <0x03 0x25f>; clock-names = "pvt_clk"; - resets = <0x18 0x0b 0x01>; + resets = <0x15 0x0b 0x01>; reset-names = "pvt_rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2820,14 +2908,14 @@ status = "okay"; label = "pvt0"; numa-node-id = <0x00>; - phandle = <0x71>; + phandle = <0x68>; }; pvt@0x52360000 { compatible = "eswin,eswin-pvt-ddr"; clocks = <0x03 0x260>; clock-names = "pvt_clk"; - resets = <0x18 0x0b 0x02>; + resets = <0x15 0x0b 0x02>; reset-names = "pvt_rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2844,16 +2932,16 @@ reg = <0x00 0x50b50000 0x00 0x10000>; clocks = <0x03 0x2a7>; clock-names = "pclk"; - resets = <0x18 0x0a 0x01>; + resets = <0x15 0x0a 0x01>; reset-names = "fan_rst"; interrupt-parent = <0x10>; interrupt-names = "fanirq"; interrupts = <0x162>; pulses-per-revolution = <0x02>; pwm-minimum-period = <0x3e8>; - pwms = <0x35 0x00 0x186a0>; + pwms = <0x32 0x00 0x186a0>; pinctrl-names = "default"; - pinctrl-0 = <0x36 0x37>; + pinctrl-0 = <0x33 0x34>; status = "okay"; label = "fan_control"; numa-node-id = <0x00>; @@ -2865,7 +2953,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x28e>; clock-names = "pclk"; - resets = <0x18 0x09 0x01>; + resets = <0x15 0x09 0x01>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2881,16 +2969,16 @@ #sound-dai-cells = <0x00>; eswin-plat = <0x02>; pinctrl-names = "default"; - pinctrl-0 = <0x38 0x39>; - front-jack-gpios = <0x2e 0x00 0x00>; - back-jack-gpios = <0x2e 0x1c 0x00>; + pinctrl-0 = <0x35 0x36>; + front-jack-gpios = <0x2b 0x00 0x00>; + back-jack-gpios = <0x2b 0x1c 0x00>; port { endpoint { system-clock-frequency = <0xbb8000>; - remote-endpoint = <0x3a>; - phandle = <0x5a>; + remote-endpoint = <0x37>; + phandle = <0x57>; }; }; }; @@ -2901,7 +2989,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x28f>; clock-names = "pclk"; - resets = <0x18 0x09 0x02>; + resets = <0x15 0x09 0x02>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2917,7 +3005,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x290>; clock-names = "pclk"; - resets = <0x18 0x09 0x04>; + resets = <0x15 0x09 0x04>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2933,7 +3021,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x291>; clock-names = "pclk"; - resets = <0x18 0x09 0x08>; + resets = <0x15 0x09 0x08>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2947,10 +3035,10 @@ compatible = "fcs,fusb303b"; status = "okay"; reg = <0x21>; - eswin,syscfg = <0x17 0x3c0 0x0c>; + eswin,syscfg = <0x14 0x3c0 0x0c>; pinctrl-names = "default"; - pinctrl-0 = <0x3b>; - int-gpios = <0x2e 0x05 0x00>; + pinctrl-0 = <0x38>; + int-gpios = <0x2b 0x05 0x00>; connector { compatible = "usb-c-connector"; @@ -2965,7 +3053,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x292>; clock-names = "pclk"; - resets = <0x18 0x09 0x10>; + resets = <0x15 0x09 0x10>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2981,7 +3069,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x293>; clock-names = "pclk"; - resets = <0x18 0x09 0x20>; + resets = <0x15 0x09 0x20>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -2997,7 +3085,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x294>; clock-names = "pclk"; - resets = <0x18 0x09 0x40>; + resets = <0x15 0x09 0x40>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -3013,7 +3101,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x295>; clock-names = "pclk"; - resets = <0x18 0x09 0x80>; + resets = <0x15 0x09 0x80>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -3029,7 +3117,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x296>; clock-names = "pclk"; - resets = <0x18 0x09 0x100>; + resets = <0x15 0x09 0x100>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -3045,7 +3133,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x297>; clock-names = "pclk"; - resets = <0x18 0x09 0x200>; + resets = <0x15 0x09 0x200>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -3061,19 +3149,19 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x29f>; clock-names = "pclk"; - resets = <0x18 0x26 0x01>; + resets = <0x15 0x26 0x01>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; reg = <0x00 0x51830000 0x00 0x8000>; interrupts = <0x122>; interrupt-parent = <0x10>; - eswin,i2c_dma = <0x3c>; + eswin,i2c_dma = <0x39>; dma-names = "rx\0tx"; - dmas = <0x3c 0x29 0xff 0x3c 0x2a 0xff>; + dmas = <0x39 0x0a 0x29 0xff 0x39 0x0b 0x2a 0xff>; numa-node-id = <0x00>; status = "okay"; - eswin,syscfg = <0x17 0x3c0 0x10>; + eswin,syscfg = <0x14 0x3c0 0x10>; aon_eeprom@50 { compatible = "atmel,24c02"; @@ -3086,7 +3174,7 @@ clock-frequency = <0x186a0>; clocks = <0x03 0x2a0>; clock-names = "pclk"; - resets = <0x18 0x25 0x01>; + resets = <0x15 0x25 0x01>; reset-names = "rst"; #address-cells = <0x01>; #size-cells = <0x00>; @@ -3095,7 +3183,7 @@ interrupt-parent = <0x10>; numa-node-id = <0x00>; status = "okay"; - eswin,syscfg = <0x17 0x3c0 0x0f>; + eswin,syscfg = <0x14 0x3c0 0x0f>; i2c-sda-hold-time-ns = <0x40>; pmic@10 { @@ -3132,7 +3220,7 @@ regulator-min-microamp = <0x1312d00>; regulator-max-microamp = <0x2625a00>; regulator-ov-protection-microvolt = <0x10c8e0>; - phandle = <0x23>; + phandle = <0x20>; }; }; }; @@ -3144,11 +3232,11 @@ numa-node-id = <0x00>; status = "okay"; pinctrl-names = "default"; - pinctrl-0 = <0x3d 0x3e 0x3f 0x40 0x41 0x42 0x43 0x44 0x45 0x46 0x47 0x48 0x49 0x4a 0x4b 0x4c 0x4d 0x4e 0x4f 0x50 0x51 0x52 0x53 0x54 0x55 0x56 0x57 0x58>; - phandle = <0x1e>; + pinctrl-0 = <0x3a 0x3b 0x3c 0x3d 0x3e 0x3f 0x40 0x41 0x42 0x43 0x44 0x45 0x46 0x47 0x48 0x49 0x4a 0x4b 0x4c 0x4d 0x4e 0x4f 0x50 0x51 0x52 0x53 0x54 0x55>; + phandle = <0x1b>; pwm0-default { - phandle = <0x37>; + phandle = <0x34>; mux { groups = "pwm0_group"; @@ -3157,7 +3245,7 @@ }; fan_tach-default { - phandle = <0x36>; + phandle = <0x33>; mux { groups = "fan_tach_group"; @@ -3538,7 +3626,7 @@ }; sata_act_led-default { - phandle = <0x2c>; + phandle = <0x29>; mux { groups = "sata_act_led_group"; @@ -3553,7 +3641,7 @@ }; emmc_led_control-default { - phandle = <0x2d>; + phandle = <0x2a>; mux { groups = "emmc_led_control_group"; @@ -3648,7 +3736,7 @@ }; gpio0-default { - phandle = <0x38>; + phandle = <0x35>; mux { groups = "gpio0_group"; @@ -3695,7 +3783,7 @@ }; gpio5-default { - phandle = <0x3b>; + phandle = <0x38>; mux { groups = "gpio5_group"; @@ -3710,7 +3798,7 @@ }; gpio6-default { - phandle = <0x3d>; + phandle = <0x3a>; mux { groups = "gpio6_group"; @@ -3725,7 +3813,7 @@ }; gpio7-default { - phandle = <0x3e>; + phandle = <0x3b>; mux { groups = "gpio7_group"; @@ -3740,7 +3828,7 @@ }; gpio8-default { - phandle = <0x3f>; + phandle = <0x3c>; mux { groups = "gpio8_group"; @@ -3755,7 +3843,7 @@ }; gpio9-default { - phandle = <0x40>; + phandle = <0x3d>; mux { groups = "gpio9_group"; @@ -3770,7 +3858,7 @@ }; gpio10-default { - phandle = <0x41>; + phandle = <0x3e>; mux { groups = "gpio10_group"; @@ -3823,7 +3911,7 @@ }; gpio15-default { - phandle = <0x2f>; + phandle = <0x2c>; mux { groups = "gpio15_group"; @@ -3846,7 +3934,7 @@ }; gpio17-default { - phandle = <0x42>; + phandle = <0x3f>; mux { groups = "gpio17_group"; @@ -3930,6 +4018,12 @@ groups = "gpio23_group"; function = "gpio23_func"; }; + + conf { + groups = "gpio23_group"; + input-enable = <0x01>; + bias-pull-down = <0x01>; + }; }; gpio24-default { @@ -3965,7 +4059,7 @@ }; gpio28-default { - phandle = <0x39>; + phandle = <0x36>; mux { groups = "gpio28_group"; @@ -4028,7 +4122,7 @@ }; gpio35-default { - phandle = <0x43>; + phandle = <0x40>; mux { groups = "gpio35_group"; @@ -4043,7 +4137,7 @@ }; gpio36-default { - phandle = <0x44>; + phandle = <0x41>; mux { groups = "gpio36_group"; @@ -4058,7 +4152,7 @@ }; gpio37-default { - phandle = <0x45>; + phandle = <0x42>; mux { groups = "gpio37_group"; @@ -4073,7 +4167,7 @@ }; gpio38-default { - phandle = <0x46>; + phandle = <0x43>; mux { groups = "gpio38_group"; @@ -4088,7 +4182,7 @@ }; gpio39-default { - phandle = <0x47>; + phandle = <0x44>; mux { groups = "gpio39_group"; @@ -4103,7 +4197,7 @@ }; gpio40-default { - phandle = <0x48>; + phandle = <0x45>; mux { groups = "gpio40_group"; @@ -4118,7 +4212,7 @@ }; gpio41-default { - phandle = <0x49>; + phandle = <0x46>; mux { groups = "gpio41_group"; @@ -4141,7 +4235,7 @@ }; gpio43-default { - phandle = <0x69>; + phandle = <0x60>; mux { groups = "gpio43_group"; @@ -4166,7 +4260,7 @@ }; gpio46-default { - phandle = <0x4a>; + phandle = <0x47>; mux { groups = "gpio46_group"; @@ -4227,7 +4321,7 @@ }; gpio52-default { - phandle = <0x4b>; + phandle = <0x48>; mux { groups = "gpio52_group"; @@ -4242,7 +4336,7 @@ }; gpio53-default { - phandle = <0x4c>; + phandle = <0x49>; mux { groups = "gpio53_group"; @@ -4337,7 +4431,7 @@ }; gpio64-default { - phandle = <0x4d>; + phandle = <0x4a>; mux { groups = "gpio64_group"; @@ -4352,7 +4446,7 @@ }; gpio65-default { - phandle = <0x4e>; + phandle = <0x4b>; mux { groups = "gpio65_group"; @@ -4367,7 +4461,7 @@ }; gpio66-default { - phandle = <0x4f>; + phandle = <0x4c>; mux { groups = "gpio66_group"; @@ -4382,7 +4476,7 @@ }; gpio67-default { - phandle = <0x50>; + phandle = <0x4d>; mux { groups = "gpio67_group"; @@ -4413,7 +4507,7 @@ }; gpio70-default { - phandle = <0x51>; + phandle = <0x4e>; mux { groups = "gpio70_group"; @@ -4438,7 +4532,7 @@ }; gpio73-default { - phandle = <0x52>; + phandle = <0x4f>; mux { groups = "gpio73_group"; @@ -4487,7 +4581,7 @@ }; gpio79-default { - phandle = <0x30>; + phandle = <0x2d>; mux { groups = "gpio79_group"; @@ -4512,7 +4606,6 @@ }; gpio82-default { - phandle = <0x64>; mux { groups = "gpio82_group"; @@ -4521,7 +4614,7 @@ }; gpio83-default { - phandle = <0x53>; + phandle = <0x50>; mux { groups = "gpio83_group"; @@ -4538,7 +4631,6 @@ }; gpio85-default { - phandle = <0x65>; mux { groups = "gpio85_group"; @@ -4547,7 +4639,7 @@ }; gpio86-default { - phandle = <0x54>; + phandle = <0x51>; mux { groups = "gpio86_group"; @@ -4556,7 +4648,7 @@ }; gpio87-default { - phandle = <0x55>; + phandle = <0x52>; mux { groups = "gpio87_group"; @@ -4597,7 +4689,7 @@ }; gpio92-default { - phandle = <0x56>; + phandle = <0x53>; mux { groups = "gpio92_group"; @@ -4612,7 +4704,7 @@ }; gpio93-default { - phandle = <0x57>; + phandle = <0x54>; mux { groups = "gpio93_group"; @@ -4627,7 +4719,7 @@ }; gpio94-default { - phandle = <0x58>; + phandle = <0x55>; mux { groups = "gpio94_group"; @@ -4730,7 +4822,7 @@ }; gpio106-default { - phandle = <0x1c>; + phandle = <0x19>; mux { groups = "gpio106_group"; @@ -4801,7 +4893,7 @@ }; gpio111-default { - phandle = <0x20>; + phandle = <0x1d>; mux { groups = "gpio111_group"; @@ -4922,7 +5014,7 @@ interrupt-controller; #interrupt-cells = <0x02>; interrupts = <0x12f 0x130 0x131 0x132 0x133 0x134 0x135 0x136 0x137 0x138 0x139 0x13a 0x13b 0x13c 0x13d 0x13e 0x13f 0x140 0x141 0x142 0x143 0x144 0x145 0x146 0x147 0x148 0x149 0x14a 0x14b 0x14c 0x14d 0x14e>; - phandle = <0x2e>; + phandle = <0x2b>; }; gpio-port@1 { @@ -4931,7 +5023,7 @@ #gpio-cells = <0x02>; ngpios = <0x20>; reg = <0x01>; - phandle = <0x6a>; + phandle = <0x61>; }; gpio-port@2 { @@ -4940,7 +5032,7 @@ #gpio-cells = <0x02>; ngpios = <0x20>; reg = <0x02>; - phandle = <0x16>; + phandle = <0x13>; }; gpio-port@3 { @@ -4949,7 +5041,7 @@ #gpio-cells = <0x02>; ngpios = <0x10>; reg = <0x03>; - phandle = <0x1d>; + phandle = <0x1a>; }; }; @@ -4960,11 +5052,11 @@ clock-names = "pclk"; clocks = <0x03 0x2a6>; clock-frequency = <0xbebc200>; - resets = <0x18 0x0f 0x01>; + resets = <0x15 0x0f 0x01>; reset-names = "rst"; status = "okay"; numa-node-id = <0x00>; - phandle = <0x35>; + phandle = <0x32>; }; watchdog@0x50800000 { @@ -4972,7 +5064,7 @@ reg = <0x00 0x50800000 0x00 0x4000>; clocks = <0x03 0x298>; clock-names = "pclk"; - resets = <0x18 0x11 0x01>; + resets = <0x15 0x11 0x01>; reset-names = "rst"; interrupts = <0x57>; interrupt-parent = <0x10>; @@ -4985,7 +5077,7 @@ reg = <0x00 0x50804000 0x00 0x4000>; clocks = <0x03 0x299>; clock-names = "pclk"; - resets = <0x18 0x11 0x02>; + resets = <0x15 0x11 0x02>; reset-names = "rst"; interrupts = <0x58>; interrupt-parent = <0x10>; @@ -4998,7 +5090,7 @@ reg = <0x00 0x50808000 0x00 0x4000>; clocks = <0x03 0x29a>; clock-names = "pclk"; - resets = <0x18 0x11 0x04>; + resets = <0x15 0x11 0x04>; reset-names = "rst"; interrupts = <0x59>; interrupt-parent = <0x10>; @@ -5011,7 +5103,7 @@ reg = <0x00 0x5080c000 0x00 0x4000>; clocks = <0x03 0x29b>; clock-names = "pclk"; - resets = <0x18 0x11 0x08>; + resets = <0x15 0x11 0x08>; reset-names = "rst"; interrupts = <0x5a>; interrupt-parent = <0x10>; @@ -5030,7 +5122,7 @@ interrupts = <0x159>; clock-names = "pclk\0timer_aclk"; clocks = <0x03 0x26c 0x03 0x268>; - resets = <0x18 0x30 0x01 0x18 0x30 0x02 0x18 0x30 0x04 0x18 0x30 0x08 0x18 0x30 0x10 0x18 0x30 0x20 0x18 0x30 0x40 0x18 0x30 0x80 0x18 0x30 0x100>; + resets = <0x15 0x30 0x01 0x15 0x30 0x02 0x15 0x30 0x04 0x15 0x30 0x08 0x15 0x30 0x10 0x15 0x30 0x20 0x15 0x30 0x40 0x15 0x30 0x80 0x15 0x30 0x100>; reset-names = "trst0\0trst1\0trst2\0trst3\0trst4\0trst5\0trst6\0trst7\0prst"; status = "okay"; }; @@ -5045,7 +5137,7 @@ interrupts = <0x15a>; clock-names = "pclk\0timer_aclk"; clocks = <0x03 0x26d 0x03 0x269>; - resets = <0x18 0x31 0x01 0x18 0x31 0x02 0x18 0x31 0x04 0x18 0x31 0x08 0x18 0x31 0x10 0x18 0x31 0x20 0x18 0x31 0x40 0x18 0x31 0x80 0x18 0x31 0x100>; + resets = <0x15 0x31 0x01 0x15 0x31 0x02 0x15 0x31 0x04 0x15 0x31 0x08 0x15 0x31 0x10 0x15 0x31 0x20 0x15 0x31 0x40 0x15 0x31 0x80 0x15 0x31 0x100>; reset-names = "trst0\0trst1\0trst2\0trst3\0trst4\0trst5\0trst6\0trst7\0prst"; status = "okay"; }; @@ -5060,7 +5152,7 @@ interrupts = <0x15b>; clock-names = "pclk\0timer_aclk"; clocks = <0x03 0x26e 0x03 0x26a>; - resets = <0x18 0x32 0x01 0x18 0x32 0x02 0x18 0x32 0x04 0x18 0x32 0x08 0x18 0x32 0x10 0x18 0x32 0x20 0x18 0x32 0x40 0x18 0x32 0x80 0x18 0x32 0x100>; + resets = <0x15 0x32 0x01 0x15 0x32 0x02 0x15 0x32 0x04 0x15 0x32 0x08 0x15 0x32 0x10 0x15 0x32 0x20 0x15 0x32 0x40 0x15 0x32 0x80 0x15 0x32 0x100>; reset-names = "trst0\0trst1\0trst2\0trst3\0trst4\0trst5\0trst6\0trst7\0prst"; status = "okay"; }; @@ -5075,7 +5167,7 @@ interrupts = <0x15c>; clock-names = "pclk\0timer_aclk\0timer3_clk8"; clocks = <0x03 0x26f 0x03 0x26b 0x03 0x270>; - resets = <0x18 0x33 0x01 0x18 0x33 0x02 0x18 0x33 0x04 0x18 0x33 0x08 0x18 0x33 0x10 0x18 0x33 0x20 0x18 0x33 0x40 0x18 0x33 0x80 0x18 0x33 0x100>; + resets = <0x15 0x33 0x01 0x15 0x33 0x02 0x15 0x33 0x04 0x15 0x33 0x08 0x15 0x33 0x10 0x15 0x33 0x20 0x15 0x33 0x40 0x15 0x33 0x80 0x15 0x33 0x100>; reset-names = "trst0\0trst1\0trst2\0trst3\0trst4\0trst5\0trst6\0trst7\0prst"; status = "okay"; }; @@ -5083,13 +5175,13 @@ rtc@51818000 { compatible = "eswin,win2030-rtc"; reg = <0x00 0x51818000 0x00 0x400>; - eswin,syscfg = <0x17 0x3c0>; + eswin,syscfg = <0x14 0x3c0>; interrupt-parent = <0x10>; interrupts = <0x124>; clocks = <0x03 0x272>; clock-names = "rtcclk"; clock-frequency = <0x3d09>; - resets = <0x18 0x34 0x01>; + resets = <0x15 0x34 0x01>; reset-names = "rtcrst"; status = "okay"; numa-node-id = <0x00>; @@ -5104,21 +5196,21 @@ #sound-dai-cells = <0x00>; reg = <0x00 0x50200000 0x00 0x10000>; dma-names = "rx\0tx"; - dmas = <0x3c 0x04 0x00 0x3c 0x05 0x00>; - vo_mclk_sel,syscrg = <0x15 0x1bc>; - resets = <0x18 0x22 0x01 0x18 0x22 0x02 0x18 0x21 0x02>; + dmas = <0x39 0x04 0x04 0x00 0x39 0x05 0x05 0x00>; + vo_mclk_sel,syscrg = <0x12 0x1bc>; + resets = <0x15 0x22 0x01 0x15 0x22 0x02 0x15 0x21 0x02>; reset-names = "i2srst\0i2sprst\0voprst"; dma-noncoherent; numa-node-id = <0x00>; status = "okay"; port { - phandle = <0x5c>; + phandle = <0x59>; endpoint { - remote-endpoint = <0x59>; + remote-endpoint = <0x56>; dai-format = "i2s"; - phandle = <0x68>; + phandle = <0x5f>; }; }; }; @@ -5132,21 +5224,21 @@ #sound-dai-cells = <0x00>; reg = <0x00 0x50210000 0x00 0x10000>; dma-names = "rx\0tx"; - dmas = <0x3c 0x02 0x01 0x3c 0x03 0x01>; - vo_mclk_sel,syscrg = <0x15 0x1bc>; - resets = <0x18 0x22 0x01 0x18 0x22 0x02 0x18 0x21 0x02>; + dmas = <0x39 0x06 0x02 0x01 0x39 0x07 0x03 0x01>; + vo_mclk_sel,syscrg = <0x12 0x1bc>; + resets = <0x15 0x22 0x01 0x15 0x22 0x02 0x15 0x21 0x02>; reset-names = "i2srst\0i2sprst\0voprst"; dma-noncoherent; numa-node-id = <0x00>; status = "okay"; port { - phandle = <0x5b>; + phandle = <0x58>; endpoint { - remote-endpoint = <0x5a>; + remote-endpoint = <0x57>; dai-format = "i2s"; - phandle = <0x3a>; + phandle = <0x37>; }; }; }; @@ -5160,9 +5252,9 @@ #sound-dai-cells = <0x00>; reg = <0x00 0x50220000 0x00 0x10000>; dma-names = "rx\0tx"; - dmas = <0x3c 0x00 0x02 0x3c 0x01 0x02>; - vo_mclk_sel,syscrg = <0x15 0x1bc>; - resets = <0x18 0x22 0x01 0x18 0x22 0x02 0x18 0x21 0x02>; + dmas = <0x39 0x08 0x00 0x02 0x39 0x09 0x01 0x02>; + vo_mclk_sel,syscrg = <0x12 0x1bc>; + resets = <0x15 0x22 0x01 0x15 0x22 0x02 0x15 0x21 0x02>; reset-names = "i2srst\0i2sprst\0voprst"; dma-noncoherent; numa-node-id = <0x00>; @@ -5180,7 +5272,7 @@ numa-node-id = <0x00>; status = "okay"; label = "Analog Audio"; - dais = <0x5b>; + dais = <0x58>; }; graphcard1 { @@ -5188,7 +5280,7 @@ numa-node-id = <0x00>; status = "okay"; label = "HDMI Audio"; - dais = <0x5c>; + dais = <0x59>; }; graphcard2 { @@ -5199,8 +5291,8 @@ display-subsystem@0 { compatible = "eswin,display-subsystem"; - ports = <0x5d>; numa-node-id = <0x00>; + ports = <0x5a>; dma-noncoherent; status = "okay"; }; @@ -5218,7 +5310,7 @@ interrupts = <0xee>; clocks = <0x03 0x24d 0x03 0x24f 0x03 0x24c 0x03 0x04 0x03 0x2a 0x03 0x2b 0x03 0x0b 0x03 0x0d>; clock-names = "cfg_clk\0pix_clk\0axi_clk\0spll0_fout1\0vo_mux\0pix_mux\0spll2_fout2\0vpll_fout1"; - resets = <0x18 0x23 0x01 0x18 0x23 0x02 0x18 0x23 0x04 0x18 0x23 0x08>; + resets = <0x15 0x23 0x01 0x15 0x23 0x02 0x15 0x23 0x04 0x15 0x23 0x08>; reset-names = "vo_arst\0vo_prst\0dc_arst\0dc_prst"; dma-noncoherent; numa-node-id = <0x00>; @@ -5227,24 +5319,18 @@ port { #address-cells = <0x01>; #size-cells = <0x00>; - phandle = <0x5d>; - - endpoint@0 { - reg = <0x00>; - remote-endpoint = <0x5e>; - phandle = <0x62>; - }; + phandle = <0x5a>; endpoint@1 { reg = <0x01>; - remote-endpoint = <0x5f>; - phandle = <0x61>; + remote-endpoint = <0x5b>; + phandle = <0x5d>; }; endpoint@2 { reg = <0x02>; - remote-endpoint = <0x60>; - phandle = <0x67>; + remote-endpoint = <0x5c>; + phandle = <0x5e>; }; }; }; @@ -5258,8 +5344,8 @@ port { endpoint { - remote-endpoint = <0x61>; - phandle = <0x5f>; + remote-endpoint = <0x5d>; + phandle = <0x5b>; }; }; }; @@ -5277,57 +5363,10 @@ reg = <0x00 0x50270000 0x00 0x10000>; clocks = <0x03 0x201>; clock-names = "pclk"; - resets = <0x18 0x21 0x01>; + resets = <0x15 0x21 0x01>; reset-names = "phyrstn"; numa-node-id = <0x00>; status = "okay"; - - ports { - #address-cells = <0x01>; - #size-cells = <0x00>; - - port@0 { - #address-cells = <0x01>; - #size-cells = <0x00>; - reg = <0x00>; - - endpoint { - remote-endpoint = <0x62>; - phandle = <0x5e>; - }; - }; - - port@1 { - #address-cells = <0x01>; - #size-cells = <0x00>; - reg = <0x01>; - - endpoint { - remote-endpoint = <0x63>; - phandle = <0x66>; - }; - }; - }; - - dsi_panel@0 { - compatible = "eswin,generic-panel"; - reg = <0x00>; - dsi,format = <0x00>; - dsi,lanes = <0x04>; - status = "okay"; - pinctrl-names = "default"; - pinctrl-0 = <0x64 0x65>; - backlight0-gpios = <0x16 0x12 0x00>; - rst-gpios = <0x16 0x15 0x00>; - - port { - - endpoint { - remote-endpoint = <0x66>; - phandle = <0x63>; - }; - }; - }; }; dctest@502c0000 { @@ -5351,7 +5390,7 @@ ddc-i2c-scl-high-time-ns = <0x1264>; ddc-i2c-scl-low-time-ns = <0x1334>; #sound-dai-cells = <0x00>; - resets = <0x18 0x21 0x08 0x18 0x21 0x10 0x18 0x21 0x20>; + resets = <0x15 0x21 0x08 0x15 0x21 0x10 0x15 0x21 0x20>; reset-names = "prstn\0phyrstn\0rstn"; numa-node-id = <0x00>; status = "okay"; @@ -5364,8 +5403,8 @@ reg = <0x00>; endpoint@0 { - remote-endpoint = <0x67>; - phandle = <0x60>; + remote-endpoint = <0x5e>; + phandle = <0x5c>; }; }; @@ -5374,8 +5413,8 @@ endpoint@1 { system-clock-frequency = <0xbb8000>; - remote-endpoint = <0x68>; - phandle = <0x59>; + remote-endpoint = <0x5f>; + phandle = <0x56>; }; }; }; @@ -5399,8 +5438,8 @@ #size-cells = <0x02>; clocks = <0x03 0x10e 0x03 0x221 0x03 0x222>; clock-names = "suspend\0aclk\0cfg_clk"; - eswin,hsp_sp_csr = <0x1a 0x800 0x808 0x83c 0x840>; - resets = <0x18 0x07 0x8000>; + eswin,hsp_sp_csr = <0x17 0x800 0x808 0x83c 0x840>; + resets = <0x15 0x07 0x8000>; reset-names = "vaux"; ranges; numa-node-id = <0x00>; @@ -5417,8 +5456,8 @@ dr_mode = "host"; phy_type = "utmi"; maximum-speed = "super-speed"; - iommus = <0x19 0x0a>; - eswin,hsp_sp_csr = <0x1a 0x1044>; + iommus = <0x16 0x0a>; + eswin,hsp_sp_csr = <0x17 0x1044>; dma-ranges = <0x00 0x00 0x00 0xc0000000 0x200 0x00>; snps,dis_enblslpm_quirk; snps,dis-u2-freeclk-exists-quirk; @@ -5438,8 +5477,8 @@ #size-cells = <0x02>; clocks = <0x03 0x10f 0x03 0x221 0x03 0x222>; clock-names = "suspend\0aclk\0cfg_clk"; - eswin,hsp_sp_csr = <0x1a 0x900 0x908 0x93c 0x940>; - resets = <0x18 0x07 0x10000>; + eswin,hsp_sp_csr = <0x17 0x900 0x908 0x93c 0x940>; + resets = <0x15 0x07 0x10000>; reset-names = "vaux"; ranges; numa-node-id = <0x00>; @@ -5456,8 +5495,8 @@ dr_mode = "host"; phy_type = "utmi"; maximum-speed = "super-speed"; - iommus = <0x19 0x0b>; - eswin,hsp_sp_csr = <0x1a 0x1048>; + iommus = <0x16 0x0b>; + eswin,hsp_sp_csr = <0x17 0x1048>; dma-ranges = <0x00 0x00 0x00 0xc0000000 0x200 0x00>; snps,dis_enblslpm_quirk; snps,dis-u2-freeclk-exists-quirk; @@ -5472,8 +5511,8 @@ usb-hub { gpio-hog; pinctrl-names = "default"; - pinctrl-0 = <0x69>; - gpios = <0x6a 0x0b 0x00>; + pinctrl-0 = <0x60>; + gpios = <0x61 0x0b 0x00>; output-low; line-name = "usb-hub-reset"; }; @@ -5484,7 +5523,7 @@ compatible = "esw,vi-common-csr\0syscon"; clocks = <0x03 0x23f 0x03 0x241 0x03 0x243 0x03 0x240 0x03 0x24b 0x03 0x24a 0x03 0x244 0x03 0x245 0x03 0x246 0x03 0x247 0x03 0x248 0x03 0x249 0x03 0x27 0x03 0x28 0x03 0x29 0x03 0x04 0x03 0x0d>; clock-names = "aclk\0cfg_clk\0isp_aclk\0dvp_clk\0phy_cfg\0phy_escclk\0sht0\0sht1\0sht2\0sht3\0sht4\0sht5\0aclk_mux\0dvp_mux\0isp_mux\0spll0_fout1\0vpll_fout1"; - resets = <0x18 0x1c 0x01 0x18 0x1c 0x02 0x18 0x1e 0x01 0x18 0x1f 0x01 0x18 0x1d 0x01 0x18 0x20 0x01 0x18 0x20 0x02 0x18 0x20 0x04 0x18 0x20 0x08 0x18 0x20 0x10 0x18 0x20 0x20>; + resets = <0x15 0x1c 0x01 0x15 0x1c 0x02 0x15 0x1e 0x01 0x15 0x1f 0x01 0x15 0x1d 0x01 0x15 0x20 0x01 0x15 0x20 0x02 0x15 0x20 0x04 0x15 0x20 0x08 0x15 0x20 0x10 0x15 0x20 0x20>; reset-names = "axi\0cfg\0isp0\0isp1\0dvp\0sht0\0sht1\0sht2\0sht3\0sht4\0sht5"; interrupt-parent = <0x10>; interrupts = <0x170 0x171 0x172 0x173 0x174 0x175 0x176 0x177>; @@ -5492,7 +5531,8 @@ #size-cells = <0x02>; reg = <0x00 0x51030000 0x00 0x10000>; numa-node-id = <0x00>; - phandle = <0x6b>; + tbus = <0x00>; + phandle = <0x62>; }; isp@0x51000000 { @@ -5503,9 +5543,9 @@ id = <0x00>; #size-cells = <0x02>; dma-ranges = <0x00 0x20000000 0x00 0x80000000 0x00 0x40000000>; - iommus = <0x19 0x06>; + iommus = <0x16 0x06>; tbus = <0x00>; - eswin,vi_top_csr = <0x6b 0x1000>; + eswin,vi_top_csr = <0x62 0x1000>; numa-node-id = <0x00>; dma-noncoherent; status = "disabled"; @@ -5519,9 +5559,9 @@ id = <0x01>; #size-cells = <0x02>; dma-ranges = <0x00 0x20000000 0x00 0x80000000 0x00 0x40000000>; - iommus = <0x19 0x06>; + iommus = <0x16 0x06>; tbus = <0x00>; - eswin,vi_top_csr = <0x6b 0x1004>; + eswin,vi_top_csr = <0x62 0x1004>; numa-node-id = <0x00>; dma-noncoherent; status = "disabled"; @@ -5531,16 +5571,16 @@ compatible = "eswin,dewarp"; clocks = <0x03 0x23f 0x03 0x241 0x03 0x242 0x03 0x27 0x03 0x54 0x03 0x04 0x03 0x0d>; clock-names = "aclk\0cfg_clk\0dw_aclk\0aclk_mux\0dw_mux\0spll0_fout1\0vpll_fout1"; - resets = <0x18 0x1c 0x01 0x18 0x1c 0x02 0x18 0x1c 0x04>; + resets = <0x15 0x1c 0x01 0x15 0x1c 0x02 0x15 0x1c 0x04>; reset-names = "axi\0cfg\0dwe"; - operating-points-v2 = <0x6c>; + operating-points-v2 = <0x63>; interrupt-parent = <0x10>; interrupts = <0x1a 0x19>; #size-cells = <0x02>; dma-ranges = <0x00 0x20000000 0x00 0x80000000 0x00 0x40000000>; - iommus = <0x19 0x08>; + iommus = <0x16 0x08>; tbus = <0x00>; - eswin,vi_top_csr = <0x6b 0x1008>; + eswin,vi_top_csr = <0x62 0x1008>; reg = <0x00 0x51020000 0x00 0xc00 0x00 0x51020c00 0x00 0x120>; numa-node-id = <0x00>; dma-noncoherent; @@ -5573,8 +5613,8 @@ endpoint@0 { reg = <0x00>; bus-type = <0x04>; - remote-endpoint = <0x6d>; - phandle = <0x6f>; + remote-endpoint = <0x64>; + phandle = <0x66>; }; }; }; @@ -5594,8 +5634,8 @@ endpoint@0 { reg = <0x00>; bus-type = <0x04>; - remote-endpoint = <0x6e>; - phandle = <0x70>; + remote-endpoint = <0x65>; + phandle = <0x67>; }; }; }; @@ -5624,8 +5664,8 @@ bus-type = <0x04>; clock-lanes = <0x00>; data-lanes = <0x01 0x02>; - remote-endpoint = <0x6f>; - phandle = <0x6d>; + remote-endpoint = <0x66>; + phandle = <0x64>; }; }; }; @@ -5652,8 +5692,8 @@ endpoint { bus-type = <0x04>; - remote-endpoint = <0x70>; - phandle = <0x6e>; + remote-endpoint = <0x67>; + phandle = <0x65>; }; }; }; @@ -5664,7 +5704,7 @@ #size-cells = <0x02>; ranges; dma-ranges = <0x00 0x80000000 0x00 0xc0000000 0x00 0x80000000>; - iommus = <0x19 0x18>; + iommus = <0x16 0x18>; tbus = <0xf00>; numa-node-id = <0x00>; status = "disabled"; @@ -5710,12 +5750,12 @@ polling-delay-passive = <0x1f4>; polling-delay = <0x1388>; sustainable-power = <0x4b0>; - thermal-sensors = <0x71>; + thermal-sensors = <0x68>; trips { trip-point2 { - temperature = <0x1adb0>; + temperature = <0x19a28>; hysteresis = <0x00>; type = "critical"; }; @@ -5733,6 +5773,7 @@ }; chosen { + bootargs = "root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 console=ttyS0,115200 root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 rootfstype=ext4 rootwait rw earlycon selinux=0 LANG=en_US.UTF-8 init=/bin/bash"; stdout-path = "serial0:115200n8"; domain-config { @@ -5770,7 +5811,7 @@ sprammemory@59000000 { no-map; reg = <0x00 0x59000000 0x00 0x400000>; - phandle = <0x24>; + phandle = <0x21>; }; g2d_4GB_boundary_reserved_4k { diff --git a/platform/riscv64/hifive-premier-p550/image/dts/minimal.dts b/platform/riscv64/hifive-premier-p550/image/dts/minimal.dts index 8d31e015..71bf9dba 100644 --- a/platform/riscv64/hifive-premier-p550/image/dts/minimal.dts +++ b/platform/riscv64/hifive-premier-p550/image/dts/minimal.dts @@ -447,105 +447,6 @@ dsp@0 { }; }; - - es_dsp@1 { - #address-cells = <0x01>; - #size-cells = <0x01>; - compatible = "eswin-dsp\0cdns,xrp-hw-eswin"; - ranges = <0x28000000 0x00 0x5b008000 0x8000 0x28100000 0x00 0x5b140000 0x20000 0x28120000 0x00 0x5b160000 0x20000>; - clocks = <0x03 0x2a9>; - clock-names = "aclk"; - operating-points-v2 = <0x22>; - dsp_mbox = <0x24>; - device-irq = <0x0d 0x50ab0000 0x40 0x50aa0000 0x01 0x50a40000>; - device-uart = <0x50900000>; - device-irq-mode = <0x01>; - host-irq-mode = <0x01>; - firmware-name = "eic7700_dsp_fw"; - process-id = <0x01>; - iommus = <0x16 0x13>; - tbus = <0x71>; - dma-noncoherent; - numa-node-id = <0x00>; - aux-e31-dtim = <0x5a110000>; - status = "okay"; - - dsp@0 { - }; - }; - - es_dsp@2 { - #address-cells = <0x01>; - #size-cells = <0x01>; - compatible = "eswin-dsp\0cdns,xrp-hw-eswin"; - ranges = <0x28000000 0x00 0x5b010000 0x8000 0x28100000 0x00 0x5b180000 0x20000 0x28120000 0x00 0x5b1a0000 0x20000>; - clocks = <0x03 0x2aa>; - clock-names = "aclk"; - operating-points-v2 = <0x22>; - dsp_mbox = <0x25>; - device-irq = <0x0f 0x50ad0000 0x80 0x50ac0000 0x01 0x50a40000>; - device-uart = <0x50900000>; - device-irq-mode = <0x01>; - host-irq-mode = <0x01>; - firmware-name = "eic7700_dsp_fw"; - process-id = <0x02>; - iommus = <0x16 0x14>; - tbus = <0x72>; - dma-noncoherent; - numa-node-id = <0x00>; - aux-e31-dtim = <0x5a110000>; - status = "okay"; - - dsp@0 { - }; - }; - - es_dsp@3 { - #address-cells = <0x01>; - #size-cells = <0x01>; - compatible = "eswin-dsp\0cdns,xrp-hw-eswin"; - ranges = <0x28000000 0x00 0x5b018000 0x8000 0x28100000 0x00 0x5b1c0000 0x20000 0x28120000 0x00 0x5b1e0000 0x20000>; - clocks = <0x03 0x2ab>; - clock-names = "aclk"; - operating-points-v2 = <0x22>; - dsp_mbox = <0x26>; - device-irq = <0x11 0x50af0000 0x100 0x50ae0000 0x01 0x50a40000>; - device-uart = <0x50900000>; - device-irq-mode = <0x01>; - host-irq-mode = <0x01>; - firmware-name = "eic7700_dsp_fw"; - process-id = <0x03>; - iommus = <0x16 0x15>; - tbus = <0x73>; - dma-noncoherent; - numa-node-id = <0x00>; - aux-e31-dtim = <0x5a110000>; - status = "okay"; - - dsp@0 { - }; - }; - - sofdsp@4 { - #sound-dai-cells = <0x01>; - #address-cells = <0x02>; - #size-cells = <0x02>; - compatible = "eswin,sof-dsp"; - reg = <0x00 0x5b018000 0x00 0x8000 0x00 0x5b1c0000 0x00 0x40000>; - mbox-names = "dsp-mbox"; - mboxes = <0x26 0x00>; - clocks = <0x03 0x2ab>; - clock-names = "aclk"; - process-id = <0x03>; - iommus = <0x16 0x15>; - tbus = <0x73>; - dma-noncoherent; - mailbox-dsp-to-u84-addr = <0x50af0000>; - mailbox-u84-to-dsp-addr = <0x50ae0000>; - dsp-uart = <0x27>; - device-uart-mutex = <0x51820000>; - numa-node-id = <0x00>; - }; }; mmc@0x50460000 { @@ -581,42 +482,6 @@ no-mmc; }; - mbox@50a00000 { - compatible = "eswin,win2030-mailbox"; - reg = <0x00 0x50a00000 0x00 0x10000 0x00 0x50a10000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x75>; - #mbox-cells = <0x01>; - clocks = <0x03 0x27e 0x03 0x27f>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x01 0x15 0x0c 0x02>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x02>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x30>; - }; - - mbox@50a20000 { - compatible = "eswin,win2030-mailbox"; - reg = <0x00 0x50a20000 0x00 0x10000 0x00 0x50a30000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x77>; - #mbox-cells = <0x01>; - clocks = <0x03 0x280 0x03 0x281>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x04 0x15 0x0c 0x08>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x04>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x31>; - }; - mbox@50a40000 { compatible = "eswin,npu0-mailbox"; reg = <0x00 0x50a40000 0x00 0x10000 0x00 0x50a50000 0x00 0x10000>; @@ -670,60 +535,6 @@ phandle = <0x23>; }; - mbox@50aa0000 { - compatible = "eswin,dsp1-mailbox"; - reg = <0x00 0x50aa0000 0x00 0x10000 0x00 0x50ab0000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x7f>; - #mbox-cells = <0x01>; - clocks = <0x03 0x288 0x03 0x289>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x400 0x15 0x0c 0x800>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x40>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x24>; - }; - - mbox@50ac0000 { - compatible = "eswin,dsp2-mailbox"; - reg = <0x00 0x50ac0000 0x00 0x10000 0x00 0x50ad0000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x81>; - #mbox-cells = <0x01>; - clocks = <0x03 0x28a 0x03 0x28b>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x1000 0x15 0x0c 0x2000>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x80>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x25>; - }; - - mbox@50ae0000 { - compatible = "eswin,dsp3-mailbox"; - reg = <0x00 0x50ae0000 0x00 0x10000 0x00 0x50af0000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x83>; - #mbox-cells = <0x01>; - clocks = <0x03 0x28c 0x03 0x28d>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x4000 0x15 0x0c 0x8000>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x100>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x26>; - }; - i2c@51838000 { compatible = "snps,designware-i2c"; clock-frequency = <0x186a0>; @@ -769,13 +580,8 @@ }; chosen { - bootargs = "root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 console=ttyS0,115200 root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 rootfstype=ext4 rootwait rw earlycon selinux=0 LANG=en_US.UTF-8"; + bootargs = "root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 console=ttyS0,115200 root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 rootfstype=ext4 rootwait rw earlycon selinux=0 LANG=en_US.UTF-8 init=/bin/bash"; stdout-path = "serial0:115200n8"; - - domain-config { - compatible = "opensbi,domain,config"; - system-suspend-test; - }; }; memory@80000000 { diff --git a/platform/riscv64/hifive-premier-p550/image/dts/zone0-npu.dts b/platform/riscv64/hifive-premier-p550/image/dts/zone0-npu.dts index 8c5b65fa..22822015 100644 --- a/platform/riscv64/hifive-premier-p550/image/dts/zone0-npu.dts +++ b/platform/riscv64/hifive-premier-p550/image/dts/zone0-npu.dts @@ -300,105 +300,6 @@ dsp@0 { }; }; - - es_dsp@1 { - #address-cells = <0x01>; - #size-cells = <0x01>; - compatible = "eswin-dsp\0cdns,xrp-hw-eswin"; - ranges = <0x28000000 0x00 0x5b008000 0x8000 0x28100000 0x00 0x5b140000 0x20000 0x28120000 0x00 0x5b160000 0x20000>; - clocks = <0x03 0x2a9>; - clock-names = "aclk"; - operating-points-v2 = <0x22>; - dsp_mbox = <0x24>; - device-irq = <0x0d 0x50ab0000 0x40 0x50aa0000 0x01 0x50a40000>; - device-uart = <0x50900000>; - device-irq-mode = <0x01>; - host-irq-mode = <0x01>; - firmware-name = "eic7700_dsp_fw"; - process-id = <0x01>; - iommus = <0x16 0x13>; - tbus = <0x71>; - dma-noncoherent; - numa-node-id = <0x00>; - aux-e31-dtim = <0x5a110000>; - status = "okay"; - - dsp@0 { - }; - }; - - es_dsp@2 { - #address-cells = <0x01>; - #size-cells = <0x01>; - compatible = "eswin-dsp\0cdns,xrp-hw-eswin"; - ranges = <0x28000000 0x00 0x5b010000 0x8000 0x28100000 0x00 0x5b180000 0x20000 0x28120000 0x00 0x5b1a0000 0x20000>; - clocks = <0x03 0x2aa>; - clock-names = "aclk"; - operating-points-v2 = <0x22>; - dsp_mbox = <0x25>; - device-irq = <0x0f 0x50ad0000 0x80 0x50ac0000 0x01 0x50a40000>; - device-uart = <0x50900000>; - device-irq-mode = <0x01>; - host-irq-mode = <0x01>; - firmware-name = "eic7700_dsp_fw"; - process-id = <0x02>; - iommus = <0x16 0x14>; - tbus = <0x72>; - dma-noncoherent; - numa-node-id = <0x00>; - aux-e31-dtim = <0x5a110000>; - status = "okay"; - - dsp@0 { - }; - }; - - es_dsp@3 { - #address-cells = <0x01>; - #size-cells = <0x01>; - compatible = "eswin-dsp\0cdns,xrp-hw-eswin"; - ranges = <0x28000000 0x00 0x5b018000 0x8000 0x28100000 0x00 0x5b1c0000 0x20000 0x28120000 0x00 0x5b1e0000 0x20000>; - clocks = <0x03 0x2ab>; - clock-names = "aclk"; - operating-points-v2 = <0x22>; - dsp_mbox = <0x26>; - device-irq = <0x11 0x50af0000 0x100 0x50ae0000 0x01 0x50a40000>; - device-uart = <0x50900000>; - device-irq-mode = <0x01>; - host-irq-mode = <0x01>; - firmware-name = "eic7700_dsp_fw"; - process-id = <0x03>; - iommus = <0x16 0x15>; - tbus = <0x73>; - dma-noncoherent; - numa-node-id = <0x00>; - aux-e31-dtim = <0x5a110000>; - status = "okay"; - - dsp@0 { - }; - }; - - sofdsp@4 { - #sound-dai-cells = <0x01>; - #address-cells = <0x02>; - #size-cells = <0x02>; - compatible = "eswin,sof-dsp"; - reg = <0x00 0x5b018000 0x00 0x8000 0x00 0x5b1c0000 0x00 0x40000>; - mbox-names = "dsp-mbox"; - mboxes = <0x26 0x00>; - clocks = <0x03 0x2ab>; - clock-names = "aclk"; - process-id = <0x03>; - iommus = <0x16 0x15>; - tbus = <0x73>; - dma-noncoherent; - mailbox-dsp-to-u84-addr = <0x50af0000>; - mailbox-u84-to-dsp-addr = <0x50ae0000>; - dsp-uart = <0x27>; - device-uart-mutex = <0x51820000>; - numa-node-id = <0x00>; - }; }; mmc@0x50460000 { @@ -434,24 +335,6 @@ no-mmc; }; - mbox@50a00000 { - compatible = "eswin,win2030-mailbox"; - reg = <0x00 0x50a00000 0x00 0x10000 0x00 0x50a10000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x75>; - #mbox-cells = <0x01>; - clocks = <0x03 0x27e 0x03 0x27f>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x01 0x15 0x0c 0x02>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x02>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x30>; - }; - mbox@50a20000 { compatible = "eswin,win2030-mailbox"; reg = <0x00 0x50a20000 0x00 0x10000 0x00 0x50a30000 0x00 0x10000>; @@ -488,23 +371,6 @@ phandle = <0x1e>; }; - mbox@50a60000 { - compatible = "eswin,win2030-mailbox"; - reg = <0x00 0x50a60000 0x00 0x10000 0x00 0x50a70000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x7b>; - #mbox-cells = <0x01>; - clocks = <0x03 0x284 0x03 0x285>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x40 0x15 0x0c 0x80>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x10>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - }; - mbox@50a80000 { compatible = "eswin,dsp0-mailbox"; reg = <0x00 0x50a80000 0x00 0x10000 0x00 0x50a90000 0x00 0x10000>; @@ -523,60 +389,6 @@ phandle = <0x23>; }; - mbox@50aa0000 { - compatible = "eswin,dsp1-mailbox"; - reg = <0x00 0x50aa0000 0x00 0x10000 0x00 0x50ab0000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x7f>; - #mbox-cells = <0x01>; - clocks = <0x03 0x288 0x03 0x289>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x400 0x15 0x0c 0x800>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x40>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x24>; - }; - - mbox@50ac0000 { - compatible = "eswin,dsp2-mailbox"; - reg = <0x00 0x50ac0000 0x00 0x10000 0x00 0x50ad0000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x81>; - #mbox-cells = <0x01>; - clocks = <0x03 0x28a 0x03 0x28b>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x1000 0x15 0x0c 0x2000>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x80>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x25>; - }; - - mbox@50ae0000 { - compatible = "eswin,dsp3-mailbox"; - reg = <0x00 0x50ae0000 0x00 0x10000 0x00 0x50af0000 0x00 0x10000>; - interrupt-parent = <0x10>; - interrupts = <0x83>; - #mbox-cells = <0x01>; - clocks = <0x03 0x28c 0x03 0x28d>; - clock-names = "pclk_mailbox_host\0pclk_mailbox_device"; - resets = <0x15 0x0c 0x4000 0x15 0x0c 0x8000>; - reset-names = "rst\0rst_device"; - lock-bit = <0x01>; - irq-bit = <0x100>; - numa-node-id = <0x00>; - dma-noncoherent; - status = "okay"; - phandle = <0x26>; - }; - i2c@51838000 { compatible = "snps,designware-i2c"; clock-frequency = <0x186a0>; @@ -622,7 +434,7 @@ }; chosen { - bootargs = "root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 console=ttyS0,115200 root=PARTUUID=b0f77ad6-36cd-4a99-a8c0-31d73649aa09 rootfstype=ext4 rootwait rw earlycon selinux=0 LANG=en_US.UTF-8 init=/bin/bash"; + bootargs = "console=ttyS0,115200 root=/dev/mmcblk0p3 rootfstype=ext4 rootwait rw earlycon selinux=0 LANG=en_US.UTF-8 init=/init.sh"; stdout-path = "serial0:115200n8"; domain-config { @@ -643,6 +455,12 @@ numa-node-id = <0x00>; }; + hvisor_virtio_device { + compatible = "hvisor"; + interrupt-parent = <0x10>; + interrupts = <0x20>; + }; + reserved-memory { #address-cells = <0x02>; #size-cells = <0x02>; @@ -658,6 +476,11 @@ reg = <0x00 0x80200000 0x00 0x02E00000>; }; + nonroot@83000000 { + no-map; + reg = <0x00 0x83000000 0x00 0x0D000000>; + }; + sprammemory@59000000 { no-map; reg = <0x00 0x59000000 0x00 0x400000>; diff --git a/platform/riscv64/hifive-premier-p550/scripts/README.md b/platform/riscv64/hifive-premier-p550/scripts/README.md index 8a129c43..13622052 100644 --- a/platform/riscv64/hifive-premier-p550/scripts/README.md +++ b/platform/riscv64/hifive-premier-p550/scripts/README.md @@ -25,4 +25,55 @@ screen -S zone1 /dev/pts/0 # reattach to virtio-console screen -r zone1 +``` +
+ +--- + +
+ +If you want to test npu, you can use these cmds. + +```bash +# in hvisor +insmod /lib/modules/6.6.77-win2030/kernel/drivers/soc/eswin/ai_driver/dsp/eic7700_dsp.ko +insmod /lib/modules/6.6.77-win2030/kernel/drivers/soc/eswin/ai_driver/npu/eic7700_npu.ko +# these two modules are needed +cd /home/debian/qwen +/opt/eswin/sample-code/npu_sample/qwen_sample/bin/es_qwen2 ./config.json + + +# in phys linux +cd qwen +sudo /opt/eswin/sample-code/npu_sample/qwen_sample/bin/es_qwen2 ./config.json +``` + +Other, if you see: +```bash +bash: cannot set terminal process group (-1): Inappropriate ioctl for device +bash: no job control in this shell +``` + +You can execute cmds: +```bash +mount -t proc proc /proc +mount -t sysfs sys /sys +mkdir -p /dev/pts +mount -t devpts devpts /dev/pts -o gid=5,mode=620,ptmxmode=0666 + +# Set one temp hostname, maybe rockos-eswin +hostname $(cat /etc/hostname) + +# insmod related ko +insmod eic7700_dsp.ko +insmod eic7700_npu.ko + +# execute getty +/sbin/getty -L ttyS0 115200 vt100 +# enter user & passwd + +# execute qwen example +cd qwen +sudo /opt/eswin/sample-code/npu_sample/qwen_sample/bin/es_qwen2 ./config.json +# enter passwd: debian ``` \ No newline at end of file diff --git a/platform/riscv64/hifive-premier-p550/scripts/init.sh b/platform/riscv64/hifive-premier-p550/scripts/init.sh new file mode 100644 index 00000000..c3bfe333 --- /dev/null +++ b/platform/riscv64/hifive-premier-p550/scripts/init.sh @@ -0,0 +1,17 @@ +#!/bin/bash + +mount -t proc proc /proc +mount -t sysfs sys /sys +mkdir -p /dev/pts +mount -t devpts devpts /dev/pts -o gid=5,mode=620,ptmxmode=0666 + +# Set one temp hostname, maybe rockos-eswin +hostname $(cat /etc/hostname) + +# insmod related ko +insmod /home/debian/module-6.77/eic7700_dsp.ko +insmod /home/debian/module-6.77/eic7700_npu.ko + +while true; do + /sbin/getty -L ttyS0 115200 vt100 +done \ No newline at end of file diff --git a/platform/riscv64/qemu-aia/board.rs b/platform/riscv64/qemu-aia/board.rs index 61dcce29..059b4d46 100644 --- a/platform/riscv64/qemu-aia/board.rs +++ b/platform/riscv64/qemu-aia/board.rs @@ -19,6 +19,8 @@ pub const BOARD_NAME: &str = "qemu-aia"; pub const BOARD_NCPUS: usize = 4; +pub const TIMEBASE_FREQ: u64 = 10_000_000; // 10MHz + pub const ACLINT_SSWI_BASE: usize = 0x2F00000; // This device is used for qemu-quit. diff --git a/platform/riscv64/qemu-plic/board.rs b/platform/riscv64/qemu-plic/board.rs index f38945b8..094ef417 100644 --- a/platform/riscv64/qemu-plic/board.rs +++ b/platform/riscv64/qemu-plic/board.rs @@ -20,6 +20,8 @@ pub const BOARD_NAME: &str = "qem-plic"; pub const BOARD_NCPUS: usize = 4; +pub const TIMEBASE_FREQ: u64 = 10_000_000; // 10MHz + pub const ACLINT_SSWI_BASE: usize = 0x2F00000; pub const PLIC_BASE: usize = 0xc000000; diff --git a/src/arch/aarch64/mod.rs b/src/arch/aarch64/mod.rs index 85bd3d21..f1c74e2a 100644 --- a/src/arch/aarch64/mod.rs +++ b/src/arch/aarch64/mod.rs @@ -25,6 +25,7 @@ pub mod mmu; pub mod paging; pub mod s2pt; pub mod sysreg; +pub mod time; pub mod trap; pub mod zone; diff --git a/src/arch/aarch64/time.rs b/src/arch/aarch64/time.rs new file mode 100644 index 00000000..25ae0f3a --- /dev/null +++ b/src/arch/aarch64/time.rs @@ -0,0 +1,21 @@ +// Copyright (c) 2025 Syswonder +// hvisor is licensed under Mulan PSL v2. +// You can use this software according to the terms and conditions of the Mulan PSL v2. +// You may obtain a copy of Mulan PSL v2 at: +// http://license.coscl.org.cn/MulanPSL2 +// THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR +// FIT FOR A PARTICULAR PURPOSE. +// See the Mulan PSL v2 for more details. +// +// Syswonder Website: +// https://www.syswonder.org +// +// Authors: +// Jingyu Liu +// + +/// Note: You should call this function once during initialization. +pub fn init_timebase() { + info!("Initializing aarch64 timebase not implemented yet."); +} diff --git a/src/arch/loongarch64/mod.rs b/src/arch/loongarch64/mod.rs index e0ef90aa..f85dcf53 100644 --- a/src/arch/loongarch64/mod.rs +++ b/src/arch/loongarch64/mod.rs @@ -28,6 +28,7 @@ pub mod paging; pub mod register; pub mod s1pt; pub mod s2pt; +pub mod time; pub mod trap; pub mod zone; diff --git a/src/arch/loongarch64/time.rs b/src/arch/loongarch64/time.rs new file mode 100644 index 00000000..786cef20 --- /dev/null +++ b/src/arch/loongarch64/time.rs @@ -0,0 +1,20 @@ +// Copyright (c) 2025 Syswonder +// hvisor is licensed under Mulan PSL v2. +// You can use this software according to the terms and conditions of the Mulan PSL v2. +// You may obtain a copy of Mulan PSL v2 at: +// http://license.coscl.org.cn/MulanPSL2 +// THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR +// FIT FOR A PARTICULAR PURPOSE. +// See the Mulan PSL v2 for more details. +// +// Syswonder Website: +// https://www.syswonder.org +// +// Authors: +// Jingyu Liu + +/// Note: You should call this function once during initialization. +pub fn init_timebase() { + info!("Initializing loongArch64 timebase not implemented yet."); +} diff --git a/src/arch/riscv64/mod.rs b/src/arch/riscv64/mod.rs index a4143b61..3c31bf95 100644 --- a/src/arch/riscv64/mod.rs +++ b/src/arch/riscv64/mod.rs @@ -25,6 +25,7 @@ pub mod paging; pub mod s1pt; pub mod s2pt; pub mod sbi; +pub mod time; pub mod trap; pub mod zone; diff --git a/src/arch/riscv64/sbi.rs b/src/arch/riscv64/sbi.rs index 4086f49d..f4e3f221 100644 --- a/src/arch/riscv64/sbi.rs +++ b/src/arch/riscv64/sbi.rs @@ -91,6 +91,8 @@ pub fn sbi_vs_handler(current_cpu: &mut ArchCpu) { EID_HVISOR => { sbi_ret = sbi_hvisor_handler(current_cpu); } + // Note: hvisor don't suggest to use Legacy Extension. + // But for compatibility, we still support some legacy SBI calls. // Legacy::Console putchar (usually used), temporily don't support other legacy extensions. legacy::LEGACY_CONSOLE_PUTCHAR => { sbi_ret = SbiRet { @@ -104,6 +106,9 @@ pub fn sbi_vs_handler(current_cpu: &mut ArchCpu) { value: 0, }; } + legacy::LEGACY_SET_TIMER => { + sbi_ret = sbi_time_handler(time::SET_TIMER, current_cpu); + } _ => { // Pass through SBI call warn!("Unsupported SBI extension {:#x} function {:#x}", eid, fid); @@ -114,8 +119,16 @@ pub fn sbi_vs_handler(current_cpu: &mut ArchCpu) { } } // Write the return value back to the current_cpu - current_cpu.x[10] = sbi_ret.error as usize; - current_cpu.x[11] = sbi_ret.value as usize; + // Note: for legacy SBI extensions, nothing is returned in a1 register. + // For other SBI extensions, a0 is error code, a1 is return value. + if eid > 0xF { + // Legacy extensions are 0x0 ~ 0xF + current_cpu.x[10] = sbi_ret.error as usize; + current_cpu.x[11] = sbi_ret.value as usize; + } else { + // This SBI call returns 0 upon success or an implementation specific negative error code. + current_cpu.x[10] = sbi_ret.error as usize; + } } /// Handle SBI Base Extension calls. @@ -148,11 +161,17 @@ pub fn sbi_base_handler(fid: usize, current_cpu: &mut ArchCpu) -> SbiRet { sbi_ret.value = ext_id; } } - base::GET_MVENDORID | base::GET_MARCHID | base::GET_MIMPID => { + base::GET_MVENDORID => { // Return a value that is legal for the mvendorid CSR and 0 is always a legal value for this CSR. + sbi_ret.value = sbi_rt::get_mvendorid(); + } + base::GET_MARCHID => { // Return a value that is legal for the marchid CSR and 0 is always a legal value for this CSR. + sbi_ret.value = sbi_rt::get_marchid(); + } + base::GET_MIMPID => { // Return a value that is legal for the mimpid CSR and 0 is always a legal value for this CSR. - sbi_ret.value = 0; + sbi_ret.value = sbi_rt::get_mimpid(); } _ => { sbi_ret.error = RET_ERR_NOT_SUPPORTED; diff --git a/src/arch/riscv64/time.rs b/src/arch/riscv64/time.rs new file mode 100644 index 00000000..58f62f94 --- /dev/null +++ b/src/arch/riscv64/time.rs @@ -0,0 +1,60 @@ +// Copyright (c) 2025 Syswonder +// hvisor is licensed under Mulan PSL v2. +// You can use this software according to the terms and conditions of the Mulan PSL v2. +// You may obtain a copy of Mulan PSL v2 at: +// http://license.coscl.org.cn/MulanPSL2 +// THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR +// FIT FOR A PARTICULAR PURPOSE. +// See the Mulan PSL v2 for more details. +// +// Syswonder Website: +// https://www.syswonder.org +// +// Authors: Jingyu Liu +// + +use crate::platform::__board::TIMEBASE_FREQ; +use riscv::register::time; + +static mut TIMEBASE: u64 = 0; + +/// Note: You should call this function once during initialization. +pub fn init_timebase() { + unsafe { + TIMEBASE = time::read() as u64; + } +} + +pub fn get_timebase() -> u64 { + unsafe { TIMEBASE } +} + +pub fn get_timefreq() -> u64 { + TIMEBASE_FREQ +} + +pub fn read_time() -> u64 { + // Now only support 64-bit system. + time::read() as u64 +} + +/// Return time in nanoseconds since some arbitrary point in the past. +pub fn get_time_ns() -> u64 { + unsafe { (read_time() - TIMEBASE) * 1_000_000_000 / TIMEBASE_FREQ } +} + +/// Return time in seconds since some arbitrary point in the past. +pub fn get_time_us() -> u64 { + unsafe { (read_time() - TIMEBASE) * 1_000_000 / TIMEBASE_FREQ } +} + +/// Return time in seconds since some arbitrary point in the past. +pub fn get_time_ms() -> u64 { + unsafe { (read_time() - TIMEBASE) * 1_000 / TIMEBASE_FREQ } +} + +/// Return time in seconds since some arbitrary point in the past. +pub fn get_time_s() -> u64 { + unsafe { (read_time() - TIMEBASE) / TIMEBASE_FREQ } +} diff --git a/src/consts.rs b/src/consts.rs index 32c55260..4e5e4c29 100644 --- a/src/consts.rs +++ b/src/consts.rs @@ -34,6 +34,10 @@ pub const MAX_ZONE_NUM: usize = 4; pub const MAX_WAIT_TIMES: usize = 100000000; +pub fn hv_start() -> VirtAddr { + skernel as _ +} + pub fn core_end() -> VirtAddr { __core_end as _ } @@ -52,5 +56,6 @@ pub const IPI_EVENT_UPDATE_HART_LINE: usize = 5; pub const IPI_EVENT_SEND_IPI: usize = 6; extern "C" { + fn skernel(); fn __core_end(); } diff --git a/src/logging.rs b/src/logging.rs index 65f2370d..128aeffc 100644 --- a/src/logging.rs +++ b/src/logging.rs @@ -164,6 +164,22 @@ impl SimpleLogger { args_color: ColorCode, record: &Record, ) { + #[cfg(feature = "print_timestamp")] + { + let time_us: u64 = crate::arch::time::get_time_us(); + let sec = time_us / 1_000_000; + let us = time_us % 1_000_000; + print(with_color!( + ColorCode::White, + "[{}] {} {} hvisor: {} {}\n", + with_color!(ColorCode::BrightWhite, "{:>5}.{:06}", sec, us), + with_color!(level_color, "{:<5}", level), + with_color!(ColorCode::BrightGreen, "CPU{}", cpu_id), + with_color!(ColorCode::White, "({}:{})", target, line), + with_color!(args_color, "{}", record.args()), + )); + } + #[cfg(not(feature = "print_timestamp"))] print(with_color!( ColorCode::White, "[{} {}] {} {}\n", diff --git a/src/main.rs b/src/main.rs index b11ac8c4..28d02906 100644 --- a/src/main.rs +++ b/src/main.rs @@ -177,6 +177,7 @@ fn rust_main(cpuid: usize, host_dtb: usize) { is_primary = true; memory::heap::init(); memory::heap::test(); + arch::time::init_timebase(); arch_post_heap_init(host_dtb); }