Commit 99c9f502 authored by Jeff Dike's avatar Jeff Dike Committed by Linus Torvalds
Browse files

uml: arch/um/include/init.h needs a definition of __used

init.h started breaking now for some reason.  It turns out that there wasn't a
definition of __used.  Fixed this by copying the relevant stuff from
compiler.h in the userspace case, and including compiler.h in the kernel case.

[ added definition of __section]
Signed-off-by: default avatarJeff Dike <>
Cc: WANG Cong <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent 747646a4
......@@ -40,6 +40,20 @@
typedef int (*initcall_t)(void);
typedef void (*exitcall_t)(void);
#ifndef __KERNEL__
#ifndef __section
# define __section(S) __attribute__ ((__section__(#S)))
#if __GNUC_MINOR__ >= 3
# define __used __attribute__((__used__))
# define __used __attribute__((__unused__))
#include <linux/compiler.h>
/* These are for everybody (although not all archs will actually
discard it in modules) */
#define __init __section(.init.text)
......@@ -127,14 +141,3 @@ extern struct uml_param __uml_setup_start, __uml_setup_end;
#endif /* _LINUX_UML_INIT_H */
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-file-style: "linux"
* End:
Supports Markdown
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