pc-bios/s390-ccw: fix old bug in ptr increment

We need to increment by the size of the structure, whereas 'ns' is 'uint8_t *'.

Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Eugene (jno) Dvurechenski <jno@linux.vnet.ibm.com>
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
This commit is contained in:
Eugene (jno) Dvurechenski 2016-02-15 15:30:25 +01:00 committed by Cornelia Huck
parent a006b67fe4
commit 3a3c752f0b

View File

@ -424,7 +424,7 @@ static void ipl_scsi(void)
IPL_assert(magic_match(sec, ZIPL_MAGIC), "No zIPL magic"); IPL_assert(magic_match(sec, ZIPL_MAGIC), "No zIPL magic");
ns_end = sec + virtio_get_block_size(); ns_end = sec + virtio_get_block_size();
for (ns = (sec + pte_len); (ns + pte_len) < ns_end; ns++) { for (ns = (sec + pte_len); (ns + pte_len) < ns_end; ns += pte_len) {
prog_table_entry = (ScsiBlockPtr *)ns; prog_table_entry = (ScsiBlockPtr *)ns;
if (!prog_table_entry->blockno) { if (!prog_table_entry->blockno) {
break; break;