diff options
author | Yinghai Lu <yinghai@kernel.org> | 2013-07-25 17:31:38 +0400 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2013-07-26 17:32:20 +0400 |
commit | aa914f5ec25e4371ba18b312971314be1b9b1076 (patch) | |
tree | 318090c34fc438e39c59780bf98e705ce8c50d9e /drivers/tty/moxa.h | |
parent | c10cc483bf3f1d0e8f9f077ca36ecc053de9bbbc (diff) | |
download | linux-aa914f5ec25e4371ba18b312971314be1b9b1076.tar.xz |
PCI: Retry allocation of only the resource type that failed
Ben Herrenschmidt reported the following problem:
- The bus has space for all desired MMIO resources, including optional
space for SR-IOV devices
- We attempt to allocate I/O port space, but it fails because the bus
has no I/O space
- Because of the I/O allocation failure, we retry MMIO allocation,
requesting only the required space, without the optional SR-IOV space
This means we don't allocate the optional SR-IOV space, even though we
could.
This is related to 0c5be0cb0e ("PCI: Retry on IORESOURCE_IO type
allocations").
This patch changes how we handle allocation failures. We will now retry
allocation of only the resource type that failed. If MMIO allocation
fails, we'll retry only MMIO allocation. If I/O port allocation fails,
we'll retry only I/O port allocation.
[bhelgaas: changelog]
Reference: https://lkml.kernel.org/r/1367712653.11982.19.camel@pasglop
Reported-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Tested-by: Gavin Shan <shangw@linux.vnet.ibm.com>
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
CC: stable@vger.kernel.org # v3.10+
Diffstat (limited to 'drivers/tty/moxa.h')
0 files changed, 0 insertions, 0 deletions