diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/um/drivers/mconsole_kern.c | 4 | ||||
-rw-r--r-- | arch/um/drivers/net_kern.c | 2 | ||||
-rw-r--r-- | arch/um/kernel/mem.c | 2 | ||||
-rw-r--r-- | arch/um/kernel/physmem.c | 15 | ||||
-rw-r--r-- | arch/um/kernel/skas/process.c | 4 | ||||
-rw-r--r-- | arch/um/os-Linux/process.c | 2 |
6 files changed, 12 insertions, 17 deletions
diff --git a/arch/um/drivers/mconsole_kern.c b/arch/um/drivers/mconsole_kern.c index 542c9ef858f8..d87090507401 100644 --- a/arch/um/drivers/mconsole_kern.c +++ b/arch/um/drivers/mconsole_kern.c | |||
@@ -499,7 +499,7 @@ static struct mc_device mem_mc = { | |||
499 | .remove = mem_remove, | 499 | .remove = mem_remove, |
500 | }; | 500 | }; |
501 | 501 | ||
502 | static int mem_mc_init(void) | 502 | static int __init mem_mc_init(void) |
503 | { | 503 | { |
504 | if(can_drop_memory()) | 504 | if(can_drop_memory()) |
505 | mconsole_register_dev(&mem_mc); | 505 | mconsole_register_dev(&mem_mc); |
@@ -798,7 +798,7 @@ void mconsole_stack(struct mc_request *req) | |||
798 | */ | 798 | */ |
799 | static char *notify_socket = NULL; | 799 | static char *notify_socket = NULL; |
800 | 800 | ||
801 | static int mconsole_init(void) | 801 | static int __init mconsole_init(void) |
802 | { | 802 | { |
803 | /* long to avoid size mismatch warnings from gcc */ | 803 | /* long to avoid size mismatch warnings from gcc */ |
804 | long sock; | 804 | long sock; |
diff --git a/arch/um/drivers/net_kern.c b/arch/um/drivers/net_kern.c index 72773dd54425..d35d0c1ee7f4 100644 --- a/arch/um/drivers/net_kern.c +++ b/arch/um/drivers/net_kern.c | |||
@@ -623,7 +623,7 @@ static int eth_setup_common(char *str, int index) | |||
623 | return found; | 623 | return found; |
624 | } | 624 | } |
625 | 625 | ||
626 | static int eth_setup(char *str) | 626 | static int __init eth_setup(char *str) |
627 | { | 627 | { |
628 | struct eth_init *new; | 628 | struct eth_init *new; |
629 | char *error; | 629 | char *error; |
diff --git a/arch/um/kernel/mem.c b/arch/um/kernel/mem.c index 72ff85693a39..d2b11f242698 100644 --- a/arch/um/kernel/mem.c +++ b/arch/um/kernel/mem.c | |||
@@ -62,7 +62,7 @@ static void setup_highmem(unsigned long highmem_start, | |||
62 | } | 62 | } |
63 | #endif | 63 | #endif |
64 | 64 | ||
65 | void mem_init(void) | 65 | void __init mem_init(void) |
66 | { | 66 | { |
67 | /* clear the zero-page */ | 67 | /* clear the zero-page */ |
68 | memset((void *) empty_zero_page, 0, PAGE_SIZE); | 68 | memset((void *) empty_zero_page, 0, PAGE_SIZE); |
diff --git a/arch/um/kernel/physmem.c b/arch/um/kernel/physmem.c index 3ba6e4c841da..5ee7e851bbc1 100644 --- a/arch/um/kernel/physmem.c +++ b/arch/um/kernel/physmem.c | |||
@@ -28,7 +28,8 @@ unsigned long high_physmem; | |||
28 | 28 | ||
29 | extern unsigned long long physmem_size; | 29 | extern unsigned long long physmem_size; |
30 | 30 | ||
31 | int init_maps(unsigned long physmem, unsigned long iomem, unsigned long highmem) | 31 | int __init init_maps(unsigned long physmem, unsigned long iomem, |
32 | unsigned long highmem) | ||
32 | { | 33 | { |
33 | struct page *p, *map; | 34 | struct page *p, *map; |
34 | unsigned long phys_len, phys_pages, highmem_len, highmem_pages; | 35 | unsigned long phys_len, phys_pages, highmem_len, highmem_pages; |
@@ -47,13 +48,7 @@ int init_maps(unsigned long physmem, unsigned long iomem, unsigned long highmem) | |||
47 | total_pages = phys_pages + iomem_pages + highmem_pages; | 48 | total_pages = phys_pages + iomem_pages + highmem_pages; |
48 | total_len = phys_len + iomem_len + highmem_len; | 49 | total_len = phys_len + iomem_len + highmem_len; |
49 | 50 | ||
50 | if(kmalloc_ok){ | 51 | map = alloc_bootmem_low_pages(total_len); |
51 | map = kmalloc(total_len, GFP_KERNEL); | ||
52 | if(map == NULL) | ||
53 | map = vmalloc(total_len); | ||
54 | } | ||
55 | else map = alloc_bootmem_low_pages(total_len); | ||
56 | |||
57 | if(map == NULL) | 52 | if(map == NULL) |
58 | return -ENOMEM; | 53 | return -ENOMEM; |
59 | 54 | ||
@@ -98,8 +93,8 @@ void map_memory(unsigned long virt, unsigned long phys, unsigned long len, | |||
98 | 93 | ||
99 | extern int __syscall_stub_start; | 94 | extern int __syscall_stub_start; |
100 | 95 | ||
101 | void setup_physmem(unsigned long start, unsigned long reserve_end, | 96 | void __init setup_physmem(unsigned long start, unsigned long reserve_end, |
102 | unsigned long len, unsigned long long highmem) | 97 | unsigned long len, unsigned long long highmem) |
103 | { | 98 | { |
104 | unsigned long reserve = reserve_end - start; | 99 | unsigned long reserve = reserve_end - start; |
105 | int pfn = PFN_UP(__pa(reserve_end)); | 100 | int pfn = PFN_UP(__pa(reserve_end)); |
diff --git a/arch/um/kernel/skas/process.c b/arch/um/kernel/skas/process.c index 2a69a7ce5792..48051a98525f 100644 --- a/arch/um/kernel/skas/process.c +++ b/arch/um/kernel/skas/process.c | |||
@@ -145,7 +145,7 @@ void init_idle_skas(void) | |||
145 | 145 | ||
146 | extern void start_kernel(void); | 146 | extern void start_kernel(void); |
147 | 147 | ||
148 | static int start_kernel_proc(void *unused) | 148 | static int __init start_kernel_proc(void *unused) |
149 | { | 149 | { |
150 | int pid; | 150 | int pid; |
151 | 151 | ||
@@ -165,7 +165,7 @@ extern int userspace_pid[]; | |||
165 | 165 | ||
166 | extern char cpu0_irqstack[]; | 166 | extern char cpu0_irqstack[]; |
167 | 167 | ||
168 | int start_uml_skas(void) | 168 | int __init start_uml_skas(void) |
169 | { | 169 | { |
170 | stack_protections((unsigned long) &cpu0_irqstack); | 170 | stack_protections((unsigned long) &cpu0_irqstack); |
171 | set_sigstack(cpu0_irqstack, THREAD_SIZE); | 171 | set_sigstack(cpu0_irqstack, THREAD_SIZE); |
diff --git a/arch/um/os-Linux/process.c b/arch/um/os-Linux/process.c index 2d9d2ca39299..e9c143297512 100644 --- a/arch/um/os-Linux/process.c +++ b/arch/um/os-Linux/process.c | |||
@@ -194,7 +194,7 @@ int os_unmap_memory(void *addr, int len) | |||
194 | #define MADV_REMOVE KERNEL_MADV_REMOVE | 194 | #define MADV_REMOVE KERNEL_MADV_REMOVE |
195 | #endif | 195 | #endif |
196 | 196 | ||
197 | int __init os_drop_memory(void *addr, int length) | 197 | int os_drop_memory(void *addr, int length) |
198 | { | 198 | { |
199 | int err; | 199 | int err; |
200 | 200 | ||