diff options
Diffstat (limited to 'arch/s390')
-rw-r--r-- | arch/s390/Kconfig | 3 | ||||
-rw-r--r-- | arch/s390/include/asm/compat.h | 7 | ||||
-rw-r--r-- | arch/s390/kernel/crash_dump.c | 1 | ||||
-rw-r--r-- | arch/s390/kernel/process.c | 1 | ||||
-rw-r--r-- | arch/s390/kernel/ptrace.c | 2 | ||||
-rw-r--r-- | arch/s390/kernel/setup.c | 2 | ||||
-rw-r--r-- | arch/s390/kernel/signal.c | 1 | ||||
-rw-r--r-- | arch/s390/mm/fault.c | 1 | ||||
-rw-r--r-- | arch/s390/mm/init.c | 30 | ||||
-rw-r--r-- | arch/s390/mm/mmap.c | 2 |
10 files changed, 32 insertions, 18 deletions
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig index d1727584230a..6d99a5fcc090 100644 --- a/arch/s390/Kconfig +++ b/arch/s390/Kconfig | |||
@@ -227,6 +227,9 @@ config COMPAT | |||
227 | config SYSVIPC_COMPAT | 227 | config SYSVIPC_COMPAT |
228 | def_bool y if COMPAT && SYSVIPC | 228 | def_bool y if COMPAT && SYSVIPC |
229 | 229 | ||
230 | config KEYS_COMPAT | ||
231 | def_bool y if COMPAT && KEYS | ||
232 | |||
230 | config AUDIT_ARCH | 233 | config AUDIT_ARCH |
231 | def_bool y | 234 | def_bool y |
232 | 235 | ||
diff --git a/arch/s390/include/asm/compat.h b/arch/s390/include/asm/compat.h index 2e49748b27da..234f1d859cea 100644 --- a/arch/s390/include/asm/compat.h +++ b/arch/s390/include/asm/compat.h | |||
@@ -172,13 +172,6 @@ static inline int is_compat_task(void) | |||
172 | return is_32bit_task(); | 172 | return is_32bit_task(); |
173 | } | 173 | } |
174 | 174 | ||
175 | #else | ||
176 | |||
177 | static inline int is_compat_task(void) | ||
178 | { | ||
179 | return 0; | ||
180 | } | ||
181 | |||
182 | #endif | 175 | #endif |
183 | 176 | ||
184 | static inline void __user *arch_compat_alloc_user_space(long len) | 177 | static inline void __user *arch_compat_alloc_user_space(long len) |
diff --git a/arch/s390/kernel/crash_dump.c b/arch/s390/kernel/crash_dump.c index 39f8fd4438fc..c383ce440d99 100644 --- a/arch/s390/kernel/crash_dump.c +++ b/arch/s390/kernel/crash_dump.c | |||
@@ -11,7 +11,6 @@ | |||
11 | #include <linux/module.h> | 11 | #include <linux/module.h> |
12 | #include <linux/gfp.h> | 12 | #include <linux/gfp.h> |
13 | #include <linux/slab.h> | 13 | #include <linux/slab.h> |
14 | #include <linux/crash_dump.h> | ||
15 | #include <linux/bootmem.h> | 14 | #include <linux/bootmem.h> |
16 | #include <linux/elf.h> | 15 | #include <linux/elf.h> |
17 | #include <asm/ipl.h> | 16 | #include <asm/ipl.h> |
diff --git a/arch/s390/kernel/process.c b/arch/s390/kernel/process.c index 4261aa799774..e795933eb2cb 100644 --- a/arch/s390/kernel/process.c +++ b/arch/s390/kernel/process.c | |||
@@ -29,7 +29,6 @@ | |||
29 | #include <asm/irq.h> | 29 | #include <asm/irq.h> |
30 | #include <asm/timer.h> | 30 | #include <asm/timer.h> |
31 | #include <asm/nmi.h> | 31 | #include <asm/nmi.h> |
32 | #include <asm/compat.h> | ||
33 | #include <asm/smp.h> | 32 | #include <asm/smp.h> |
34 | #include "entry.h" | 33 | #include "entry.h" |
35 | 34 | ||
diff --git a/arch/s390/kernel/ptrace.c b/arch/s390/kernel/ptrace.c index 9d82ed4bcb27..61f95489d70c 100644 --- a/arch/s390/kernel/ptrace.c +++ b/arch/s390/kernel/ptrace.c | |||
@@ -20,8 +20,8 @@ | |||
20 | #include <linux/regset.h> | 20 | #include <linux/regset.h> |
21 | #include <linux/tracehook.h> | 21 | #include <linux/tracehook.h> |
22 | #include <linux/seccomp.h> | 22 | #include <linux/seccomp.h> |
23 | #include <linux/compat.h> | ||
23 | #include <trace/syscall.h> | 24 | #include <trace/syscall.h> |
24 | #include <asm/compat.h> | ||
25 | #include <asm/segment.h> | 25 | #include <asm/segment.h> |
26 | #include <asm/page.h> | 26 | #include <asm/page.h> |
27 | #include <asm/pgtable.h> | 27 | #include <asm/pgtable.h> |
diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c index 354de0763eff..3b2efc81f34e 100644 --- a/arch/s390/kernel/setup.c +++ b/arch/s390/kernel/setup.c | |||
@@ -46,6 +46,7 @@ | |||
46 | #include <linux/kexec.h> | 46 | #include <linux/kexec.h> |
47 | #include <linux/crash_dump.h> | 47 | #include <linux/crash_dump.h> |
48 | #include <linux/memory.h> | 48 | #include <linux/memory.h> |
49 | #include <linux/compat.h> | ||
49 | 50 | ||
50 | #include <asm/ipl.h> | 51 | #include <asm/ipl.h> |
51 | #include <asm/uaccess.h> | 52 | #include <asm/uaccess.h> |
@@ -59,7 +60,6 @@ | |||
59 | #include <asm/ptrace.h> | 60 | #include <asm/ptrace.h> |
60 | #include <asm/sections.h> | 61 | #include <asm/sections.h> |
61 | #include <asm/ebcdic.h> | 62 | #include <asm/ebcdic.h> |
62 | #include <asm/compat.h> | ||
63 | #include <asm/kvm_virtio.h> | 63 | #include <asm/kvm_virtio.h> |
64 | #include <asm/diag.h> | 64 | #include <asm/diag.h> |
65 | 65 | ||
diff --git a/arch/s390/kernel/signal.c b/arch/s390/kernel/signal.c index a8ba840294ff..2d421d90fada 100644 --- a/arch/s390/kernel/signal.c +++ b/arch/s390/kernel/signal.c | |||
@@ -30,7 +30,6 @@ | |||
30 | #include <asm/ucontext.h> | 30 | #include <asm/ucontext.h> |
31 | #include <asm/uaccess.h> | 31 | #include <asm/uaccess.h> |
32 | #include <asm/lowcore.h> | 32 | #include <asm/lowcore.h> |
33 | #include <asm/compat.h> | ||
34 | #include "entry.h" | 33 | #include "entry.h" |
35 | 34 | ||
36 | #define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP))) | 35 | #define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP))) |
diff --git a/arch/s390/mm/fault.c b/arch/s390/mm/fault.c index 354dd39073ef..e8fcd928dc78 100644 --- a/arch/s390/mm/fault.c +++ b/arch/s390/mm/fault.c | |||
@@ -36,7 +36,6 @@ | |||
36 | #include <asm/pgtable.h> | 36 | #include <asm/pgtable.h> |
37 | #include <asm/irq.h> | 37 | #include <asm/irq.h> |
38 | #include <asm/mmu_context.h> | 38 | #include <asm/mmu_context.h> |
39 | #include <asm/compat.h> | ||
40 | #include "../kernel/entry.h" | 39 | #include "../kernel/entry.h" |
41 | 40 | ||
42 | #ifndef CONFIG_64BIT | 41 | #ifndef CONFIG_64BIT |
diff --git a/arch/s390/mm/init.c b/arch/s390/mm/init.c index 5d633019d8f3..50236610de83 100644 --- a/arch/s390/mm/init.c +++ b/arch/s390/mm/init.c | |||
@@ -223,16 +223,38 @@ void free_initrd_mem(unsigned long start, unsigned long end) | |||
223 | #ifdef CONFIG_MEMORY_HOTPLUG | 223 | #ifdef CONFIG_MEMORY_HOTPLUG |
224 | int arch_add_memory(int nid, u64 start, u64 size) | 224 | int arch_add_memory(int nid, u64 start, u64 size) |
225 | { | 225 | { |
226 | struct pglist_data *pgdat; | 226 | unsigned long zone_start_pfn, zone_end_pfn, nr_pages; |
227 | unsigned long start_pfn = PFN_DOWN(start); | ||
228 | unsigned long size_pages = PFN_DOWN(size); | ||
227 | struct zone *zone; | 229 | struct zone *zone; |
228 | int rc; | 230 | int rc; |
229 | 231 | ||
230 | pgdat = NODE_DATA(nid); | ||
231 | zone = pgdat->node_zones + ZONE_MOVABLE; | ||
232 | rc = vmem_add_mapping(start, size); | 232 | rc = vmem_add_mapping(start, size); |
233 | if (rc) | 233 | if (rc) |
234 | return rc; | 234 | return rc; |
235 | rc = __add_pages(nid, zone, PFN_DOWN(start), PFN_DOWN(size)); | 235 | for_each_zone(zone) { |
236 | if (zone_idx(zone) != ZONE_MOVABLE) { | ||
237 | /* Add range within existing zone limits */ | ||
238 | zone_start_pfn = zone->zone_start_pfn; | ||
239 | zone_end_pfn = zone->zone_start_pfn + | ||
240 | zone->spanned_pages; | ||
241 | } else { | ||
242 | /* Add remaining range to ZONE_MOVABLE */ | ||
243 | zone_start_pfn = start_pfn; | ||
244 | zone_end_pfn = start_pfn + size_pages; | ||
245 | } | ||
246 | if (start_pfn < zone_start_pfn || start_pfn >= zone_end_pfn) | ||
247 | continue; | ||
248 | nr_pages = (start_pfn + size_pages > zone_end_pfn) ? | ||
249 | zone_end_pfn - start_pfn : size_pages; | ||
250 | rc = __add_pages(nid, zone, start_pfn, nr_pages); | ||
251 | if (rc) | ||
252 | break; | ||
253 | start_pfn += nr_pages; | ||
254 | size_pages -= nr_pages; | ||
255 | if (!size_pages) | ||
256 | break; | ||
257 | } | ||
236 | if (rc) | 258 | if (rc) |
237 | vmem_remove_mapping(start, size); | 259 | vmem_remove_mapping(start, size); |
238 | return rc; | 260 | return rc; |
diff --git a/arch/s390/mm/mmap.c b/arch/s390/mm/mmap.c index f09c74881b7e..a0155c02e324 100644 --- a/arch/s390/mm/mmap.c +++ b/arch/s390/mm/mmap.c | |||
@@ -29,8 +29,8 @@ | |||
29 | #include <linux/mman.h> | 29 | #include <linux/mman.h> |
30 | #include <linux/module.h> | 30 | #include <linux/module.h> |
31 | #include <linux/random.h> | 31 | #include <linux/random.h> |
32 | #include <linux/compat.h> | ||
32 | #include <asm/pgalloc.h> | 33 | #include <asm/pgalloc.h> |
33 | #include <asm/compat.h> | ||
34 | 34 | ||
35 | static unsigned long stack_maxrandom_size(void) | 35 | static unsigned long stack_maxrandom_size(void) |
36 | { | 36 | { |