Received: from eggs.gnu.org ([2001:4830:134:3::10]:59418) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBRIL-0002zp-SK for qemu-devel@nongnu.org; Wed, 14 Jan 2015 11:59:50 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YBRIG-0000Mq-C8 for qemu-devel@nongnu.org; Wed, 14 Jan 2015 11:59:49 -0500 Received: from e06smtp17.uk.ibm.com ([195.75.94.113]:52954) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YBRIG-0000MD-1i for qemu-devel@nongnu.org; Wed, 14 Jan 2015 11:59:44 -0500 Received: from /spool/local by e06smtp17.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 14 Jan 2015 16:59:42 -0000 Received: from b06cxnps3075.portsmouth.uk.ibm.com (d06relay10.portsmouth.uk.ibm.com [9.149.109.195]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id A598817D8042 for ; Wed, 14 Jan 2015 17:00:18 +0000 (GMT) Received: from d06av08.portsmouth.uk.ibm.com (d06av08.portsmouth.uk.ibm.com [9.149.37.249]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t0EGxePX48693450 for ; Wed, 14 Jan 2015 16:59:40 GMT Received: from d06av08.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av08.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t0EGxdO3010141 for ; Wed, 14 Jan 2015 09:59:40 -0700 Date: Wed, 14 Jan 2015 17:59:36 +0100 From: Thomas Huth Message-ID: <20150114175936.20ed79a1@oc7435384737.ibm.com> In-Reply-To: <1421248847-24237-1-git-send-email-blaschka@linux.vnet.ibm.com> References: <1421248847-24237-1-git-send-email-blaschka@linux.vnet.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] s390x/pci: fix 2 bugs found by coverity List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Frank Blaschka Cc: cornelia.huck@de.ibm.com, borntraeger@de.ibm.com, qemu-devel@nongnu.org, pbonzini@redhat.com On Wed, 14 Jan 2015 16:20:47 +0100 Frank Blaschka wrote: > Signed-off-by: Frank Blaschka > --- > hw/s390x/s390-pci-bus.c | 1 + > hw/s390x/s390-pci-inst.c | 2 +- > 2 files changed, 2 insertions(+), 1 deletion(-) > > diff --git a/hw/s390x/s390-pci-bus.c b/hw/s390x/s390-pci-bus.c > index 1201b8d..546dcf1 100644 > --- a/hw/s390x/s390-pci-bus.c > +++ b/hw/s390x/s390-pci-bus.c > @@ -192,6 +192,7 @@ static void s390_pci_generate_event(uint8_t cc, uint16_t pec, uint32_t fh, > object_resolve_path(TYPE_S390_PCI_HOST_BRIDGE, NULL)); > > if (!s) { > + g_free(sei_cont); > return; > } > > diff --git a/hw/s390x/s390-pci-inst.c b/hw/s390x/s390-pci-inst.c > index 5ea13e5..5596679 100644 > --- a/hw/s390x/s390-pci-inst.c > +++ b/hw/s390x/s390-pci-inst.c > @@ -787,7 +787,7 @@ int stpcifc_service_call(S390CPU *cpu, uint8_t r1, uint64_t fiba) > data = (pbdev->isc << 28) | (pbdev->noi << 16) | > (pbdev->routes.adapter.ind_offset << 8) | (pbdev->sum << 7) | > pbdev->routes.adapter.summary_offset; > - stw_p(&fib.data, data); > + stl_p(&fib.data, data); > > if (pbdev->fh >> ENABLE_BIT_OFFSET) { > fib.fc |= 0x80; Looks right. Reviewed-by: Thomas Huth