From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56733) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7Ik3-0002m2-N4 for qemu-devel@nongnu.org; Fri, 11 Dec 2015 03:07:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a7Ik0-0007AK-Gm for qemu-devel@nongnu.org; Fri, 11 Dec 2015 03:07:51 -0500 Received: from e06smtp11.uk.ibm.com ([195.75.94.107]:36835) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7Ik0-00079E-6E for qemu-devel@nongnu.org; Fri, 11 Dec 2015 03:07:48 -0500 Received: from localhost by e06smtp11.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 11 Dec 2015 08:07:46 -0000 Received: from b06cxnps3074.portsmouth.uk.ibm.com (d06relay09.portsmouth.uk.ibm.com [9.149.109.194]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id 3527B1B08067 for ; Fri, 11 Dec 2015 08:08:13 +0000 (GMT) Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id tBB87h8N11862448 for ; Fri, 11 Dec 2015 08:07:43 GMT Received: from d06av02.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id tBB87gq2010161 for ; Fri, 11 Dec 2015 01:07:42 -0700 Date: Fri, 11 Dec 2015 09:07:41 +0100 From: David Hildenbrand Message-ID: <20151211090741.400fd4ea@thinkpad-w530> In-Reply-To: <1449768232-22924-5-git-send-email-armbru@redhat.com> References: <1449768232-22924-1-git-send-email-armbru@redhat.com> <1449768232-22924-5-git-send-email-armbru@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 4/4] hw/s390x: Rename local variables Error *l_err to just err List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: qemu-devel@nongnu.org > > static Property s390_ipl_properties[] = { > diff --git a/hw/s390x/sclp.c b/hw/s390x/sclp.c > index a061b49..9a117c9 100644 > --- a/hw/s390x/sclp.c > +++ b/hw/s390x/sclp.c > @@ -456,29 +456,29 @@ static void sclp_realize(DeviceState *dev, Error **errp) > { > MachineState *machine = MACHINE(qdev_get_machine()); > SCLPDevice *sclp = SCLP(dev); > - Error *l_err = NULL; > + Error *err = NULL; > uint64_t hw_limit; > int ret; > > object_property_set_bool(OBJECT(sclp->event_facility), true, "realized", > - &l_err); > - if (l_err) { > + &err); > + if (err) { > goto error; > } > > ret = s390_set_memory_limit(machine->maxram_size, &hw_limit); > if (ret == -E2BIG) { > - error_setg(&l_err, "qemu: host supports a maximum of %" PRIu64 " GB", > + error_setg(&err, "qemu: host supports a maximum of %" PRIu64 " GB", > hw_limit >> 30); > goto error; > } else if (ret) { > - error_setg(&l_err, "qemu: setting the guest size failed"); > + error_setg(&err, "qemu: setting the guest size failed"); > goto error; > } > return; > error: > - assert(l_err); > - error_propagate(errp, l_err); > + assert(err); We could also get rid of that assert and remove the return; above (naming the label "out"). > + error_propagate(errp, err); > } > > static void sclp_memory_init(SCLPDevice *sclp) Reviewed-by: David Hildenbrand David