Make the address variable a parameter of zipl_load_segment. Modify this function for reuse in the next patch, which allows loading segment or signature data to the destination memory address.
Signed-off-by: Zhuoying Cai <zy...@linux.ibm.com> --- pc-bios/s390-ccw/bootmap.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pc-bios/s390-ccw/bootmap.c b/pc-bios/s390-ccw/bootmap.c index 485b55f1bf..4fb3e99f4b 100644 --- a/pc-bios/s390-ccw/bootmap.c +++ b/pc-bios/s390-ccw/bootmap.c @@ -613,19 +613,17 @@ static int ipl_eckd(void) * IPL a SCSI disk */ -static int zipl_load_segment(ComponentEntry *entry) +static int zipl_load_segment(ComponentEntry *entry, uint64_t address) { const int max_entries = (MAX_SECTOR_SIZE / sizeof(ScsiBlockPtr)); ScsiBlockPtr *bprs = (void *)sec; const int bprs_size = sizeof(sec); block_number_t blockno; - uint64_t address; int i; char err_msg[] = "zIPL failed to read BPRS at 0xZZZZZZZZZZZZZZZZ"; char *blk_no = &err_msg[30]; /* where to print blockno in (those ZZs) */ blockno = entry->data.blockno; - address = entry->compdat.load_addr; debug_print_int("loading segment at block", blockno); debug_print_int("addr", address); @@ -685,7 +683,7 @@ static int zipl_run_normal(ComponentEntry *entry, uint8_t *tmp_sec) continue; } - if (zipl_load_segment(entry)) { + if (zipl_load_segment(entry, entry->compdat.load_addr)) { return -1; } -- 2.49.0