From bbb93362a4452282ba51067dfb609476380518dc Mon Sep 17 00:00:00 2001 From: Song Liu Date: Wed, 25 Jan 2023 10:54:00 -0800 Subject: [PATCH] x86/module: remove unused code in __apply_relocate_add This "#if 0" block has been untouched for many years. Remove it to clean up the code. Suggested-by: Josh Poimboeuf Signed-off-by: Song Liu Reviewed-by: Petr Mladek Acked-by: Josh Poimboeuf Reviewed-by: Joe Lawrence Signed-off-by: Petr Mladek Link: https://lore.kernel.org/r/20230125185401.279042-1-song@kernel.org --- arch/x86/kernel/module.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/arch/x86/kernel/module.c b/arch/x86/kernel/module.c index c8a25aed604d6..0a09d816794bd 100644 --- a/arch/x86/kernel/module.c +++ b/arch/x86/kernel/module.c @@ -187,10 +187,6 @@ static int __apply_relocate_add(Elf64_Shdr *sechdrs, goto invalid_relocation; val -= (u64)loc; write(loc, &val, 4); -#if 0 - if ((s64)val != *(s32 *)loc) - goto overflow; -#endif break; case R_X86_64_PC64: if (*(u64 *)loc != 0) -- 2.30.2