Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp3698357imj; Tue, 19 Feb 2019 07:59:06 -0800 (PST) X-Google-Smtp-Source: AHgI3IZpHT6A9KLWrpScNOG8yieiuiFdXzHGIWs05+lg7ePuqGgKu9iNpCGhFdx4wJuzcwRFdUy9 X-Received: by 2002:a17:902:8d89:: with SMTP id v9mr31672687plo.90.1550591946197; Tue, 19 Feb 2019 07:59:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550591946; cv=none; d=google.com; s=arc-20160816; b=sfIJar8f1SgdwD5GqJgFOlP8WIyVTvu7b5KibzGXufMy2Y1S4OUB1BQa27xch/thla vQW6ZGqkvAA2MHgshfurW7/cXGUMn42bq2i3cmtaEBMzGLDJ+vjR8B7RWgVf1nDMfP/n hRQUBoItE0Yp+ykRvXzHnAP8zAsVEI4XL9KRe20nHwj4LAF+uMcr8jKGsvMRkgxu8yL1 58s7Csj9sKtahqh6mGZ7T1DgIIGPYC1B3oeabD1uGWXwRYVMTHqGkNK1indL/jQ5O0bP dyO+23iXXVR33t3CIggWlUxloDUXaJNIfnvvAQNISd2FGy8h1rh+9gYwA23MzZZco7uQ KxOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:to:from; bh=HWlYkJyx66cnz151dohW7vWUOzTPmVjUNENeOaCIpck=; b=EWuqaBLylNm53R8l4Mv1ggmFp9E2dX53uyJSQ+qPmTqNCvX0aO5e/5uROtaKG1u3P6 MFkK3l7+b1VUQTwGkIt9EVn6PLLv0YZhHwxBtiAVLNyC+VJXmtBBEJ2Is0IQvpmcV80j En2opSNFrCkUpXaF44Q6oWEk3zJRoS+LThTfek27V6S+ZuR/4XnzMW73rZQo1v0QWUlO bhSihOTHPtcDecZwuFYcb+8juEyUAnXKWXaZCRroloytDcGpFx/mijzL3djENaH6a88d qwkoeWvw4kkc12WLvohsn154dlWdZtCeRdGsv8NKjISqQyM8QgaMBtZZQxzj2tyHXRBy MUsg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g20si14449040pgk.587.2019.02.19.07.58.51; Tue, 19 Feb 2019 07:59:06 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729102AbfBSP6H (ORCPT + 99 others); Tue, 19 Feb 2019 10:58:07 -0500 Received: from mx2.suse.de ([195.135.220.15]:51914 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728642AbfBSP5j (ORCPT ); Tue, 19 Feb 2019 10:57:39 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id E78BCAF5F; Tue, 19 Feb 2019 15:57:38 +0000 (UTC) From: Thomas Bogendoerfer To: Bjorn Helgaas , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 07/10] PCI: call add_bus method also for root bus Date: Tue, 19 Feb 2019 16:57:21 +0100 Message-Id: <20190219155728.19163-8-tbogendoerfer@suse.de> X-Mailer: git-send-email 2.13.7 In-Reply-To: <20190219155728.19163-1-tbogendoerfer@suse.de> References: <20190219155728.19163-1-tbogendoerfer@suse.de> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org pci-xtalk controller code uses the add_bus method to set node of the bus device, which then is used for pcibus_to_node() implementation. Signed-off-by: Thomas Bogendoerfer --- drivers/pci/probe.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index 257b9f6f2ebb..456448d5f46d 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c @@ -837,6 +837,12 @@ static int pci_register_host_bridge(struct pci_host_bridge *bridge) pcibios_add_bus(bus); + if (bus->ops->add_bus) { + err = bus->ops->add_bus(bus); + if (WARN_ON(err < 0)) + dev_err(&bus->dev, "failed to add bus: %d\n", err); + } + /* Create legacy_io and legacy_mem files for this bus */ pci_create_legacy_files(bus); -- 2.13.7