From 264b8aa4bf061e84e4363e4accc0bace43ce0aa5 Mon Sep 17 00:00:00 2001 From: Alexander Taylor Date: Thu, 22 Aug 2024 19:35:00 -0400 Subject: Specialize relocation warning for 32-bit/64-bit. --- arch/riscv/src/lib.rs | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/arch/riscv/src/lib.rs b/arch/riscv/src/lib.rs index 725177ca..aaeed66d 100644 --- a/arch/riscv/src/lib.rs +++ b/arch/riscv/src/lib.rs @@ -2337,10 +2337,19 @@ impl RelocationHandler reloc.size = 2; reloc.truncate_size = 2; } - Self::R_RISCV_TLS_TPREL32 | Self::R_RISCV_TLS_TPREL64 => { + Self::R_RISCV_TLS_TPREL32 => { reloc.type_ = RelocationType::UnhandledRelocation; log::warn!( - "Unhandled relocation type R_RISCV_TLS_TPREL at {:x?}", + "Unhandled relocation type {:?} (R_RISCV_TLS_TPREL32) at {:x?}", + reloc.native_type, + reloc.address + ) + } + Self::R_RISCV_TLS_TPREL64 => { + reloc.type_ = RelocationType::UnhandledRelocation; + log::warn!( + "Unhandled relocation type {:?} (R_RISCV_TLS_TPREL64) at {:x?}", + reloc.native_type, reloc.address ) } -- cgit v1.3.1