Skip to content

Commit 0e04fe7

Browse files
rjolearyrminnich
authored andcommitted
Use a smaller dtfs which fits in 16MiB flash map
Signed-off-by: Ryan O'Leary <[email protected]>
1 parent 8fcfd28 commit 0e04fe7

File tree

5 files changed

+16
-41
lines changed

5 files changed

+16
-41
lines changed

src/mainboard/sifive/hifive/fixed-dtfs.dts

Lines changed: 12 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -11,64 +11,36 @@
1111
board-url = "https://www.sifive.com/boards/hifive-unleashed";
1212
areas {
1313
area@0 {
14-
description = "Boot Blob";
15-
compatible = "ore-bootblob";
14+
description = "Boot Blob and Ramstage";
1615
offset = <0x0>;
1716
size = <0x80000>; // 512KiB
1817
file = "target/riscv64imac-unknown-none-elf/release/bootblob.bin";
1918
};
2019
area@1 {
2120
description = "Fixed DTFS";
22-
compatible = "ore-dtfs";
2321
offset = <0x80000>;
2422
size = <0x80000>; // 512KiB
2523
file = "target/riscv64imac-unknown-none-elf/release/fixed-dtfs.dtb";
2624
};
2725
area@2 {
28-
description = "NVRAM A";
29-
compatible = "ore-nvram";
30-
half = <0>;
26+
description = "Payload A";
3127
offset = <0x100000>;
32-
size = <0x80000>; // 512KiB
28+
size = <0x600000>; // 6MiB
29+
file = "payloadA";
3330
};
3431
area@3 {
35-
description = "NVRAM B";
36-
compatible = "ore-nvram";
37-
half = <1>;
38-
offset = <0x180000>;
39-
size = <0x80000>; // 512KiB
32+
description = "Payload B";
33+
offset = <0x700000>;
34+
size = <0x600000>; // 6MiB
35+
file = "payloadB";
4036
};
4137
area@4 {
42-
description = "RomPayload DTFS A";
43-
compatible = "ore-rompayload";
44-
half = <0>;
45-
offset = <0x200000>;
46-
size = <0x100000>; // 1MiB
38+
description = "Payload C";
39+
offset = <0xd00000>;
40+
size = <0x300000>; // 3MiB
41+
file = "payloadC";
4742
};
4843
area@5 {
49-
description = "RomPayload DTFS B";
50-
compatible = "ore-rompayload";
51-
half = <1>;
52-
offset = <0x300000>;
53-
size = <0x100000>; // 1MiB
54-
};
55-
area@6 {
56-
description = "RamPayload DTFS A";
57-
compatible = "ore-rampayload";
58-
half = <0>;
59-
offset = <0x400000>;
60-
size = <0x600000>; // 6MiB
61-
file = "../../../../payloads/src/external/simple/testtesttest";
62-
};
63-
area@7 {
64-
description = "RamPayload DTFS B";
65-
compatible = "ore-rampayload";
66-
half = <1>;
67-
offset = <0xa00000>;
68-
size = <0x600000>; // 6MiB
69-
file = "../../../../payloads/src/external/simple/testtesttest";
70-
};
71-
area@8 {
7244
description = "Empty Space";
7345
offset = <0x1000000>;
7446
size = <0x1000000>; // 16MiB

src/mainboard/sifive/hifive/payloadA

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../../../payloads/src/external/simple/testtesttest

src/mainboard/sifive/hifive/payloadB

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../../../payloads/src/external/simple/testtesttest

src/mainboard/sifive/hifive/payloadC

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../../../payloads/src/external/simple/testtesttest

src/mainboard/sifive/hifive/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ pub extern "C" fn _start_boot_hart(_hart_id: usize, fdt_address: usize) -> ! {
121121
payload::Segment {
122122
typ: payload::stype::PAYLOAD_SEGMENT_ENTRY,
123123
base: mem,
124-
data: &mut SectionReader::new(&Memory {}, 0x20000000 + 0x400000, 6 * 1024 * 1024),
124+
data: &mut SectionReader::new(&Memory {}, 0x20000000 + 0x100000, 0x600000),
125125
},
126126
payload::Segment {
127127
typ: payload::stype::PAYLOAD_SEGMENT_DATA,

0 commit comments

Comments
 (0)