浏览代码

sh: Discard .exit.text/.exit.data at runtime.

These were previously discarded at link time, though as with MIPS
we keep them around until runtime to satisfy .rodata references.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Paul Mundt 17 年之前
父节点
当前提交
63482aaada
共有 1 个文件被更改,包括 5 次插入0 次删除
  1. 5 0
      arch/sh/kernel/vmlinux.lds.S

+ 5 - 0
arch/sh/kernel/vmlinux.lds.S

@@ -91,6 +91,11 @@ SECTIONS
   __con_initcall_end = .;
   SECURITY_INIT
 
+  /* .exit.text is discarded at runtime, not link time, to deal with
+     references from .rodata */
+  .exit.text : { *(.exit.text) }
+  .exit.data : { *(.exit.data) }
+
 #ifdef CONFIG_BLK_DEV_INITRD
   . = ALIGN(PAGE_SIZE);