Message ID | 20190111153707.10140-10-s.miroshnichenko@yadro.com |
---|---|
State | Superseded |
Delegated to: | Bjorn Helgaas |
Headers | show
Return-Path: <linux-pci-owner@vger.kernel.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=linux-pci-owner@vger.kernel.org; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=yadro.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=yadro.com header.i=@yadro.com header.b="Qq/0+dKv"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 43bnGT59F2z9s7h for <incoming@patchwork.ozlabs.org>; Sat, 12 Jan 2019 02:44:01 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731954AbfAKPn5 (ORCPT <rfc822;incoming@patchwork.ozlabs.org>); Fri, 11 Jan 2019 10:43:57 -0500 Received: from mta-01.yadro.com ([89.207.88.251]:40080 "EHLO mta-01.yadro.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731907AbfAKPn4 (ORCPT <rfc822;linux-pci@vger.kernel.org>); Fri, 11 Jan 2019 10:43:56 -0500 Received: from localhost (unknown [127.0.0.1]) by mta-01.yadro.com (Postfix) with ESMTP id ACA194199C for <linux-pci@vger.kernel.org>; Fri, 11 Jan 2019 15:37:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yadro.com; h= content-type:content-type:content-transfer-encoding:mime-version :references:in-reply-to:x-mailer:message-id:date:date:subject :subject:from:from:received:received:received; s=mta-01; t= 1547221045; x=1549035446; bh=w2WsEPtKzIZL+wyNvFgeoacIwtne0R6BKOf WLQ7P2EI=; b=Qq/0+dKvwiTFgztEZyLSYWzJ2yrjjdNPYlSUgzDYZcuhYOFRPcy NY5YiBKA7cg6RGq7jAy31ueWiCxM/2tNJbBMr+u0E+8CUlrTPC4mn3KTkam9XZm+ 1hSV0Kgw7LPm3Pd10RfR61ePGRSFXBUgyigOZX8Gf2HvOK0RUEs2W5GE= X-Virus-Scanned: amavisd-new at yadro.com Received: from mta-01.yadro.com ([127.0.0.1]) by localhost (mta-01.yadro.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dNAcFMi6xWLB for <linux-pci@vger.kernel.org>; Fri, 11 Jan 2019 18:37:25 +0300 (MSK) Received: from T-EXCH-02.corp.yadro.com (t-exch-02.corp.yadro.com [172.17.10.102]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mta-01.yadro.com (Postfix) with ESMTPS id 5A1DC419A0 for <linux-pci@vger.kernel.org>; Fri, 11 Jan 2019 18:37:23 +0300 (MSK) Received: from NB-148.yadro.com (172.17.15.60) by T-EXCH-02.corp.yadro.com (172.17.10.102) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.669.32; Fri, 11 Jan 2019 18:37:23 +0300 From: Sergey Miroshnichenko <s.miroshnichenko@yadro.com> To: <linux-pci@vger.kernel.org> CC: <linux@yadro.com>, Sergey Miroshnichenko <s.miroshnichenko@yadro.com> Subject: [PATCH RFC v2 09/21] PCI: Don't reserve memory for hotplug when enabled movable BARs Date: Fri, 11 Jan 2019 18:36:55 +0300 Message-ID: <20190111153707.10140-10-s.miroshnichenko@yadro.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190111153707.10140-1-s.miroshnichenko@yadro.com> References: <20190111153707.10140-1-s.miroshnichenko@yadro.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.17.15.60] X-ClientProxiedBy: T-EXCH-01.corp.yadro.com (172.17.10.101) To T-EXCH-02.corp.yadro.com (172.17.10.102) Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: <linux-pci.vger.kernel.org> X-Mailing-List: linux-pci@vger.kernel.org |
Series |
PCI: Allow BAR movement during hotplug
|
expand
|
diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c index 99aa78668e9e..3ed13abdf937 100644 --- a/drivers/pci/setup-bus.c +++ b/drivers/pci/setup-bus.c @@ -1266,7 +1266,7 @@ void __pci_bus_size_bridges(struct pci_bus *bus, struct list_head *realloc_head) case PCI_CLASS_BRIDGE_PCI: pci_bridge_check_ranges(bus); - if (bus->self->is_hotplug_bridge) { + if (bus->self->is_hotplug_bridge && !pci_movable_bars_enabled()) { additional_io_size = pci_hotplug_io_size; additional_mem_size = pci_hotplug_mem_size; }
pbus_size_mem() returns a precise amount of memory required to fit all the requested BARs and windows of children bridges. Signed-off-by: Sergey Miroshnichenko <s.miroshnichenko@yadro.com> --- drivers/pci/setup-bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)