]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - arch/arm/kernel/vmlinux.lds.S
ARM: use linker magic for vectors and vector stubs
[karo-tx-linux.git] / arch / arm / kernel / vmlinux.lds.S
index fa25e4e425f6070c0a6055de98271f865dde3823..7bcee5c9b6049c2723df9e3e9fc9b0b088b5fe0b 100644 (file)
@@ -148,6 +148,23 @@ SECTIONS
        . = ALIGN(PAGE_SIZE);
        __init_begin = .;
 #endif
+       /*
+        * The vectors and stubs are relocatable code, and the
+        * only thing that matters is their relative offsets
+        */
+       __vectors_start = .;
+       .vectors 0 : AT(__vectors_start) {
+               *(.vectors)
+       }
+       . = __vectors_start + SIZEOF(.vectors);
+       __vectors_end = .;
+
+       __stubs_start = .;
+       .stubs 0x1000 : AT(__stubs_start) {
+               *(.stubs)
+       }
+       . = __stubs_start + SIZEOF(.stubs);
+       __stubs_end = .;
 
        INIT_TEXT_SECTION(8)
        .exit.text : {