From patchwork Fri Mar 14 15:17:09 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Borntraeger X-Patchwork-Id: 330346 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3742A2C00BE for ; Sat, 15 Mar 2014 02:19:30 +1100 (EST) Received: from localhost ([::1]:45284 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WOTtP-00063r-U8 for incoming@patchwork.ozlabs.org; Fri, 14 Mar 2014 11:19:27 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58084) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WOTr5-0001Le-01 for qemu-devel@nongnu.org; Fri, 14 Mar 2014 11:17:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WOTqw-0004sT-JB for qemu-devel@nongnu.org; Fri, 14 Mar 2014 11:17:02 -0400 Received: from e06smtp18.uk.ibm.com ([195.75.94.114]:48095) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WOTqw-0004sC-1q for qemu-devel@nongnu.org; Fri, 14 Mar 2014 11:16:54 -0400 Received: from /spool/local by e06smtp18.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 14 Mar 2014 15:16:53 -0000 Received: from d06dlp02.portsmouth.uk.ibm.com (9.149.20.14) by e06smtp18.uk.ibm.com (192.168.101.148) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Fri, 14 Mar 2014 15:16:51 -0000 Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by d06dlp02.portsmouth.uk.ibm.com (Postfix) with ESMTP id 74F73219005C for ; Fri, 14 Mar 2014 15:16:46 +0000 (GMT) Received: from d06av10.portsmouth.uk.ibm.com (d06av10.portsmouth.uk.ibm.com [9.149.37.251]) by b06cxnps4074.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id s2EFGd2R196896 for ; Fri, 14 Mar 2014 15:16:39 GMT Received: from d06av10.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s2EFGomQ028319 for ; Fri, 14 Mar 2014 09:16:50 -0600 Received: from tuxmaker.boeblingen.de.ibm.com (tuxmaker.boeblingen.de.ibm.com [9.152.85.9]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id s2EFGoWo028307; Fri, 14 Mar 2014 09:16:50 -0600 Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 2F387122443E; Fri, 14 Mar 2014 16:16:50 +0100 (CET) From: Christian Borntraeger To: qemu-devel Date: Fri, 14 Mar 2014 16:17:09 +0100 Message-Id: <1394810232-9079-2-git-send-email-borntraeger@de.ibm.com> X-Mailer: git-send-email 1.8.4.2 In-Reply-To: <1394810232-9079-1-git-send-email-borntraeger@de.ibm.com> References: <1394810232-9079-1-git-send-email-borntraeger@de.ibm.com> X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 14031415-6892-0000-0000-00000820AAEA X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 195.75.94.114 Cc: Alexey Kardashevskiy , Alexander Graf , Christian Borntraeger , Jens Freimann , Cornelia Huck , Richard Henderson Subject: [Qemu-devel] [PATCH 1/4] s390/ipl: Fix error path on BIOS loading X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org commit 18674b26788a9e47f1157170234e32ece2044367 (elf-loader: add more return codes) enabled the elf loader to return other errors than -1. Lets also handle that case for our "BIOS" on s390. Signed-off-by: Christian Borntraeger CC: Alexey Kardashevskiy CC: Alexander Graf --- hw/s390x/ipl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/s390x/ipl.c b/hw/s390x/ipl.c index 32d38a0..4fa9cff 100644 --- a/hw/s390x/ipl.c +++ b/hw/s390x/ipl.c @@ -80,7 +80,7 @@ static int s390_ipl_init(SysBusDevice *dev) bios_size = load_elf(bios_filename, NULL, NULL, &ipl->start_addr, NULL, NULL, 1, ELF_MACHINE, 0); - if (bios_size == -1) { + if (bios_size < 0) { bios_size = load_image_targphys(bios_filename, ZIPL_IMAGE_START, 4096); ipl->start_addr = ZIPL_IMAGE_START;