Skip to content

Commit 76ef964

Browse files
Michael HolzheuMartin Schwidefsky
authored andcommitted
[S390] zcore: Fix reipl device detection
The reipl device information is passed from the kernel to zfcpdump using a pointer in the lowcore (0xe00) that points to the reipl information Currently if that pointer is not zero, we copy the reipl information. If the pointer is not initialized and points outside the accessible memory, it can happen that the memory copy fails. In that case we currently stop the initialization of zcore which leads to a failing kernel dump. The correct behavior is to disable the reipl after dump and continue with zcore intialization. Signed-off-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
1 parent 157a1a2 commit 76ef964

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

‎drivers/s390/char/zcore.c‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -638,11 +638,7 @@ static int __init zcore_reipl_init(void)
638638
rc = memcpy_hsa_kernel(ipl_block, ipib_info.ipib, PAGE_SIZE);
639639
else
640640
rc = memcpy_real(ipl_block, (void *) ipib_info.ipib, PAGE_SIZE);
641-
if (rc) {
642-
free_page((unsigned long) ipl_block);
643-
return rc;
644-
}
645-
if (csum_partial(ipl_block, ipl_block->hdr.len, 0) !=
641+
if (rc || csum_partial(ipl_block, ipl_block->hdr.len, 0) !=
646642
ipib_info.checksum) {
647643
TRACE("Checksum does not match\n");
648644
free_page((unsigned long) ipl_block);

0 commit comments

Comments
 (0)