summaryrefslogtreecommitdiffstats
path: root/backends
diff options
context:
space:
mode:
authorMichael S. Tsirkin2013-11-21 14:34:26 +0100
committerAnthony Liguori2013-11-21 16:55:10 +0100
commit376827d48922941d16ef9949672e86f820005d0a (patch)
tree6625a70db6873cd9a7aa8bac834f09df5add4876 /backends
parentacpi-build: fix build on glib < 2.14 (diff)
downloadqemu-376827d48922941d16ef9949672e86f820005d0a.tar.gz
qemu-376827d48922941d16ef9949672e86f820005d0a.tar.xz
qemu-376827d48922941d16ef9949672e86f820005d0a.zip
s390x: fix flat file load on 32 bit systems
pc-bios/s390-zipl.rom is a flat image so it's expected that loading it as elf will fail. It should fall back on loading a flat file, but doesn't on 32 bit systems, instead it fails printing: qemu: hardware error: could not load bootloader 's390-zipl.rom' The result is boot failure. The reason is that a 64 bit unsigned interger which is set to -1 on error is compared to -1UL which on a 32 bit system with gcc is a 32 bit unsigned interger. Since both are unsigned, no sign extension takes place and comparison evaluates to non-equal. There's no reason to do clever tricks: all functions we call actually return int so just use int. And then we can use == -1 everywhere, consistently. Reviewed-by: Alexander Graf <agraf@suse.de> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Message-id: 20131121133426.GA30827@redhat.com Signed-off-by: Anthony Liguori <aliguori@amazon.com>
Diffstat (limited to 'backends')
0 files changed, 0 insertions, 0 deletions