File size: 1,373 Bytes
cd886b3
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/dts-v1/;

/ {
	#address-cells = <0x02>;
	#size-cells = <0x02>;
	compatible = "riscv-minimal-nommu";
	model = "riscv-minimal-nommu,qemu";

	chosen {
		bootargs = "earlycon=uart8250,mmio,0x10000000 console=ttyS0";
		/*
		opencores 16550 uart seems to break if linux inits it.
		removing the baudrate setting tells the driver to not init it.
		bootargs = "earlycon=uart8250,mmio,0x10000000,460800 console=ttyS0";
		*/
	};

	memory@80000000 {
		device_type = "memory";
		reg = <0x00 0x80000000 0x00 0x1000000>; // 16MB
	};

	cpus {
		#address-cells = <0x01>;
		#size-cells = <0x00>;
		/* sys timer is in Hz */
		timebase-frequency = <1000000>;

		cpu@0 {
			reg = <0x00>;
			device_type = "cpu";
			status = "okay";
			compatible = "riscv";
			riscv,isa = "rv32ima";
			mmu-type = "riscv,none";

			intc: interrupt-controller {
				#interrupt-cells = <0x01>;
				#address-cells = <0x01>;
				interrupt-controller;
				compatible = "riscv,cpu-intc";
				phandle = <0x02>;
			};
		};
	};

	soc {
		#address-cells = <0x02>;
		#size-cells = <0x02>;
		compatible = "simple-bus";
		ranges;

		uart@10000000 {
			clock-frequency = <14746227>;
			reg = <0x00 0x10000000 0x00 0x100>;
			compatible = "ns16850";
		};

		clint@11000000 {
			interrupts-extended = <&intc 0x03>,
					      <&intc 0x07>;
			reg = <0x00 0x11000000 0x00 0x10000>;
			compatible = "riscv,clint0";
		};
	};
};