aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/alloc.rs1
-rw-r--r--src/bsp/raspberrypi/linker.ld1
2 files changed, 2 insertions, 0 deletions
diff --git a/src/alloc.rs b/src/alloc.rs
index 4fe44ee..fd22c67 100644
--- a/src/alloc.rs
+++ b/src/alloc.rs
@@ -89,4 +89,5 @@ impl Debug for CharAllocator {
}
}
+#[link_section = ".data.alloc"]
pub static CHAR_ALLOCATOR: CharAllocator = CharAllocator::new();
diff --git a/src/bsp/raspberrypi/linker.ld b/src/bsp/raspberrypi/linker.ld
index 93ee267..daf4a05 100644
--- a/src/bsp/raspberrypi/linker.ld
+++ b/src/bsp/raspberrypi/linker.ld
@@ -19,6 +19,7 @@ SECTIONS
.data :
{
*(.data*)
+ KEEP(*(.data.alloc))
__stacks_start = .;
KEEP(*(.data.stacks))
}