diff options
author | Maxim Samoylov <max7255@linux.vnet.ibm.com> | 2015-10-12 17:50:20 +0200 |
---|---|---|
committer | Cornelia Huck <cornelia.huck@de.ibm.com> | 2015-11-11 17:21:39 +0100 |
commit | 38150be860434de9d9c76cef71ff5c6b6112ee8f (patch) | |
tree | f10678074561d2a2cb7d327a06dde4fd4f1db67b /pc-bios/s390-ccw | |
parent | 4c292a009700755a1e6b234063ef3f2db235aaae (diff) | |
download | hqemu-38150be860434de9d9c76cef71ff5c6b6112ee8f.zip hqemu-38150be860434de9d9c76cef71ff5c6b6112ee8f.tar.gz |
pc-bios/s390-ccw: Always adjust virtio sector count
Let's always adjust the sector number to be read using the current
virtio block size value.
This prepares for the implementation of IPL from ISO-9660 media.
Signed-off-by: Maxim Samoylov <max7255@linux.vnet.ibm.com>
Reviewed-by: David Hildenbrand <dahi@linux.vnet.ibm.com>
Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Diffstat (limited to 'pc-bios/s390-ccw')
-rw-r--r-- | pc-bios/s390-ccw/virtio.h | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/pc-bios/s390-ccw/virtio.h b/pc-bios/s390-ccw/virtio.h index c23466b..76c42f1 100644 --- a/pc-bios/s390-ccw/virtio.h +++ b/pc-bios/s390-ccw/virtio.h @@ -199,14 +199,9 @@ extern int virtio_read_many(ulong sector, void *load_addr, int sec_num); #define VIRTIO_SECTOR_SIZE 512 -static inline ulong virtio_eckd_sector_adjust(ulong sector) -{ - return sector * (virtio_get_block_size() / VIRTIO_SECTOR_SIZE); -} - static inline ulong virtio_sector_adjust(ulong sector) { - return virtio_disk_is_eckd() ? virtio_eckd_sector_adjust(sector) : sector; + return sector * (virtio_get_block_size() / VIRTIO_SECTOR_SIZE); } #endif /* VIRTIO_H */ |