Received: from eggs.gnu.org ([140.186.70.92]:49097) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RVIOf-0008HM-54 for qemu-devel@nongnu.org; Tue, 29 Nov 2011 02:46:37 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RVIOb-0001fS-9B for qemu-devel@nongnu.org; Tue, 29 Nov 2011 02:46:33 -0500 Date: Tue, 29 Nov 2011 18:41:10 +1100 From: David Gibson Message-ID: <20111129074110.GK3508@truffala.fritz.box> References: <1322547699-28329-1-git-send-email-david@gibson.dropbear.id.au> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1322547699-28329-1-git-send-email-david@gibson.dropbear.id.au> Subject: Re: [Qemu-devel] [Qemu-ppc] [PATCH] pseries: Fix array overrun bug in PCI code List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: agraf@suse.de Cc: aik@ozlabs.ru, sw@weilnetz.de, qemu-ppc@nongnu.org, qemu-devel@nongnu.org On Tue, Nov 29, 2011 at 05:21:39PM +1100, David Gibson wrote: > spapr_populate_pci_devices() containd a loop with PCI_NUM_REGIONS (7) > iterations. However this overruns the 'bars' global array, which only has > 6 elements. In fact we only want to run this loop for things listed in the > bars array, so this patch corrects the loop bounds to reflect that. > > Signed-off-by: David Gibson As a bugfix for a bad memory access, this is definitely for 1.0 -- David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson