summaryrefslogtreecommitdiff
path: root/include/linux/init.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/init.h')
-rw-r--r--include/linux/init.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/include/linux/init.h b/include/linux/init.h
index 0e06c176f185..13b633ed695e 100644
--- a/include/linux/init.h
+++ b/include/linux/init.h
@@ -2,8 +2,6 @@
#define _LINUX_INIT_H
#include <linux/compiler.h>
-#include <linux/section-names.h>
-#include <linux/stringify.h>
/* These macros are used to mark some functions or
* initialized data (doesn't apply to uninitialized data)
@@ -31,7 +29,7 @@
* sign followed by value, e.g.:
*
* static int init_variable __initdata = 0;
- * static char linux_logo[] __initdata = { 0x32, 0x36, ... };
+ * static const char linux_logo[] __initconst = { 0x32, 0x36, ... };
*
* Don't forget to initialize data not at file scope, i.e. within a function,
* as gcc otherwise puts the data into the bss section and not into the init
@@ -101,7 +99,7 @@
#define __memexitconst __section(.memexit.rodata)
/* For assembly routines */
-#define __HEAD .section __stringify(HEAD_TEXT_SECTION),"ax"
+#define __HEAD .section ".head.text","ax"
#define __INIT .section ".init.text","ax"
#define __FINIT .previous
@@ -136,6 +134,9 @@ typedef void (*exitcall_t)(void);
extern initcall_t __con_initcall_start[], __con_initcall_end[];
extern initcall_t __security_initcall_start[], __security_initcall_end[];
+/* Used for contructor calls. */
+typedef void (*ctor_fn_t)(void);
+
/* Defined in init/main.c */
extern int do_one_initcall(initcall_t fn);
extern char __initdata boot_command_line[];
@@ -225,7 +226,8 @@ struct obs_kernel_param {
* obs_kernel_param "array" too far apart in .init.setup.
*/
#define __setup_param(str, unique_id, fn, early) \
- static char __setup_str_##unique_id[] __initdata __aligned(1) = str; \
+ static const char __setup_str_##unique_id[] __initconst \
+ __aligned(1) = str; \
static struct obs_kernel_param __setup_##unique_id \
__used __section(.init.setup) \
__attribute__((aligned((sizeof(long))))) \