Commit 37c514e3 authored by Sam Ravnborg's avatar Sam Ravnborg

Add missing init section definitions

When adding __devinitconst etc. the __initconst variant
were missed.
Add this one and proper definitions for .head.text for use
in .S files.
The naming .head.text is preferred over .text.head as the
latter will conflict for a function named head when introducing
-ffunctions-sections.
Signed-off-by: default avatarSam Ravnborg <sam@ravnborg.org>
parent b1d2675a
...@@ -238,6 +238,9 @@ ...@@ -238,6 +238,9 @@
*(.kprobes.text) \ *(.kprobes.text) \
VMLINUX_SYMBOL(__kprobes_text_end) = .; VMLINUX_SYMBOL(__kprobes_text_end) = .;
/* Section used for early init (in .S files) */
#define HEAD_TEXT *(.head.text)
/* init and exit section handling */ /* init and exit section handling */
#define INIT_DATA \ #define INIT_DATA \
*(.init.data) \ *(.init.data) \
......
...@@ -42,6 +42,7 @@ ...@@ -42,6 +42,7 @@
discard it in modules) */ discard it in modules) */
#define __init __section(.init.text) __cold #define __init __section(.init.text) __cold
#define __initdata __section(.init.data) #define __initdata __section(.init.data)
#define __initconst __section(.init.rodata)
#define __exitdata __section(.exit.data) #define __exitdata __section(.exit.data)
#define __exit_call __used __section(.exitcall.exit) #define __exit_call __used __section(.exitcall.exit)
...@@ -106,6 +107,7 @@ ...@@ -106,6 +107,7 @@
#define __memexitconst __section(.memexit.rodata) #define __memexitconst __section(.memexit.rodata)
/* For assembly routines */ /* For assembly routines */
#define __HEAD .section ".head.text","ax"
#define __INIT .section ".init.text","ax" #define __INIT .section ".init.text","ax"
#define __FINIT .previous #define __FINIT .previous
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment