aboutsummaryrefslogtreecommitdiff
path: root/asm/lib.rs
diff options
context:
space:
mode:
authorGravatar Jonas Schievink <jonasschievink@gmail.com> 2020-11-04 02:08:00 +0100
committerGravatar Jonas Schievink <jonasschievink@gmail.com> 2020-11-04 02:08:00 +0100
commit1762486eddee0dbacaa702be3afbbae8c183f0c2 (patch)
tree76257725aec0eb6361df76029b66291ae732c91d /asm/lib.rs
parent94d3357f0b4e27895e9a9e5eab3d7cb91e10abd4 (diff)
downloadcortex-m-1762486eddee0dbacaa702be3afbbae8c183f0c2.tar.gz
cortex-m-1762486eddee0dbacaa702be3afbbae8c183f0c2.tar.zst
cortex-m-1762486eddee0dbacaa702be3afbbae8c183f0c2.zip
Fix panic handler removal
Diffstat (limited to 'asm/lib.rs')
-rw-r--r--asm/lib.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/asm/lib.rs b/asm/lib.rs
index ec46d5b..b57642e 100644
--- a/asm/lib.rs
+++ b/asm/lib.rs
@@ -126,6 +126,7 @@ shims! {
/// handler gets linked in, this causes a linker error. We always build this file with optimizations
/// enabled, but even without them the panic handler should never be linked in.
#[panic_handler]
+#[link_section = ".text.asm_panic_handler"]
fn panic(_: &core::panic::PanicInfo) -> ! {
extern "C" {
#[link_name = "cortex-m internal error: panic handler not optimized out, please file an \