From patchwork Fri Apr 16 21:53:46 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tim Harvey X-Patchwork-Id: 422651 Delivered-To: patch@linaro.org Received: by 2002:a02:6a6f:0:0:0:0:0 with SMTP id m47csp745062jaf; Fri, 16 Apr 2021 14:54:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz/Yo7qF1+4t2PvDCH+swaAqcuADkoqe12xYiEuq2+sWqEFbV6iR/tPqVfEbbB4jelZYjk+ X-Received: by 2002:a17:907:7631:: with SMTP id jy17mr10325519ejc.418.1618610047586; Fri, 16 Apr 2021 14:54:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618610047; cv=none; d=google.com; s=arc-20160816; b=sivPyIWzD8nb+ufVOJBSPaFN+BKC7FubI8w+YfXvB19j3UxsVRDjp/YD9AH34xPmAr 0PmsDe9vjBNiZmy+YB5bu/VT7iWzxX2Nqot9GWx6hbYDIAqm6Hx4C7hpnA1710jlQEWw 2y6vz4XG/n65Kn2XMsNrA21qc9W8kczfmqDKBP0gn5a/Pjy6P1ue/xerI25YZSlvyG4l WaFiMjAcysTUji/cWFhuxJ/f+HxcVDj7dRw65IXmAs2pIcr1Hlbzis6vGGsSdbinG9IS EjQiXoYMLSDuZMzfPXHzt5JBdRU+7WsIS3lnRRCEDWd2OXqD4MvSAfBszrM77QSwfYch +2iA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=YLslV7jUOf8aX2zwZt93b6p4RPGNX8vryKi9VuYoYqs=; b=uFxRbGE2glEoSVAJLDHPzAdQFlo7qZZevwDQovQ6Ct3gCVTuWsSuikcAJWXtl7zVTq ypDTdCRjLduHJiXlNijbiEptnTixk/Kcf9A02OxuOcGzRAuNaZAaQeFhtiieAB26dlqC 8rfCVjLM0sspR0Nvt24dRP0tRCF9Cqzghpho5Nk/MaIAE5IV2G/RDh4iZeKQYTdp8nPx /uziUk+LVgLC7Cbnm/wq+mjs4bo2FFLeQhHPfx2l/f/xPXy5Mr7TA+kfEmnMuqbsaoAR 12cA1JFp9H9PmX9j+hqIRsnoSTEaKsQdIKLhRU45wmlkRZOlemlLsoDGUankHc+qgO/L LRnw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Return-Path: Received: from phobos.denx.de (phobos.denx.de. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id bs7si5814695edb.489.2021.04.16.14.54.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Apr 2021 14:54:07 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 41CFF8021A; Fri, 16 Apr 2021 23:54:02 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gateworks.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 01D5180F1C; Fri, 16 Apr 2021 23:54:00 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00, KHOP_HELO_FCRDNS, SPF_HELO_NONE autolearn=no autolearn_force=no version=3.4.2 Received: from finn.localdomain (finn.gateworks.com [108.161.129.64]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 1813580EBA for ; Fri, 16 Apr 2021 23:53:55 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gateworks.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=tharvey@gateworks.com Received: from 068-189-091-139.biz.spectrum.com ([68.189.91.139] helo=tharvey.pdc.gateworks.com) by finn.localdomain with esmtp (Exim 4.93) (envelope-from ) id 1lXWPN-002O25-Qq; Fri, 16 Apr 2021 21:53:49 +0000 From: Tim Harvey To: Stefano Babic , Fabio Estevam , "NXP i . MX U-Boot Team" , Simon Glass Cc: u-boot@lists.denx.de, Masami Hiramatsu Subject: [PATCH 1/3] pci: Update the highest subordinate bus number for bridge setup Date: Fri, 16 Apr 2021 14:53:46 -0700 Message-Id: <20210416215348.15277-1-tharvey@gateworks.com> X-Mailer: git-send-email 2.17.1 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.102.4 at phobos.denx.de X-Virus-Status: Clean From: Masami Hiramatsu Update the highest subordinate bus number after probing the devices under the bus for setting up the bridge correctly. The commit 42f3663a3f67 ("pci: Update to use new sequence numbers") removed this but it is required if a PCIe bridge is under the bus. Fixes: 42f3663a3f67 ("pci: Update to use new sequence numbers") Signed-off-by: Masami Hiramatsu --- drivers/pci/pci-uclass.c | 3 +++ 1 file changed, 3 insertions(+) -- 2.17.1 diff --git a/drivers/pci/pci-uclass.c b/drivers/pci/pci-uclass.c index dfd54b339f..f463ef3550 100644 --- a/drivers/pci/pci-uclass.c +++ b/drivers/pci/pci-uclass.c @@ -646,6 +646,9 @@ int dm_pci_hose_probe_bus(struct udevice *bus) return log_msg_ret("probe", ret); } + if (!ea_pos) + sub_bus = pci_get_bus_max(); + dm_pciauto_postscan_setup_bridge(bus, sub_bus); return sub_bus;