From patchwork Fri Apr 17 04:02:16 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yinghai Lu X-Patchwork-Id: 18608 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n3H435FI030871 for ; Fri, 17 Apr 2009 04:03:05 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750872AbZDQEC5 (ORCPT ); Fri, 17 Apr 2009 00:02:57 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1750809AbZDQEC5 (ORCPT ); Fri, 17 Apr 2009 00:02:57 -0400 Received: from hera.kernel.org ([140.211.167.34]:52832 "EHLO hera.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750760AbZDQEC4 (ORCPT ); Fri, 17 Apr 2009 00:02:56 -0400 Received: from [192.168.101.7] (adsl-75-62-232-65.dsl.pltn13.sbcglobal.net [75.62.232.65]) (authenticated bits=0) by hera.kernel.org (8.14.2/8.13.8) with ESMTP id n3H42Onu032382 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 17 Apr 2009 04:02:30 GMT Message-ID: <49E7FF48.1060509@kernel.org> Date: Thu, 16 Apr 2009 21:02:16 -0700 From: Yinghai Lu User-Agent: Thunderbird 2.0.0.19 (X11/20081227) MIME-Version: 1.0 To: Ingo Molnar , Matthew Wilcox , Jesse Barnes , Thomas Gleixner CC: linux-pci@vger.kernel.org Subject: [PATCH 1/2] pci: don't assign non root buses References: <20090416193110.GF1926@parisc-linux.org> <20090417001248.GA29630@elte.hu> In-Reply-To: <20090417001248.GA29630@elte.hu> X-Virus-Scanned: ClamAV 0.93.3/9248/Thu Apr 16 21:20:40 2009 on hera.kernel.org X-Virus-Status: Clean Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org Impact: cleanup it will be assigned late pci_scan_child_bus/pcibios_fixup_bus Signed-off-by: Yinghai Lu --- drivers/pci/probe.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Index: linux-2.6/drivers/pci/probe.c =================================================================== --- linux-2.6.orig/drivers/pci/probe.c +++ linux-2.6/drivers/pci/probe.c @@ -1177,8 +1177,12 @@ struct pci_bus * pci_create_bus(struct d pci_create_legacy_files(b); b->number = b->secondary = bus; - b->resource[0] = &ioport_resource; - b->resource[1] = &iomem_resource; + + /* don't need assign those for non root buses */ + if (!parent) { + b->resource[0] = &ioport_resource; + b->resource[1] = &iomem_resource; + } return b;