diff options
Diffstat (limited to 'arch/s390/kernel')
-rw-r--r-- | arch/s390/kernel/compat_wrapper.c | 1 | ||||
-rw-r--r-- | arch/s390/kernel/diag.c | 4 | ||||
-rw-r--r-- | arch/s390/kernel/head.S | 95 | ||||
-rw-r--r-- | arch/s390/kernel/ipl.c | 65 | ||||
-rw-r--r-- | arch/s390/kernel/process.c | 6 | ||||
-rw-r--r-- | arch/s390/kernel/sclp.c | 2 | ||||
-rw-r--r-- | arch/s390/kernel/setup.c | 3 | ||||
-rw-r--r-- | arch/s390/kernel/syscalls.S | 1 | ||||
-rw-r--r-- | arch/s390/kernel/trace.c | 6 |
9 files changed, 63 insertions, 120 deletions
diff --git a/arch/s390/kernel/compat_wrapper.c b/arch/s390/kernel/compat_wrapper.c index 09f194052df3..fac4eeddef91 100644 --- a/arch/s390/kernel/compat_wrapper.c +++ b/arch/s390/kernel/compat_wrapper.c | |||
@@ -176,3 +176,4 @@ COMPAT_SYSCALL_WRAP4(accept4, int, fd, struct sockaddr __user *, upeer_sockaddr, | |||
176 | COMPAT_SYSCALL_WRAP3(getsockname, int, fd, struct sockaddr __user *, usockaddr, int __user *, usockaddr_len); | 176 | COMPAT_SYSCALL_WRAP3(getsockname, int, fd, struct sockaddr __user *, usockaddr, int __user *, usockaddr_len); |
177 | COMPAT_SYSCALL_WRAP3(getpeername, int, fd, struct sockaddr __user *, usockaddr, int __user *, usockaddr_len); | 177 | COMPAT_SYSCALL_WRAP3(getpeername, int, fd, struct sockaddr __user *, usockaddr, int __user *, usockaddr_len); |
178 | COMPAT_SYSCALL_WRAP6(sendto, int, fd, void __user *, buff, size_t, len, unsigned int, flags, struct sockaddr __user *, addr, int, addr_len); | 178 | COMPAT_SYSCALL_WRAP6(sendto, int, fd, void __user *, buff, size_t, len, unsigned int, flags, struct sockaddr __user *, addr, int, addr_len); |
179 | COMPAT_SYSCALL_WRAP3(mlock2, unsigned long, start, size_t, len, int, flags); | ||
diff --git a/arch/s390/kernel/diag.c b/arch/s390/kernel/diag.c index f98766ede4e1..48b37b8357e6 100644 --- a/arch/s390/kernel/diag.c +++ b/arch/s390/kernel/diag.c | |||
@@ -121,14 +121,14 @@ device_initcall(show_diag_stat_init); | |||
121 | void diag_stat_inc(enum diag_stat_enum nr) | 121 | void diag_stat_inc(enum diag_stat_enum nr) |
122 | { | 122 | { |
123 | this_cpu_inc(diag_stat.counter[nr]); | 123 | this_cpu_inc(diag_stat.counter[nr]); |
124 | trace_diagnose(diag_map[nr].code); | 124 | trace_s390_diagnose(diag_map[nr].code); |
125 | } | 125 | } |
126 | EXPORT_SYMBOL(diag_stat_inc); | 126 | EXPORT_SYMBOL(diag_stat_inc); |
127 | 127 | ||
128 | void diag_stat_inc_norecursion(enum diag_stat_enum nr) | 128 | void diag_stat_inc_norecursion(enum diag_stat_enum nr) |
129 | { | 129 | { |
130 | this_cpu_inc(diag_stat.counter[nr]); | 130 | this_cpu_inc(diag_stat.counter[nr]); |
131 | trace_diagnose_norecursion(diag_map[nr].code); | 131 | trace_s390_diagnose_norecursion(diag_map[nr].code); |
132 | } | 132 | } |
133 | EXPORT_SYMBOL(diag_stat_inc_norecursion); | 133 | EXPORT_SYMBOL(diag_stat_inc_norecursion); |
134 | 134 | ||
diff --git a/arch/s390/kernel/head.S b/arch/s390/kernel/head.S index 1255c6c5353e..301ee9c70688 100644 --- a/arch/s390/kernel/head.S +++ b/arch/s390/kernel/head.S | |||
@@ -26,6 +26,7 @@ | |||
26 | #include <asm/asm-offsets.h> | 26 | #include <asm/asm-offsets.h> |
27 | #include <asm/thread_info.h> | 27 | #include <asm/thread_info.h> |
28 | #include <asm/page.h> | 28 | #include <asm/page.h> |
29 | #include <asm/ptrace.h> | ||
29 | 30 | ||
30 | #define ARCH_OFFSET 4 | 31 | #define ARCH_OFFSET 4 |
31 | 32 | ||
@@ -59,19 +60,6 @@ __HEAD | |||
59 | .long 0x020006e0,0x20000050 | 60 | .long 0x020006e0,0x20000050 |
60 | 61 | ||
61 | .org 0x200 | 62 | .org 0x200 |
62 | # | ||
63 | # subroutine to set architecture mode | ||
64 | # | ||
65 | .Lsetmode: | ||
66 | mvi __LC_AR_MODE_ID,1 # set esame flag | ||
67 | slr %r0,%r0 # set cpuid to zero | ||
68 | lhi %r1,2 # mode 2 = esame (dump) | ||
69 | sigp %r1,%r0,0x12 # switch to esame mode | ||
70 | bras %r13,0f | ||
71 | .fill 16,4,0x0 | ||
72 | 0: lmh %r0,%r15,0(%r13) # clear high-order half of gprs | ||
73 | sam31 # switch to 31 bit addressing mode | ||
74 | br %r14 | ||
75 | 63 | ||
76 | # | 64 | # |
77 | # subroutine to wait for end I/O | 65 | # subroutine to wait for end I/O |
@@ -159,7 +147,14 @@ __HEAD | |||
159 | .long 0x02200050,0x00000000 | 147 | .long 0x02200050,0x00000000 |
160 | 148 | ||
161 | iplstart: | 149 | iplstart: |
162 | bas %r14,.Lsetmode # Immediately switch to 64 bit mode | 150 | mvi __LC_AR_MODE_ID,1 # set esame flag |
151 | slr %r0,%r0 # set cpuid to zero | ||
152 | lhi %r1,2 # mode 2 = esame (dump) | ||
153 | sigp %r1,%r0,0x12 # switch to esame mode | ||
154 | bras %r13,0f | ||
155 | .fill 16,4,0x0 | ||
156 | 0: lmh %r0,%r15,0(%r13) # clear high-order half of gprs | ||
157 | sam31 # switch to 31 bit addressing mode | ||
163 | lh %r1,0xb8 # test if subchannel number | 158 | lh %r1,0xb8 # test if subchannel number |
164 | bct %r1,.Lnoload # is valid | 159 | bct %r1,.Lnoload # is valid |
165 | l %r1,0xb8 # load ipl subchannel number | 160 | l %r1,0xb8 # load ipl subchannel number |
@@ -269,71 +264,6 @@ iplstart: | |||
269 | .Lcpuid:.fill 8,1,0 | 264 | .Lcpuid:.fill 8,1,0 |
270 | 265 | ||
271 | # | 266 | # |
272 | # SALIPL loader support. Based on a patch by Rob van der Heij. | ||
273 | # This entry point is called directly from the SALIPL loader and | ||
274 | # doesn't need a builtin ipl record. | ||
275 | # | ||
276 | .org 0x800 | ||
277 | ENTRY(start) | ||
278 | stm %r0,%r15,0x07b0 # store registers | ||
279 | bas %r14,.Lsetmode # Immediately switch to 64 bit mode | ||
280 | basr %r12,%r0 | ||
281 | .base: | ||
282 | l %r11,.parm | ||
283 | l %r8,.cmd # pointer to command buffer | ||
284 | |||
285 | ltr %r9,%r9 # do we have SALIPL parameters? | ||
286 | bp .sk8x8 | ||
287 | |||
288 | mvc 0(64,%r8),0x00b0 # copy saved registers | ||
289 | xc 64(240-64,%r8),0(%r8) # remainder of buffer | ||
290 | tr 0(64,%r8),.lowcase | ||
291 | b .gotr | ||
292 | .sk8x8: | ||
293 | mvc 0(240,%r8),0(%r9) # copy iplparms into buffer | ||
294 | .gotr: | ||
295 | slr %r0,%r0 | ||
296 | st %r0,INITRD_SIZE+ARCH_OFFSET-PARMAREA(%r11) | ||
297 | st %r0,INITRD_START+ARCH_OFFSET-PARMAREA(%r11) | ||
298 | j startup # continue with startup | ||
299 | .cmd: .long COMMAND_LINE # address of command line buffer | ||
300 | .parm: .long PARMAREA | ||
301 | .lowcase: | ||
302 | .byte 0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07 | ||
303 | .byte 0x08,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f | ||
304 | .byte 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17 | ||
305 | .byte 0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f | ||
306 | .byte 0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27 | ||
307 | .byte 0x28,0x29,0x2a,0x2b,0x2c,0x2d,0x2e,0x2f | ||
308 | .byte 0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37 | ||
309 | .byte 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f | ||
310 | .byte 0x40,0x41,0x42,0x43,0x44,0x45,0x46,0x47 | ||
311 | .byte 0x48,0x49,0x4a,0x4b,0x4c,0x4d,0x4e,0x4f | ||
312 | .byte 0x50,0x51,0x52,0x53,0x54,0x55,0x56,0x57 | ||
313 | .byte 0x58,0x59,0x5a,0x5b,0x5c,0x5d,0x5e,0x5f | ||
314 | .byte 0x60,0x61,0x62,0x63,0x64,0x65,0x66,0x67 | ||
315 | .byte 0x68,0x69,0x6a,0x6b,0x6c,0x6d,0x6e,0x6f | ||
316 | .byte 0x70,0x71,0x72,0x73,0x74,0x75,0x76,0x77 | ||
317 | .byte 0x78,0x79,0x7a,0x7b,0x7c,0x7d,0x7e,0x7f | ||
318 | |||
319 | .byte 0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87 | ||
320 | .byte 0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f | ||
321 | .byte 0x90,0x91,0x92,0x93,0x94,0x95,0x96,0x97 | ||
322 | .byte 0x98,0x99,0x9a,0x9b,0x9c,0x9d,0x9e,0x9f | ||
323 | .byte 0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7 | ||
324 | .byte 0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf | ||
325 | .byte 0xb0,0xb1,0xb2,0xb3,0xb4,0xb5,0xb6,0xb7 | ||
326 | .byte 0xb8,0xb9,0xba,0xbb,0xbc,0xbd,0xbe,0xbf | ||
327 | .byte 0xc0,0x81,0x82,0x83,0x84,0x85,0x86,0x87 # .abcdefg | ||
328 | .byte 0x88,0x89,0xca,0xcb,0xcc,0xcd,0xce,0xcf # hi | ||
329 | .byte 0xd0,0x91,0x92,0x93,0x94,0x95,0x96,0x97 # .jklmnop | ||
330 | .byte 0x98,0x99,0xda,0xdb,0xdc,0xdd,0xde,0xdf # qr | ||
331 | .byte 0xe0,0xe1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7 # ..stuvwx | ||
332 | .byte 0xa8,0xa9,0xea,0xeb,0xec,0xed,0xee,0xef # yz | ||
333 | .byte 0xf0,0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7 | ||
334 | .byte 0xf8,0xf9,0xfa,0xfb,0xfc,0xfd,0xfe,0xff | ||
335 | |||
336 | # | ||
337 | # startup-code at 0x10000, running in absolute addressing mode | 267 | # startup-code at 0x10000, running in absolute addressing mode |
338 | # this is called either by the ipl loader or directly by PSW restart | 268 | # this is called either by the ipl loader or directly by PSW restart |
339 | # or linload or SALIPL | 269 | # or linload or SALIPL |
@@ -364,7 +294,7 @@ ENTRY(startup_kdump) | |||
364 | bras %r13,0f | 294 | bras %r13,0f |
365 | .fill 16,4,0x0 | 295 | .fill 16,4,0x0 |
366 | 0: lmh %r0,%r15,0(%r13) # clear high-order half of gprs | 296 | 0: lmh %r0,%r15,0(%r13) # clear high-order half of gprs |
367 | sam31 # switch to 31 bit addressing mode | 297 | sam64 # switch to 64 bit addressing mode |
368 | basr %r13,0 # get base | 298 | basr %r13,0 # get base |
369 | .LPG0: | 299 | .LPG0: |
370 | xc 0x200(256),0x200 # partially clear lowcore | 300 | xc 0x200(256),0x200 # partially clear lowcore |
@@ -395,7 +325,7 @@ ENTRY(startup_kdump) | |||
395 | jnz 1b | 325 | jnz 1b |
396 | j 4f | 326 | j 4f |
397 | 2: l %r15,.Lstack-.LPG0(%r13) | 327 | 2: l %r15,.Lstack-.LPG0(%r13) |
398 | ahi %r15,-96 | 328 | ahi %r15,-STACK_FRAME_OVERHEAD |
399 | la %r2,.Lals_string-.LPG0(%r13) | 329 | la %r2,.Lals_string-.LPG0(%r13) |
400 | l %r3,.Lsclp_print-.LPG0(%r13) | 330 | l %r3,.Lsclp_print-.LPG0(%r13) |
401 | basr %r14,%r3 | 331 | basr %r14,%r3 |
@@ -429,8 +359,7 @@ ENTRY(startup_kdump) | |||
429 | .long 1, 0xc0000000 | 359 | .long 1, 0xc0000000 |
430 | #endif | 360 | #endif |
431 | 4: | 361 | 4: |
432 | /* Continue with 64bit startup code in head64.S */ | 362 | /* Continue with startup code in head64.S */ |
433 | sam64 # switch to 64 bit mode | ||
434 | jg startup_continue | 363 | jg startup_continue |
435 | 364 | ||
436 | .align 8 | 365 | .align 8 |
diff --git a/arch/s390/kernel/ipl.c b/arch/s390/kernel/ipl.c index f6d8acd7e136..b1f0a90f933b 100644 --- a/arch/s390/kernel/ipl.c +++ b/arch/s390/kernel/ipl.c | |||
@@ -121,6 +121,7 @@ static char *dump_type_str(enum dump_type type) | |||
121 | * Must be in data section since the bss section | 121 | * Must be in data section since the bss section |
122 | * is not cleared when these are accessed. | 122 | * is not cleared when these are accessed. |
123 | */ | 123 | */ |
124 | static u8 ipl_ssid __attribute__((__section__(".data"))) = 0; | ||
124 | static u16 ipl_devno __attribute__((__section__(".data"))) = 0; | 125 | static u16 ipl_devno __attribute__((__section__(".data"))) = 0; |
125 | u32 ipl_flags __attribute__((__section__(".data"))) = 0; | 126 | u32 ipl_flags __attribute__((__section__(".data"))) = 0; |
126 | 127 | ||
@@ -197,6 +198,33 @@ static ssize_t sys_##_prefix##_##_name##_show(struct kobject *kobj, \ | |||
197 | return snprintf(page, PAGE_SIZE, _format, ##args); \ | 198 | return snprintf(page, PAGE_SIZE, _format, ##args); \ |
198 | } | 199 | } |
199 | 200 | ||
201 | #define IPL_ATTR_CCW_STORE_FN(_prefix, _name, _ipl_blk) \ | ||
202 | static ssize_t sys_##_prefix##_##_name##_store(struct kobject *kobj, \ | ||
203 | struct kobj_attribute *attr, \ | ||
204 | const char *buf, size_t len) \ | ||
205 | { \ | ||
206 | unsigned long long ssid, devno; \ | ||
207 | \ | ||
208 | if (sscanf(buf, "0.%llx.%llx\n", &ssid, &devno) != 2) \ | ||
209 | return -EINVAL; \ | ||
210 | \ | ||
211 | if (ssid > __MAX_SSID || devno > __MAX_SUBCHANNEL) \ | ||
212 | return -EINVAL; \ | ||
213 | \ | ||
214 | _ipl_blk.ssid = ssid; \ | ||
215 | _ipl_blk.devno = devno; \ | ||
216 | return len; \ | ||
217 | } | ||
218 | |||
219 | #define DEFINE_IPL_CCW_ATTR_RW(_prefix, _name, _ipl_blk) \ | ||
220 | IPL_ATTR_SHOW_FN(_prefix, _name, "0.%x.%04x\n", \ | ||
221 | _ipl_blk.ssid, _ipl_blk.devno); \ | ||
222 | IPL_ATTR_CCW_STORE_FN(_prefix, _name, _ipl_blk); \ | ||
223 | static struct kobj_attribute sys_##_prefix##_##_name##_attr = \ | ||
224 | __ATTR(_name, (S_IRUGO | S_IWUSR), \ | ||
225 | sys_##_prefix##_##_name##_show, \ | ||
226 | sys_##_prefix##_##_name##_store) \ | ||
227 | |||
200 | #define DEFINE_IPL_ATTR_RO(_prefix, _name, _format, _value) \ | 228 | #define DEFINE_IPL_ATTR_RO(_prefix, _name, _format, _value) \ |
201 | IPL_ATTR_SHOW_FN(_prefix, _name, _format, _value) \ | 229 | IPL_ATTR_SHOW_FN(_prefix, _name, _format, _value) \ |
202 | static struct kobj_attribute sys_##_prefix##_##_name##_attr = \ | 230 | static struct kobj_attribute sys_##_prefix##_##_name##_attr = \ |
@@ -395,7 +423,7 @@ static ssize_t sys_ipl_device_show(struct kobject *kobj, | |||
395 | 423 | ||
396 | switch (ipl_info.type) { | 424 | switch (ipl_info.type) { |
397 | case IPL_TYPE_CCW: | 425 | case IPL_TYPE_CCW: |
398 | return sprintf(page, "0.0.%04x\n", ipl_devno); | 426 | return sprintf(page, "0.%x.%04x\n", ipl_ssid, ipl_devno); |
399 | case IPL_TYPE_FCP: | 427 | case IPL_TYPE_FCP: |
400 | case IPL_TYPE_FCP_DUMP: | 428 | case IPL_TYPE_FCP_DUMP: |
401 | return sprintf(page, "0.0.%04x\n", ipl->ipl_info.fcp.devno); | 429 | return sprintf(page, "0.0.%04x\n", ipl->ipl_info.fcp.devno); |
@@ -687,21 +715,14 @@ static ssize_t reipl_fcp_scpdata_write(struct file *filp, struct kobject *kobj, | |||
687 | struct bin_attribute *attr, | 715 | struct bin_attribute *attr, |
688 | char *buf, loff_t off, size_t count) | 716 | char *buf, loff_t off, size_t count) |
689 | { | 717 | { |
718 | size_t scpdata_len = count; | ||
690 | size_t padding; | 719 | size_t padding; |
691 | size_t scpdata_len; | ||
692 | |||
693 | if (off < 0) | ||
694 | return -EINVAL; | ||
695 | 720 | ||
696 | if (off >= DIAG308_SCPDATA_SIZE) | ||
697 | return -ENOSPC; | ||
698 | 721 | ||
699 | if (count > DIAG308_SCPDATA_SIZE - off) | 722 | if (off) |
700 | count = DIAG308_SCPDATA_SIZE - off; | 723 | return -EINVAL; |
701 | |||
702 | memcpy(reipl_block_fcp->ipl_info.fcp.scp_data, buf + off, count); | ||
703 | scpdata_len = off + count; | ||
704 | 724 | ||
725 | memcpy(reipl_block_fcp->ipl_info.fcp.scp_data, buf, count); | ||
705 | if (scpdata_len % 8) { | 726 | if (scpdata_len % 8) { |
706 | padding = 8 - (scpdata_len % 8); | 727 | padding = 8 - (scpdata_len % 8); |
707 | memset(reipl_block_fcp->ipl_info.fcp.scp_data + scpdata_len, | 728 | memset(reipl_block_fcp->ipl_info.fcp.scp_data + scpdata_len, |
@@ -717,7 +738,7 @@ static ssize_t reipl_fcp_scpdata_write(struct file *filp, struct kobject *kobj, | |||
717 | } | 738 | } |
718 | static struct bin_attribute sys_reipl_fcp_scp_data_attr = | 739 | static struct bin_attribute sys_reipl_fcp_scp_data_attr = |
719 | __BIN_ATTR(scp_data, (S_IRUGO | S_IWUSR), reipl_fcp_scpdata_read, | 740 | __BIN_ATTR(scp_data, (S_IRUGO | S_IWUSR), reipl_fcp_scpdata_read, |
720 | reipl_fcp_scpdata_write, PAGE_SIZE); | 741 | reipl_fcp_scpdata_write, DIAG308_SCPDATA_SIZE); |
721 | 742 | ||
722 | static struct bin_attribute *reipl_fcp_bin_attrs[] = { | 743 | static struct bin_attribute *reipl_fcp_bin_attrs[] = { |
723 | &sys_reipl_fcp_scp_data_attr, | 744 | &sys_reipl_fcp_scp_data_attr, |
@@ -814,9 +835,7 @@ static struct attribute_group reipl_fcp_attr_group = { | |||
814 | }; | 835 | }; |
815 | 836 | ||
816 | /* CCW reipl device attributes */ | 837 | /* CCW reipl device attributes */ |
817 | 838 | DEFINE_IPL_CCW_ATTR_RW(reipl_ccw, device, reipl_block_ccw->ipl_info.ccw); | |
818 | DEFINE_IPL_ATTR_RW(reipl_ccw, device, "0.0.%04llx\n", "0.0.%llx\n", | ||
819 | reipl_block_ccw->ipl_info.ccw.devno); | ||
820 | 839 | ||
821 | /* NSS wrapper */ | 840 | /* NSS wrapper */ |
822 | static ssize_t reipl_nss_loadparm_show(struct kobject *kobj, | 841 | static ssize_t reipl_nss_loadparm_show(struct kobject *kobj, |
@@ -1056,8 +1075,8 @@ static void __reipl_run(void *unused) | |||
1056 | 1075 | ||
1057 | switch (reipl_method) { | 1076 | switch (reipl_method) { |
1058 | case REIPL_METHOD_CCW_CIO: | 1077 | case REIPL_METHOD_CCW_CIO: |
1078 | devid.ssid = reipl_block_ccw->ipl_info.ccw.ssid; | ||
1059 | devid.devno = reipl_block_ccw->ipl_info.ccw.devno; | 1079 | devid.devno = reipl_block_ccw->ipl_info.ccw.devno; |
1060 | devid.ssid = 0; | ||
1061 | reipl_ccw_dev(&devid); | 1080 | reipl_ccw_dev(&devid); |
1062 | break; | 1081 | break; |
1063 | case REIPL_METHOD_CCW_VM: | 1082 | case REIPL_METHOD_CCW_VM: |
@@ -1192,6 +1211,7 @@ static int __init reipl_ccw_init(void) | |||
1192 | 1211 | ||
1193 | reipl_block_ccw_init(reipl_block_ccw); | 1212 | reipl_block_ccw_init(reipl_block_ccw); |
1194 | if (ipl_info.type == IPL_TYPE_CCW) { | 1213 | if (ipl_info.type == IPL_TYPE_CCW) { |
1214 | reipl_block_ccw->ipl_info.ccw.ssid = ipl_ssid; | ||
1195 | reipl_block_ccw->ipl_info.ccw.devno = ipl_devno; | 1215 | reipl_block_ccw->ipl_info.ccw.devno = ipl_devno; |
1196 | reipl_block_ccw_fill_parms(reipl_block_ccw); | 1216 | reipl_block_ccw_fill_parms(reipl_block_ccw); |
1197 | } | 1217 | } |
@@ -1336,9 +1356,7 @@ static struct attribute_group dump_fcp_attr_group = { | |||
1336 | }; | 1356 | }; |
1337 | 1357 | ||
1338 | /* CCW dump device attributes */ | 1358 | /* CCW dump device attributes */ |
1339 | 1359 | DEFINE_IPL_CCW_ATTR_RW(dump_ccw, device, dump_block_ccw->ipl_info.ccw); | |
1340 | DEFINE_IPL_ATTR_RW(dump_ccw, device, "0.0.%04llx\n", "0.0.%llx\n", | ||
1341 | dump_block_ccw->ipl_info.ccw.devno); | ||
1342 | 1360 | ||
1343 | static struct attribute *dump_ccw_attrs[] = { | 1361 | static struct attribute *dump_ccw_attrs[] = { |
1344 | &sys_dump_ccw_device_attr.attr, | 1362 | &sys_dump_ccw_device_attr.attr, |
@@ -1418,8 +1436,8 @@ static void __dump_run(void *unused) | |||
1418 | 1436 | ||
1419 | switch (dump_method) { | 1437 | switch (dump_method) { |
1420 | case DUMP_METHOD_CCW_CIO: | 1438 | case DUMP_METHOD_CCW_CIO: |
1439 | devid.ssid = dump_block_ccw->ipl_info.ccw.ssid; | ||
1421 | devid.devno = dump_block_ccw->ipl_info.ccw.devno; | 1440 | devid.devno = dump_block_ccw->ipl_info.ccw.devno; |
1422 | devid.ssid = 0; | ||
1423 | reipl_ccw_dev(&devid); | 1441 | reipl_ccw_dev(&devid); |
1424 | break; | 1442 | break; |
1425 | case DUMP_METHOD_CCW_VM: | 1443 | case DUMP_METHOD_CCW_VM: |
@@ -1939,14 +1957,14 @@ void __init setup_ipl(void) | |||
1939 | ipl_info.type = get_ipl_type(); | 1957 | ipl_info.type = get_ipl_type(); |
1940 | switch (ipl_info.type) { | 1958 | switch (ipl_info.type) { |
1941 | case IPL_TYPE_CCW: | 1959 | case IPL_TYPE_CCW: |
1960 | ipl_info.data.ccw.dev_id.ssid = ipl_ssid; | ||
1942 | ipl_info.data.ccw.dev_id.devno = ipl_devno; | 1961 | ipl_info.data.ccw.dev_id.devno = ipl_devno; |
1943 | ipl_info.data.ccw.dev_id.ssid = 0; | ||
1944 | break; | 1962 | break; |
1945 | case IPL_TYPE_FCP: | 1963 | case IPL_TYPE_FCP: |
1946 | case IPL_TYPE_FCP_DUMP: | 1964 | case IPL_TYPE_FCP_DUMP: |
1965 | ipl_info.data.fcp.dev_id.ssid = 0; | ||
1947 | ipl_info.data.fcp.dev_id.devno = | 1966 | ipl_info.data.fcp.dev_id.devno = |
1948 | IPL_PARMBLOCK_START->ipl_info.fcp.devno; | 1967 | IPL_PARMBLOCK_START->ipl_info.fcp.devno; |
1949 | ipl_info.data.fcp.dev_id.ssid = 0; | ||
1950 | ipl_info.data.fcp.wwpn = IPL_PARMBLOCK_START->ipl_info.fcp.wwpn; | 1968 | ipl_info.data.fcp.wwpn = IPL_PARMBLOCK_START->ipl_info.fcp.wwpn; |
1951 | ipl_info.data.fcp.lun = IPL_PARMBLOCK_START->ipl_info.fcp.lun; | 1969 | ipl_info.data.fcp.lun = IPL_PARMBLOCK_START->ipl_info.fcp.lun; |
1952 | break; | 1970 | break; |
@@ -1978,6 +1996,7 @@ void __init ipl_save_parameters(void) | |||
1978 | if (cio_get_iplinfo(&iplinfo)) | 1996 | if (cio_get_iplinfo(&iplinfo)) |
1979 | return; | 1997 | return; |
1980 | 1998 | ||
1999 | ipl_ssid = iplinfo.ssid; | ||
1981 | ipl_devno = iplinfo.devno; | 2000 | ipl_devno = iplinfo.devno; |
1982 | ipl_flags |= IPL_DEVNO_VALID; | 2001 | ipl_flags |= IPL_DEVNO_VALID; |
1983 | if (!iplinfo.is_qdio) | 2002 | if (!iplinfo.is_qdio) |
diff --git a/arch/s390/kernel/process.c b/arch/s390/kernel/process.c index 688a3aad9c79..114ee8b96f17 100644 --- a/arch/s390/kernel/process.c +++ b/arch/s390/kernel/process.c | |||
@@ -243,11 +243,7 @@ unsigned long arch_align_stack(unsigned long sp) | |||
243 | 243 | ||
244 | static inline unsigned long brk_rnd(void) | 244 | static inline unsigned long brk_rnd(void) |
245 | { | 245 | { |
246 | /* 8MB for 32bit, 1GB for 64bit */ | 246 | return (get_random_int() & BRK_RND_MASK) << PAGE_SHIFT; |
247 | if (is_32bit_task()) | ||
248 | return (get_random_int() & 0x7ffUL) << PAGE_SHIFT; | ||
249 | else | ||
250 | return (get_random_int() & 0x3ffffUL) << PAGE_SHIFT; | ||
251 | } | 247 | } |
252 | 248 | ||
253 | unsigned long arch_randomize_brk(struct mm_struct *mm) | 249 | unsigned long arch_randomize_brk(struct mm_struct *mm) |
diff --git a/arch/s390/kernel/sclp.c b/arch/s390/kernel/sclp.c index fa0bdff1d413..9fe7781a45cd 100644 --- a/arch/s390/kernel/sclp.c +++ b/arch/s390/kernel/sclp.c | |||
@@ -21,7 +21,7 @@ static void _sclp_wait_int(void) | |||
21 | __ctl_load(cr0_new, 0, 0); | 21 | __ctl_load(cr0_new, 0, 0); |
22 | 22 | ||
23 | psw_ext_save = S390_lowcore.external_new_psw; | 23 | psw_ext_save = S390_lowcore.external_new_psw; |
24 | psw_mask = __extract_psw() & (PSW_MASK_EA | PSW_MASK_BA); | 24 | psw_mask = __extract_psw(); |
25 | S390_lowcore.external_new_psw.mask = psw_mask; | 25 | S390_lowcore.external_new_psw.mask = psw_mask; |
26 | psw_wait.mask = psw_mask | PSW_MASK_EXT | PSW_MASK_WAIT; | 26 | psw_wait.mask = psw_mask | PSW_MASK_EXT | PSW_MASK_WAIT; |
27 | S390_lowcore.ext_int_code = 0; | 27 | S390_lowcore.ext_int_code = 0; |
diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c index ce0cbd6ba7ca..c837bcacf218 100644 --- a/arch/s390/kernel/setup.c +++ b/arch/s390/kernel/setup.c | |||
@@ -764,9 +764,6 @@ static int __init setup_hwcaps(void) | |||
764 | get_cpu_id(&cpu_id); | 764 | get_cpu_id(&cpu_id); |
765 | add_device_randomness(&cpu_id, sizeof(cpu_id)); | 765 | add_device_randomness(&cpu_id, sizeof(cpu_id)); |
766 | switch (cpu_id.machine) { | 766 | switch (cpu_id.machine) { |
767 | case 0x9672: | ||
768 | strcpy(elf_platform, "g5"); | ||
769 | break; | ||
770 | case 0x2064: | 767 | case 0x2064: |
771 | case 0x2066: | 768 | case 0x2066: |
772 | default: /* Use "z900" as default for 64 bit kernels. */ | 769 | default: /* Use "z900" as default for 64 bit kernels. */ |
diff --git a/arch/s390/kernel/syscalls.S b/arch/s390/kernel/syscalls.S index 8c56929c8d82..5378c3ea1b98 100644 --- a/arch/s390/kernel/syscalls.S +++ b/arch/s390/kernel/syscalls.S | |||
@@ -382,3 +382,4 @@ SYSCALL(sys_sendmsg,compat_sys_sendmsg) /* 370 */ | |||
382 | SYSCALL(sys_recvfrom,compat_sys_recvfrom) | 382 | SYSCALL(sys_recvfrom,compat_sys_recvfrom) |
383 | SYSCALL(sys_recvmsg,compat_sys_recvmsg) | 383 | SYSCALL(sys_recvmsg,compat_sys_recvmsg) |
384 | SYSCALL(sys_shutdown,sys_shutdown) | 384 | SYSCALL(sys_shutdown,sys_shutdown) |
385 | SYSCALL(sys_mlock2,compat_sys_mlock2) | ||
diff --git a/arch/s390/kernel/trace.c b/arch/s390/kernel/trace.c index 73239bb576c4..21a5df99552b 100644 --- a/arch/s390/kernel/trace.c +++ b/arch/s390/kernel/trace.c | |||
@@ -9,11 +9,11 @@ | |||
9 | #define CREATE_TRACE_POINTS | 9 | #define CREATE_TRACE_POINTS |
10 | #include <asm/trace/diag.h> | 10 | #include <asm/trace/diag.h> |
11 | 11 | ||
12 | EXPORT_TRACEPOINT_SYMBOL(diagnose); | 12 | EXPORT_TRACEPOINT_SYMBOL(s390_diagnose); |
13 | 13 | ||
14 | static DEFINE_PER_CPU(unsigned int, diagnose_trace_depth); | 14 | static DEFINE_PER_CPU(unsigned int, diagnose_trace_depth); |
15 | 15 | ||
16 | void trace_diagnose_norecursion(int diag_nr) | 16 | void trace_s390_diagnose_norecursion(int diag_nr) |
17 | { | 17 | { |
18 | unsigned long flags; | 18 | unsigned long flags; |
19 | unsigned int *depth; | 19 | unsigned int *depth; |
@@ -22,7 +22,7 @@ void trace_diagnose_norecursion(int diag_nr) | |||
22 | depth = this_cpu_ptr(&diagnose_trace_depth); | 22 | depth = this_cpu_ptr(&diagnose_trace_depth); |
23 | if (*depth == 0) { | 23 | if (*depth == 0) { |
24 | (*depth)++; | 24 | (*depth)++; |
25 | trace_diagnose(diag_nr); | 25 | trace_s390_diagnose(diag_nr); |
26 | (*depth)--; | 26 | (*depth)--; |
27 | } | 27 | } |
28 | local_irq_restore(flags); | 28 | local_irq_restore(flags); |