Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

s390/kernel: Remove OS info init function call and diag 308 for kdump

Because of a design change for stand-alone kdump the function that
was done by the OS info init function is moved to the boot loader
code. This has two implications that are implemented by this patch:
a) The OS info init function is no longer called by the kernel
b) The diag 308 subcode 1 reset is no longer done by the kdump boot code.
This is necessary because otherwise the operation that is done now
by the boot loader would be reversed. For the normal kexec based
kdump mechansim the reset is already done by the kdump trigger code
(e.g. panic or PSW restart).

Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>

authored by

Michael Holzheu and committed by
Martin Schwidefsky
d7b7cdea 61011677

+2 -23
+2 -3
arch/s390/include/asm/os_info.h
··· 13 13 14 14 #define OS_INFO_VMCOREINFO 0 15 15 #define OS_INFO_REIPL_BLOCK 1 16 - #define OS_INFO_INIT_FN 2 17 16 18 17 struct os_info_entry { 19 18 u64 addr; ··· 27 28 u16 version_minor; 28 29 u64 crashkernel_addr; 29 30 u64 crashkernel_size; 30 - struct os_info_entry entry[3]; 31 - u8 reserved[4004]; 31 + struct os_info_entry entry[2]; 32 + u8 reserved[4024]; 32 33 } __packed; 33 34 34 35 void os_info_init(void);
-7
arch/s390/kernel/head_kdump.S
··· 85 85 basr %r13,0 86 86 0: 87 87 mvc 0(8,%r0),.Lrestart_psw-0b(%r13) # Setup restart PSW 88 - mvc 464(16,%r0),.Lpgm_psw-0b(%r13) # Setup pgm check PSW 89 - lhi %r1,1 # Start new kernel 90 - diag %r1,%r1,0x308 # with diag 308 91 - 92 - .Lno_diag308: # No diag 308 93 88 sam31 # Switch to 31 bit addr mode 94 89 sr %r1,%r1 # Erase register r1 95 90 sr %r2,%r2 # Erase register r2 ··· 93 98 .align 8 94 99 .Lrestart_psw: 95 100 .long 0x00080000,0x80000000 + startup 96 - .Lpgm_psw: 97 - .quad 0x0000000180000000,0x0000000000000000 + .Lno_diag308 98 101 #else 99 102 .align 2 100 103 .Lep_startup_kdump:
-1
arch/s390/kernel/os_info.c
··· 138 138 goto fail_free; 139 139 os_info_old_alloc(OS_INFO_VMCOREINFO, 1); 140 140 os_info_old_alloc(OS_INFO_REIPL_BLOCK, 1); 141 - os_info_old_alloc(OS_INFO_INIT_FN, PAGE_SIZE); 142 141 pr_info("crashkernel: addr=0x%lx size=%lu\n", 143 142 (unsigned long) os_info_old->crashkernel_addr, 144 143 (unsigned long) os_info_old->crashkernel_size);
-12
arch/s390/kernel/smp.c
··· 800 800 801 801 #endif /* CONFIG_HOTPLUG_CPU */ 802 802 803 - static void smp_call_os_info_init_fn(void) 804 - { 805 - int (*init_fn)(void); 806 - unsigned long size; 807 - 808 - init_fn = os_info_old_entry(OS_INFO_INIT_FN, &size); 809 - if (!init_fn) 810 - return; 811 - init_fn(); 812 - } 813 - 814 803 void __init smp_prepare_cpus(unsigned int max_cpus) 815 804 { 816 805 /* request the 0x1201 emergency signal external interrupt */ ··· 808 819 /* request the 0x1202 external call external interrupt */ 809 820 if (register_external_interrupt(0x1202, do_ext_call_interrupt) != 0) 810 821 panic("Couldn't request external interrupt 0x1202"); 811 - smp_call_os_info_init_fn(); 812 822 smp_detect_cpus(); 813 823 } 814 824