diff options
Diffstat (limited to 'dts/upstream/src/loongarch')
| -rw-r--r-- | dts/upstream/src/loongarch/loongson-2k0500-ref.dts | 9 | ||||
| -rw-r--r-- | dts/upstream/src/loongarch/loongson-2k0500.dtsi | 188 | ||||
| -rw-r--r-- | dts/upstream/src/loongarch/loongson-2k1000-ref.dts | 37 | ||||
| -rw-r--r-- | dts/upstream/src/loongarch/loongson-2k1000.dtsi | 66 | ||||
| -rw-r--r-- | dts/upstream/src/loongarch/loongson-2k2000-ref.dts | 10 | ||||
| -rw-r--r-- | dts/upstream/src/loongarch/loongson-2k2000.dtsi | 78 | 
6 files changed, 379 insertions, 9 deletions
| diff --git a/dts/upstream/src/loongarch/loongson-2k0500-ref.dts b/dts/upstream/src/loongarch/loongson-2k0500-ref.dts index a34734a6c3c..018ed904352 100644 --- a/dts/upstream/src/loongarch/loongson-2k0500-ref.dts +++ b/dts/upstream/src/loongarch/loongson-2k0500-ref.dts @@ -41,6 +41,15 @@  	};  }; +&apbdma3 { +	status = "okay"; +}; + +&mmc0 { +	status = "okay"; +	bus-width = <4>; +}; +  &gmac0 {  	status = "okay"; diff --git a/dts/upstream/src/loongarch/loongson-2k0500.dtsi b/dts/upstream/src/loongarch/loongson-2k0500.dtsi index 3b38ff8853a..588ebc3bded 100644 --- a/dts/upstream/src/loongarch/loongson-2k0500.dtsi +++ b/dts/upstream/src/loongarch/loongson-2k0500.dtsi @@ -104,7 +104,7 @@  			status = "disabled";  		}; -		dma-controller@1fe10c20 { +		apbdma2: dma-controller@1fe10c20 {  			compatible = "loongson,ls2k0500-apbdma", "loongson,ls2k1000-apbdma";  			reg = <0 0x1fe10c20 0 0x8>;  			interrupt-parent = <&eiointc>; @@ -114,7 +114,7 @@  			status = "disabled";  		}; -		dma-controller@1fe10c30 { +		apbdma3: dma-controller@1fe10c30 {  			compatible = "loongson,ls2k0500-apbdma", "loongson,ls2k1000-apbdma";  			reg = <0 0x1fe10c30 0 0x8>;  			interrupt-parent = <&eiointc>; @@ -169,6 +169,166 @@  			interrupts = <3>;  		}; +		pwm@1ff5c000 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c000 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <24 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c010 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c010 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <24 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c020 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c020 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <24 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c030 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c030 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <24 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c040 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c040 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <25 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c050 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c050 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <25 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c060 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c060 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <25 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c070 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c070 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <25 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c080 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c080 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <26 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c090 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c090 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <26 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c0a0 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c0a0 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <26 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c0b0 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c0b0 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <26 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c0c0 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c0c0 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <27 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c0d0 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c0d0 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <27 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c0e0 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c0e0 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <27 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1ff5c0f0 { +			compatible = "loongson,ls2k0500-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1ff5c0f0 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <27 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; +  		gmac0: ethernet@1f020000 {  			compatible = "snps,dwmac-3.70a";  			reg = <0x0 0x1f020000 0x0 0x10000>; @@ -277,6 +437,30 @@  			status = "disabled";  		}; +		mmc0: mmc@1ff64000 { +			compatible = "loongson,ls2k0500-mmc"; +			reg = <0 0x1ff64000 0 0x2000>, +			      <0 0x1fe10100 0 0x4>; +			interrupt-parent = <&eiointc>; +			interrupts = <57>; +			dmas = <&apbdma3 0>; +			dma-names = "rx-tx"; +			clocks = <&clk LOONGSON2_APB_CLK>; +			status = "disabled"; +		}; + +		mmc@1ff66000 { +			compatible = "loongson,ls2k0500-mmc"; +			reg = <0 0x1ff66000 0 0x2000>, +			      <0 0x1fe10100 0 0x4>; +			interrupt-parent = <&eiointc>; +			interrupts = <58>; +			dmas = <&apbdma2 0>; +			dma-names = "rx-tx"; +			clocks = <&clk LOONGSON2_APB_CLK>; +			status = "disabled"; +		}; +  		pmc: power-management@1ff6c000 {  			compatible = "loongson,ls2k0500-pmc", "syscon";  			reg = <0x0 0x1ff6c000 0x0 0x58>; diff --git a/dts/upstream/src/loongarch/loongson-2k1000-ref.dts b/dts/upstream/src/loongarch/loongson-2k1000-ref.dts index 3514ea78f52..d9a452ada5d 100644 --- a/dts/upstream/src/loongarch/loongson-2k1000-ref.dts +++ b/dts/upstream/src/loongarch/loongson-2k1000-ref.dts @@ -5,6 +5,7 @@  /dts-v1/; +#include "dt-bindings/thermal/thermal.h"  #include "loongson-2k1000.dtsi"  / { @@ -38,6 +39,26 @@  			linux,cma-default;  		};  	}; + +	fan0: pwm-fan { +		compatible = "pwm-fan"; +		cooling-levels = <255 153 85 25>; +		pwms = <&pwm1 0 100000 0>; +		#cooling-cells = <2>; +	}; +}; + +&apbdma1 { +	status = "okay"; +}; + +&mmc { +	status = "okay"; + +	pinctrl-0 = <&sdio_pins_default>; +	pinctrl-names = "default"; +	bus-width = <4>; +	cd-gpios = <&gpio0 22 GPIO_ACTIVE_LOW>;  };  &gmac0 { @@ -92,6 +113,22 @@  	#size-cells = <0>;  }; +&pwm1 { +	status = "okay"; + +	pinctrl-0 = <&pwm1_pins_default>; +	pinctrl-names = "default"; +}; + +&cpu_thermal { +	cooling-maps { +		map0 { +			trip = <&cpu_alert>; +			cooling-device = <&fan0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; +		}; +	}; +}; +  &ehci0 {  	status = "okay";  }; diff --git a/dts/upstream/src/loongarch/loongson-2k1000.dtsi b/dts/upstream/src/loongarch/loongson-2k1000.dtsi index 8dff2aa5241..d8e01e2534d 100644 --- a/dts/upstream/src/loongarch/loongson-2k1000.dtsi +++ b/dts/upstream/src/loongarch/loongson-2k1000.dtsi @@ -68,7 +68,7 @@  	};  	thermal-zones { -		cpu-thermal { +		cpu_thermal: cpu-thermal {  			polling-delay-passive = <1000>;  			polling-delay = <5000>;  			thermal-sensors = <&tsensor 0>; @@ -187,14 +187,14 @@  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>, -				     <>, -				     <26 IRQ_TYPE_LEVEL_HIGH>, +				     <0 IRQ_TYPE_NONE>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>, +				     <26 IRQ_TYPE_NONE>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>,  				     <26 IRQ_TYPE_LEVEL_HIGH>, @@ -209,13 +209,13 @@  				     <27 IRQ_TYPE_LEVEL_HIGH>,  				     <27 IRQ_TYPE_LEVEL_HIGH>,  				     <27 IRQ_TYPE_LEVEL_HIGH>, -				     <>, +				     <0 IRQ_TYPE_NONE>,  				     <27 IRQ_TYPE_LEVEL_HIGH>,  				     <27 IRQ_TYPE_LEVEL_HIGH>,  				     <27 IRQ_TYPE_LEVEL_HIGH>,  				     <27 IRQ_TYPE_LEVEL_HIGH>, -				     <>, -				     <>, +				     <0 IRQ_TYPE_NONE>, +				     <0 IRQ_TYPE_NONE>,  				     <27 IRQ_TYPE_LEVEL_HIGH>,  				     <27 IRQ_TYPE_LEVEL_HIGH>,  				     <27 IRQ_TYPE_LEVEL_HIGH>, @@ -256,7 +256,7 @@  			status = "disabled";  		}; -		dma-controller@1fe00c10 { +		apbdma1: dma-controller@1fe00c10 {  			compatible = "loongson,ls2k1000-apbdma";  			reg = <0x0 0x1fe00c10 0x0 0x8>;  			interrupt-parent = <&liointc1>; @@ -322,6 +322,46 @@  			status = "disabled";  		}; +		pwm@1fe22000 { +			compatible = "loongson,ls2k1000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1fe22000 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <24 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm1: pwm@1fe22010 { +			compatible = "loongson,ls2k1000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1fe22010 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <25 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1fe22020 { +			compatible = "loongson,ls2k1000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1fe22020 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <26 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@1fe22030 { +			compatible = "loongson,ls2k1000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x1fe22030 0x0 0x10>; +			interrupt-parent = <&liointc0>; +			interrupts = <27 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; +  		pmc: power-management@1fe27000 {  			compatible = "loongson,ls2k1000-pmc", "loongson,ls2k0500-pmc", "syscon";  			reg = <0x0 0x1fe27000 0x0 0x58>; @@ -365,6 +405,18 @@  			status = "disabled";  		}; +		mmc: mmc@1fe2c000 { +			compatible = "loongson,ls2k1000-mmc"; +			reg = <0 0x1fe2c000 0 0x68>, +			      <0 0x1fe00438 0 0x8>; +			interrupt-parent = <&liointc0>; +			interrupts = <31 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_APB_CLK>; +			dmas = <&apbdma1 0>; +			dma-names = "rx-tx"; +			status = "disabled"; +		}; +  		spi0: spi@1fff0220 {  			compatible = "loongson,ls2k1000-spi";  			reg = <0x0 0x1fff0220 0x0 0x10>; diff --git a/dts/upstream/src/loongarch/loongson-2k2000-ref.dts b/dts/upstream/src/loongarch/loongson-2k2000-ref.dts index ea9e6985d0e..3c6b1222038 100644 --- a/dts/upstream/src/loongarch/loongson-2k2000-ref.dts +++ b/dts/upstream/src/loongarch/loongson-2k2000-ref.dts @@ -39,6 +39,16 @@  	};  }; +&emmc { +	status = "okay"; + +	bus-width = <8>; +	cap-mmc-highspeed; +	mmc-hs200-1_8v; +	no-sd; +	no-sdio; +}; +  &sata {  	status = "okay";  }; diff --git a/dts/upstream/src/loongarch/loongson-2k2000.dtsi b/dts/upstream/src/loongarch/loongson-2k2000.dtsi index b4ff55a33e9..00cc485b753 100644 --- a/dts/upstream/src/loongarch/loongson-2k2000.dtsi +++ b/dts/upstream/src/loongarch/loongson-2k2000.dtsi @@ -165,6 +165,66 @@  			interrupt-parent = <&eiointc>;  		}; +		pwm@100a0000 { +			compatible = "loongson,ls2k2000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x100a0000 0x0 0x10>; +			interrupt-parent = <&pic>; +			interrupts = <24 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_MISC_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@100a0100 { +			compatible = "loongson,ls2k2000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x100a0100 0x0 0x10>; +			interrupt-parent = <&pic>; +			interrupts = <25 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_MISC_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@100a0200 { +			compatible = "loongson,ls2k2000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x100a0200 0x0 0x10>; +			interrupt-parent = <&pic>; +			interrupts = <26 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_MISC_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@100a0300 { +			compatible = "loongson,ls2k2000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x100a0300 0x0 0x10>; +			interrupt-parent = <&pic>; +			interrupts = <27 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_MISC_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@100a0400 { +			compatible = "loongson,ls2k2000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x100a0400 0x0 0x10>; +			interrupt-parent = <&pic>; +			interrupts = <38 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_MISC_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; + +		pwm@100a0500 { +			compatible = "loongson,ls2k2000-pwm", "loongson,ls7a-pwm"; +			reg = <0x0 0x100a0500 0x0 0x10>; +			interrupt-parent = <&pic>; +			interrupts = <39 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_MISC_CLK>; +			#pwm-cells = <3>; +			status = "disabled"; +		}; +  		rtc0: rtc@100d0100 {  			compatible = "loongson,ls2k2000-rtc", "loongson,ls7a-rtc";  			reg = <0x0 0x100d0100 0x0 0x100>; @@ -199,6 +259,24 @@  			status = "disabled";  		}; +		emmc: mmc@79990000 { +			compatible = "loongson,ls2k2000-mmc"; +			reg = <0x0 0x79990000 0x0 0x1000>; +			interrupt-parent = <&pic>; +			interrupts = <51 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_EMMC_CLK>; +			status = "disabled"; +		}; + +		mmc@79991000 { +			compatible = "loongson,ls2k2000-mmc"; +			reg = <0x0 0x79991000 0x0 0x1000>; +			interrupt-parent = <&pic>; +			interrupts = <50 IRQ_TYPE_LEVEL_HIGH>; +			clocks = <&clk LOONGSON2_EMMC_CLK>; +			status = "disabled"; +		}; +  		pcie@1a000000 {  			compatible = "loongson,ls2k-pci";  			reg = <0x0 0x1a000000 0x0 0x02000000>, | 
