diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2018-02-06 12:59:40 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2018-02-06 12:59:40 -0500 |
| commit | 105cf3c8c6264dce4bcdab877feb8037bc4109b1 (patch) | |
| tree | d44c56b22038b15bb44c7104c3cfc8a6bc4eefff /kernel | |
| parent | e237f98a9c134c3d600353f21e07db915516875b (diff) | |
| parent | ab8c609356fbe8dbcd44df11e884ce8cddf3739e (diff) | |
Merge tag 'pci-v4.16-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci
Pull PCI updates from Bjorn Helgaas:
- skip AER driver error recovery callbacks for correctable errors
reported via ACPI APEI, as we already do for errors reported via the
native path (Tyler Baicar)
- fix DPC shared interrupt handling (Alex Williamson)
- print full DPC interrupt number (Keith Busch)
- enable DPC only if AER is available (Keith Busch)
- simplify DPC code (Bjorn Helgaas)
- calculate ASPM L1 substate parameter instead of hardcoding it (Bjorn
Helgaas)
- enable Latency Tolerance Reporting for ASPM L1 substates (Bjorn
Helgaas)
- move ASPM internal interfaces out of public header (Bjorn Helgaas)
- allow hot-removal of VGA devices (Mika Westerberg)
- speed up unplug and shutdown by assuming Thunderbolt controllers
don't support Command Completed events (Lukas Wunner)
- add AtomicOps support for GPU and Infiniband drivers (Felix Kuehling,
Jay Cornwall)
- expose "ari_enabled" in sysfs to help NIC naming (Stuart Hayes)
- clean up PCI DMA interface usage (Christoph Hellwig)
- remove PCI pool API (replaced with DMA pool) (Romain Perier)
- deprecate pci_get_bus_and_slot(), which assumed PCI domain 0 (Sinan
Kaya)
- move DT PCI code from drivers/of/ to drivers/pci/ (Rob Herring)
- add PCI-specific wrappers for dev_info(), etc (Frederick Lawler)
- remove warnings on sysfs mmap failure (Bjorn Helgaas)
- quiet ROM validation messages (Alex Deucher)
- remove redundant memory alloc failure messages (Markus Elfring)
- fill in types for compile-time VGA and other I/O port resources
(Bjorn Helgaas)
- make "pci=pcie_scan_all" work for Root Ports as well as Downstream
Ports to help AmigaOne X1000 (Bjorn Helgaas)
- add SPDX tags to all PCI files (Bjorn Helgaas)
- quirk Marvell 9128 DMA aliases (Alex Williamson)
- quirk broken INTx disable on Ceton InfiniTV4 (Bjorn Helgaas)
- fix CONFIG_PCI=n build by adding dummy pci_irqd_intx_xlate() (Niklas
Cassel)
- use DMA API to get MSI address for DesignWare IP (Niklas Cassel)
- fix endpoint-mode DMA mask configuration (Kishon Vijay Abraham I)
- fix ARTPEC-6 incorrect IS_ERR() usage (Wei Yongjun)
- add support for ARTPEC-7 SoC (Niklas Cassel)
- add endpoint-mode support for ARTPEC (Niklas Cassel)
- add Cadence PCIe host and endpoint controller driver (Cyrille
Pitchen)
- handle multiple INTx status bits being set in dra7xx (Vignesh R)
- translate dra7xx hwirq range to fix INTD handling (Vignesh R)
- remove deprecated Exynos PHY initialization code (Jaehoon Chung)
- fix MSI erratum workaround for HiSilicon Hip06/Hip07 (Dongdong Liu)
- fix NULL pointer dereference in iProc BCMA driver (Ray Jui)
- fix Keystone interrupt-controller-node lookup (Johan Hovold)
- constify qcom driver structures (Julia Lawall)
- rework Tegra config space mapping to increase space available for
endpoints (Vidya Sagar)
- simplify Tegra driver by using bus->sysdata (Manikanta Maddireddy)
- remove PCI_REASSIGN_ALL_BUS usage on Tegra (Manikanta Maddireddy)
- add support for Global Fabric Manager Server (GFMS) event to
Microsemi Switchtec switch driver (Logan Gunthorpe)
- add IDs for Switchtec PSX 24xG3 and PSX 48xG3 (Kelvin Cao)
* tag 'pci-v4.16-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: (140 commits)
PCI: cadence: Add EndPoint Controller driver for Cadence PCIe controller
dt-bindings: PCI: cadence: Add DT bindings for Cadence PCIe endpoint controller
PCI: endpoint: Fix EPF device name to support multi-function devices
PCI: endpoint: Add the function number as argument to EPC ops
PCI: cadence: Add host driver for Cadence PCIe controller
dt-bindings: PCI: cadence: Add DT bindings for Cadence PCIe host controller
PCI: Add vendor ID for Cadence
PCI: Add generic function to probe PCI host controllers
PCI: generic: fix missing call of pci_free_resource_list()
PCI: OF: Add generic function to parse and allocate PCI resources
PCI: Regroup all PCI related entries into drivers/pci/Makefile
PCI/DPC: Reformat DPC register definitions
PCI/DPC: Add and use DPC Status register field definitions
PCI/DPC: Squash dpc_rp_pio_get_info() into dpc_process_rp_pio_error()
PCI/DPC: Remove unnecessary RP PIO register structs
PCI/DPC: Push dpc->rp_pio_status assignment into dpc_rp_pio_get_info()
PCI/DPC: Squash dpc_rp_pio_print_error() into dpc_rp_pio_get_info()
PCI/DPC: Make RP PIO log size check more generic
PCI/DPC: Rename local "status" to "dpc_status"
PCI/DPC: Squash dpc_rp_pio_print_tlp_header() into dpc_rp_pio_print_error()
...
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/resource.c | 29 |
1 files changed, 21 insertions, 8 deletions
diff --git a/kernel/resource.c b/kernel/resource.c index 54ba6de3757c..8c527d83ca76 100644 --- a/kernel/resource.c +++ b/kernel/resource.c | |||
| @@ -1022,6 +1022,7 @@ static void __init __reserve_region_with_split(struct resource *root, | |||
| 1022 | struct resource *conflict; | 1022 | struct resource *conflict; |
| 1023 | struct resource *res = alloc_resource(GFP_ATOMIC); | 1023 | struct resource *res = alloc_resource(GFP_ATOMIC); |
| 1024 | struct resource *next_res = NULL; | 1024 | struct resource *next_res = NULL; |
| 1025 | int type = resource_type(root); | ||
| 1025 | 1026 | ||
| 1026 | if (!res) | 1027 | if (!res) |
| 1027 | return; | 1028 | return; |
| @@ -1029,7 +1030,7 @@ static void __init __reserve_region_with_split(struct resource *root, | |||
| 1029 | res->name = name; | 1030 | res->name = name; |
| 1030 | res->start = start; | 1031 | res->start = start; |
| 1031 | res->end = end; | 1032 | res->end = end; |
| 1032 | res->flags = IORESOURCE_BUSY; | 1033 | res->flags = type | IORESOURCE_BUSY; |
| 1033 | res->desc = IORES_DESC_NONE; | 1034 | res->desc = IORES_DESC_NONE; |
| 1034 | 1035 | ||
| 1035 | while (1) { | 1036 | while (1) { |
| @@ -1064,7 +1065,7 @@ static void __init __reserve_region_with_split(struct resource *root, | |||
| 1064 | next_res->name = name; | 1065 | next_res->name = name; |
| 1065 | next_res->start = conflict->end + 1; | 1066 | next_res->start = conflict->end + 1; |
| 1066 | next_res->end = end; | 1067 | next_res->end = end; |
| 1067 | next_res->flags = IORESOURCE_BUSY; | 1068 | next_res->flags = type | IORESOURCE_BUSY; |
| 1068 | next_res->desc = IORES_DESC_NONE; | 1069 | next_res->desc = IORES_DESC_NONE; |
| 1069 | } | 1070 | } |
| 1070 | } else { | 1071 | } else { |
| @@ -1478,7 +1479,7 @@ void __devm_release_region(struct device *dev, struct resource *parent, | |||
| 1478 | EXPORT_SYMBOL(__devm_release_region); | 1479 | EXPORT_SYMBOL(__devm_release_region); |
| 1479 | 1480 | ||
| 1480 | /* | 1481 | /* |
| 1481 | * Called from init/main.c to reserve IO ports. | 1482 | * Reserve I/O ports or memory based on "reserve=" kernel parameter. |
| 1482 | */ | 1483 | */ |
| 1483 | #define MAXRESERVE 4 | 1484 | #define MAXRESERVE 4 |
| 1484 | static int __init reserve_setup(char *str) | 1485 | static int __init reserve_setup(char *str) |
| @@ -1489,26 +1490,38 @@ static int __init reserve_setup(char *str) | |||
| 1489 | for (;;) { | 1490 | for (;;) { |
| 1490 | unsigned int io_start, io_num; | 1491 | unsigned int io_start, io_num; |
| 1491 | int x = reserved; | 1492 | int x = reserved; |
| 1493 | struct resource *parent; | ||
| 1492 | 1494 | ||
| 1493 | if (get_option (&str, &io_start) != 2) | 1495 | if (get_option(&str, &io_start) != 2) |
| 1494 | break; | 1496 | break; |
| 1495 | if (get_option (&str, &io_num) == 0) | 1497 | if (get_option(&str, &io_num) == 0) |
| 1496 | break; | 1498 | break; |
| 1497 | if (x < MAXRESERVE) { | 1499 | if (x < MAXRESERVE) { |
| 1498 | struct resource *res = reserve + x; | 1500 | struct resource *res = reserve + x; |
| 1501 | |||
| 1502 | /* | ||
| 1503 | * If the region starts below 0x10000, we assume it's | ||
| 1504 | * I/O port space; otherwise assume it's memory. | ||
| 1505 | */ | ||
| 1506 | if (io_start < 0x10000) { | ||
| 1507 | res->flags = IORESOURCE_IO; | ||
| 1508 | parent = &ioport_resource; | ||
| 1509 | } else { | ||
| 1510 | res->flags = IORESOURCE_MEM; | ||
| 1511 | parent = &iomem_resource; | ||
| 1512 | } | ||
| 1499 | res->name = "reserved"; | 1513 | res->name = "reserved"; |
| 1500 | res->start = io_start; | 1514 | res->start = io_start; |
| 1501 | res->end = io_start + io_num - 1; | 1515 | res->end = io_start + io_num - 1; |
| 1502 | res->flags = IORESOURCE_BUSY; | 1516 | res->flags |= IORESOURCE_BUSY; |
| 1503 | res->desc = IORES_DESC_NONE; | 1517 | res->desc = IORES_DESC_NONE; |
| 1504 | res->child = NULL; | 1518 | res->child = NULL; |
| 1505 | if (request_resource(res->start >= 0x10000 ? &iomem_resource : &ioport_resource, res) == 0) | 1519 | if (request_resource(parent, res) == 0) |
| 1506 | reserved = x+1; | 1520 | reserved = x+1; |
| 1507 | } | 1521 | } |
| 1508 | } | 1522 | } |
| 1509 | return 1; | 1523 | return 1; |
| 1510 | } | 1524 | } |
| 1511 | |||
| 1512 | __setup("reserve=", reserve_setup); | 1525 | __setup("reserve=", reserve_setup); |
| 1513 | 1526 | ||
| 1514 | /* | 1527 | /* |
