From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MTe7A-000766-VH for qemu-devel@nongnu.org; Wed, 22 Jul 2009 11:52:21 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MTe73-00072z-RK for qemu-devel@nongnu.org; Wed, 22 Jul 2009 11:52:20 -0400 Received: from [199.232.76.173] (port=52083 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MTe73-00072a-9q for qemu-devel@nongnu.org; Wed, 22 Jul 2009 11:52:13 -0400 Received: from mx2.redhat.com ([66.187.237.31]:38137) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MTe72-0001Ra-MW for qemu-devel@nongnu.org; Wed, 22 Jul 2009 11:52:12 -0400 Date: Wed, 22 Jul 2009 18:51:14 +0300 From: "Michael S. Tsirkin" Message-ID: <20090722155114.GA8554@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Subject: [Qemu-devel] [PATCH] qemu: msix nit: clear msix_entries_nr on error List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org, anthony@codemonkey.ws I don't think it's critical to do this, but it's best to keep uninit and error recovery consistent. Signed-off-by: Michael S. Tsirkin --- hw/msix.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/hw/msix.c b/hw/msix.c index 4ab6da6..932deea 100644 --- a/hw/msix.c +++ b/hw/msix.c @@ -255,6 +255,7 @@ int msix_init(struct PCIDevice *dev, unsigned short nentries, return 0; err_config: + dev->msix_entries_nr = 0; cpu_unregister_io_memory(dev->msix_mmio_index); err_index: qemu_free(dev->msix_table_page); -- 1.6.2.5