From patchwork Thu Jan 28 19:10:14 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yinghai Lu X-Patchwork-Id: 75607 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o0SJCeuW019527 for ; Thu, 28 Jan 2010 19:12:40 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756409Ab0A1TMj (ORCPT ); Thu, 28 Jan 2010 14:12:39 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1756347Ab0A1TMj (ORCPT ); Thu, 28 Jan 2010 14:12:39 -0500 Received: from hera.kernel.org ([140.211.167.34]:34872 "EHLO hera.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753641Ab0A1TMi (ORCPT ); Thu, 28 Jan 2010 14:12:38 -0500 Received: from [129.146.52.180] (sca-ea-fw-1.Sun.COM [192.18.43.225]) (authenticated bits=0) by hera.kernel.org (8.14.3/8.14.3) with ESMTP id o0SJAjXV003459 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Thu, 28 Jan 2010 19:10:45 GMT X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.95.2 at hera.kernel.org Message-ID: <4B61E116.6050208@kernel.org> Date: Thu, 28 Jan 2010 11:10:14 -0800 From: Yinghai Lu User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.5) Gecko/20091130 SUSE/3.0.0-1.1.1 Thunderbird/3.0 MIME-Version: 1.0 To: Linus Torvalds CC: Jesse Barnes , Jeff Garrett , "Rafael J. Wysocki" , Bjorn Helgaas , Linux Kernel Mailing List , Kernel Testers List , Linux PCI , Myron Stowe , Matthew Garrett , Ingo Molnar Subject: [PATCH -v2] x86/pci: print ioh resources only References: <201001261348.59508.rjw@sisk.pl> <201001261032.37053.bjorn.helgaas@hp.com> <201001261902.13911.rjw@sisk.pl> <20100126101752.78196900@jbarnes-piketon> <4B5F735B.2040308@kernel.org> <20100127192409.79af96db@jbarnes-piketon> <20100128040226.GB8964@jgarrett.org> <20100128082432.05a97ebc@jbarnes-piketon> <4B61D7C4.1050405@kernel.org> In-Reply-To: Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Thu, 28 Jan 2010 19:12:40 +0000 (UTC) Index: linux-2.6/arch/x86/pci/intel_bus.c =================================================================== --- linux-2.6.orig/arch/x86/pci/intel_bus.c +++ linux-2.6/arch/x86/pci/intel_bus.c @@ -53,13 +53,9 @@ static void __devinit pci_root_bus_res(s if (dev->cfg_size < 0x120) return; - if (pci_root_num >= PCI_ROOT_NR) { - printk(KERN_DEBUG "intel_bus.c: PCI_ROOT_NR is too small\n"); + info = kmalloc(sizeof(struct pci_root_info), GFP_KERNEL); + if (!info) return; - } - - info = &pci_root_info[pci_root_num]; - pci_root_num++; pci_read_config_word(dev, IOH_LCFGBUS, &word); bus_base = (word & 0xff);