[MIPS] vmlinux.lds.S: Fix handling of .notes in final link.
authorRalf Baechle <ralf@linux-mips.org>
Sun, 14 Oct 2007 21:49:01 +0000 (22:49 +0100)
committerRalf Baechle <ralf@linux-mips.org>
Tue, 16 Oct 2007 17:23:46 +0000 (18:23 +0100)
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/kernel/vmlinux.lds.S

index 03ad46e24563234223c8ec9fe5df7a4ef3816947..33581387d662ec73d9f8b324b7cbccca7d443a2d 100644 (file)
@@ -5,6 +5,10 @@
 #define mips mips
 OUTPUT_ARCH(mips)
 ENTRY(kernel_entry)
+PHDRS {
+       text PT_LOAD FLAGS(7);  /* RWX */
+       note PT_NOTE FLAGS(4);  /* R__ */
+}
 jiffies = JIFFIES;
 
 SECTIONS
@@ -33,7 +37,7 @@ SECTIONS
                LOCK_TEXT
                *(.fixup)
                *(.gnu.warning)
-       } =0
+       } :text = 0
        _etext = .;     /* End of text section */
 
        /* Exception table */
@@ -50,6 +54,10 @@ SECTIONS
                *(__dbe_table)
                __stop___dbe_table = .;
        }
+
+       NOTES :text :note
+       .dummy : { *(.dummy) } :text
+
        RODATA
 
        /* writeable */
@@ -200,7 +208,4 @@ SECTIONS
                *(.gptab.bss)
                *(.gptab.sbss)
        }
-       .note : {
-               *(.note)
-       }
 }