From patchwork Wed Jan 29 18:17:33 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Helgaas X-Patchwork-Id: 3553901 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: X-Original-To: patchwork-linux-pci@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 502BE9F382 for ; Wed, 29 Jan 2014 18:24:51 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 8F748201B9 for ; Wed, 29 Jan 2014 18:24:50 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C85DE201B4 for ; Wed, 29 Jan 2014 18:24:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752705AbaA2SRl (ORCPT ); Wed, 29 Jan 2014 13:17:41 -0500 Received: from mail-ie0-f171.google.com ([209.85.223.171]:42809 "EHLO mail-ie0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752858AbaA2SRh (ORCPT ); Wed, 29 Jan 2014 13:17:37 -0500 Received: by mail-ie0-f171.google.com with SMTP id as1so2475259iec.30 for ; Wed, 29 Jan 2014 10:17:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=subject:to:from:cc:date:message-id:in-reply-to:references :user-agent:mime-version:content-type:content-transfer-encoding; bh=fmGobmL9tqwjDTWoyjAg2BuPvk792kaodgmL4v2bgx0=; b=OsVPqdmfXGcxaaSR/IQfO8bHCxoFumhQWhhj10euRBolPNflC35UPFMAZ1l9MBJAfy eBZbDjr4Zlhz5g1d5D8sPY6SD9+MljNlISrWou0xR7MKiS++HUr2RIdB73bLe2OI1uRA Ctuacwfxqyksmgg5XrhRl8eYAMDNJKtJGX+EPTd+MOAPHeCap3QFHg3YTKnEF1Hv64vi XjUqCn7RnPSLG2Fl2FdtgoCcu1qr9ebUUz38NBRZpCNdc12pYG+deuczMG3A3ePtc1j/ f5tSFsqtNYnZF1qVW/s0/Jau3sdY+58Jg1eLED5LOZ1OjWH40zsuZzWgHztGtG2ubeVW QXfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:from:cc:date:message-id:in-reply-to :references:user-agent:mime-version:content-type :content-transfer-encoding; bh=fmGobmL9tqwjDTWoyjAg2BuPvk792kaodgmL4v2bgx0=; b=mpQQYZTo8huNHPf3AUt+E7xkzDg+xzRlOhScfeSzETwrq87WDohzK6N7pdjOsCQVXD S2m1LE/GOzo9HCnYozNydyS9TPo6GHM+fw9Yij0/OqlbsB/8Silzdu99Mt4PmVF3pzu3 MsXiWULuQ93XvQGFGiqylExmUTebO25fCzSm0BrfQSayYmria0TwoaMtuS5KqZqPlA/D dlPPhWPRIiCyDA7Kt4iAfRG1rEaTAl3kRtW1ORRUN57+za9NT2ka6qoxAoOY7hs9gj3y uaspJtDRZPWgqPZBIeJW1qXBaXh3OZ5WV2zPpiSc0qZnyiGkwZfTNP9xtzR4NR9vYQ6O Kq6g== X-Gm-Message-State: ALoCoQlMHUQaaCzNinOHGSd+ds1VPTQqYYckNmKhbaMjwuhEUaZEzPuCqY4iR4sFsC1hqj6XZXAt+wl+zlSPUz0gmCEVF1eM5iUcw4tpXQmdfwJ7dv0DEAFATR7Y4+nllXW/Xd1KiJIYY4O2OlG8Fz5RAgxIy4xJt7ePApA02SrCNwbLD4gg/93vHAHQz8KLVBML8EubfpHK1tVEky1skRT4sBcjDiheFbgTJ7oTd4ZB0oDEW1INMFA= X-Received: by 10.50.222.99 with SMTP id ql3mr9918529igc.42.1391019456788; Wed, 29 Jan 2014 10:17:36 -0800 (PST) Received: from localhost ([172.29.123.160]) by mx.google.com with ESMTPSA id h6sm70357865igy.8.2014.01.29.10.17.33 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Wed, 29 Jan 2014 10:17:34 -0800 (PST) Subject: [PATCH 01/17] x86/PCI: Drop pcibios_scan_root() check for bus already scanned To: linux-pci@vger.kernel.org From: Bjorn Helgaas Cc: linux-acpi@vger.kernel.org, x86@kernel.org, linux-ia64@vger.kernel.org, linux-kernel@vger.kernel.org Date: Wed, 29 Jan 2014 11:17:33 -0700 Message-ID: <20140129181732.15476.79292.stgit@bhelgaas-glaptop.roam.corp.google.com> In-Reply-To: <20140129174106.15476.7075.stgit@bhelgaas-glaptop.roam.corp.google.com> References: <20140129174106.15476.7075.stgit@bhelgaas-glaptop.roam.corp.google.com> User-Agent: StGit/0.16 MIME-Version: 1.0 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The PCI core checks to see whether we've already scanned a bus, so we don't need to do it in pcibios_scan_root(). Here's where it happens in the core: pcibios_scan_root pci_scan_bus_on_node pci_scan_root_bus pci_create_root_bus b2 = pci_find_bus(pci_domain_nr(b), bus) if (b2) goto err_out; # already scanned this bus This removes the check from pcibios_scan_root(). Signed-off-by: Bjorn Helgaas --- arch/x86/pci/common.c | 9 --------- 1 file changed, 9 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 diff --git a/arch/x86/pci/common.c b/arch/x86/pci/common.c index 981c2dbd72cc..c47bb2288bb9 100644 --- a/arch/x86/pci/common.c +++ b/arch/x86/pci/common.c @@ -458,15 +458,6 @@ void __init dmi_check_pciprobe(void) struct pci_bus *pcibios_scan_root(int busnum) { - struct pci_bus *bus = NULL; - - while ((bus = pci_find_next_bus(bus)) != NULL) { - if (bus->number == busnum) { - /* Already scanned */ - return bus; - } - } - return pci_scan_bus_on_node(busnum, &pci_root_ops, get_mp_bus_to_node(busnum)); }