From: Simon Glass Date: Wed, 25 Sep 2019 08:56:15 -0600 Subject: [U-Boot] [PATCH 031/126] pci: Add more debug detail when resources are exhausted In-Reply-To: <20190925145750.200592-1-sjg@chromium.org> References: <20190925145750.200592-1-sjg@chromium.org> Message-ID: <20190925145750.200592-32-sjg@chromium.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de If PCI auto-config runs out of memory, show a few more details to help diagnose the problem. Signed-off-by: Simon Glass --- drivers/pci/pci_auto_common.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/pci/pci_auto_common.c b/drivers/pci/pci_auto_common.c index 84908e6154c..bb56a3d3fea 100644 --- a/drivers/pci/pci_auto_common.c +++ b/drivers/pci/pci_auto_common.c @@ -45,7 +45,8 @@ int pciauto_region_allocate(struct pci_region *res, pci_size_t size, addr = ((res->bus_lower - 1) | (size - 1)) + 1; if (addr - res->bus_start + size > res->size) { - debug("No room in resource"); + debug("No room in resource, avail start=%x / size=%x, need=%x\n", + res->bus_lower, res->size, size); goto error; } -- 2.23.0.444.g18eeb5a265-goog