Merge tag 'pci-v4.6-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci
authorLinus Torvalds <torvalds@linux-foundation.org>
Wed, 16 Mar 2016 21:45:55 +0000 (14:45 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 16 Mar 2016 21:45:55 +0000 (14:45 -0700)
Pull PCI updates from Bjorn Helgaas:
 "PCI changes for v4.6:

  Enumeration:
   - Disable IO/MEM decoding for devices with non-compliant BARs (Bjorn Helgaas)
   - Mark Broadwell-EP Home Agent & PCU as having non-compliant BARs (Bjorn Helgaas

  Resource management:
   - Mark shadow copy of VGA ROM as IORESOURCE_PCI_FIXED (Bjorn Helgaas)
   - Don't assign or reassign immutable resources (Bjorn Helgaas)
   - Don't enable/disable ROM BAR if we're using a RAM shadow copy (Bjorn Helgaas)
   - Set ROM shadow location in arch code, not in PCI core (Bjorn Helgaas)
   - Remove arch-specific IORESOURCE_ROM_SHADOW size from sysfs (Bjorn Helgaas)
   - ia64: Use ioremap() instead of open-coded equivalent (Bjorn Helgaas)
   - ia64: Keep CPU physical (not virtual) addresses in shadow ROM resource (Bjorn Helgaas)
   - MIPS: Keep CPU physical (not virtual) addresses in shadow ROM resource (Bjorn Helgaas)
   - Remove unused IORESOURCE_ROM_COPY and IORESOURCE_ROM_BIOS_COPY (Bjorn Helgaas)
   - Don't leak memory if sysfs_create_bin_file() fails (Bjorn Helgaas)
   - rcar: Remove PCI_PROBE_ONLY handling (Lorenzo Pieralisi)
   - designware: Remove PCI_PROBE_ONLY handling (Lorenzo Pieralisi)

  Virtualization:
   - Wait for up to 1000ms after FLR reset (Alex Williamson)
   - Support SR-IOV on any function type (Kelly Zytaruk)
   - Add ACS quirk for all Cavium devices (Manish Jaggi)

  AER:
   - Rename pci_ops_aer to aer_inj_pci_ops (Bjorn Helgaas)
   - Restore pci_ops pointer while calling original pci_ops (David Daney)
   - Fix aer_inject error codes (Jean Delvare)
   - Use dev_warn() in aer_inject (Jean Delvare)
   - Log actual error causes in aer_inject (Jean Delvare)
   - Log aer_inject error injections (Jean Delvare)

  VPD:
   - Prevent VPD access for buggy devices (Babu Moger)
   - Move pci_read_vpd() and pci_write_vpd() close to other VPD code (Bjorn Helgaas)
   - Move pci_vpd_release() from header file to pci/access.c (Bjorn Helgaas)
   - Remove struct pci_vpd_ops.release function pointer (Bjorn Helgaas)
   - Rename VPD symbols to remove unnecessary "pci22" (Bjorn Helgaas)
   - Fold struct pci_vpd_pci22 into struct pci_vpd (Bjorn Helgaas)
   - Sleep rather than busy-wait for VPD access completion (Bjorn Helgaas)
   - Update VPD definitions (Hannes Reinecke)
   - Allow access to VPD attributes with size 0 (Hannes Reinecke)
   - Determine actual VPD size on first access (Hannes Reinecke)

  Generic host bridge driver:
   - Move structure definitions to separate header file (David Daney)
   - Add pci_host_common_probe(), based on gen_pci_probe() (David Daney)
   - Expose pci_host_common_probe() for use by other drivers (David Daney)

  Altera host bridge driver:
   - Fix altera_pcie_link_is_up() (Ley Foon Tan)

  Cavium ThunderX host bridge driver:
   - Add PCIe host driver for ThunderX processors (David Daney)
   - Add driver for ThunderX-pass{1,2} on-chip devices (David Daney)

  Freescale i.MX6 host bridge driver:
   - Add DT bindings to configure PHY Tx driver settings (Justin Waters)
   - Move imx6_pcie_reset_phy() near other PHY handling functions (Lucas Stach)
   - Move PHY reset into imx6_pcie_establish_link() (Lucas Stach)
   - Remove broken Gen2 workaround (Lucas Stach)
   - Move link up check into imx6_pcie_wait_for_link() (Lucas Stach)

  Freescale Layerscape host bridge driver:
   - Add "fsl,ls2085a-pcie" compatible ID (Yang Shi)

  Intel VMD host bridge driver:
   - Attach VMD resources to parent domain's resource tree (Jon Derrick)
   - Set bus resource start to 0 (Keith Busch)

  Microsoft Hyper-V host bridge driver:
   - Add fwnode_handle to x86 pci_sysdata (Jake Oshins)
   - Look up IRQ domain by fwnode_handle (Jake Oshins)
   - Add paravirtual PCI front-end for Microsoft Hyper-V VMs (Jake Oshins)

  NVIDIA Tegra host bridge driver:
   - Add pci_ops.{add,remove}_bus() callbacks (Thierry Reding)
   - Implement ->{add,remove}_bus() callbacks (Thierry Reding)
   - Remove unused struct tegra_pcie.num_ports field (Thierry Reding)
   - Track bus -> CPU mapping (Thierry Reding)
   - Remove misleading PHYS_OFFSET (Thierry Reding)

  Renesas R-Car host bridge driver:
   - Depend on ARCH_RENESAS, not ARCH_SHMOBILE (Simon Horman)

  Synopsys DesignWare host bridge driver:
   - ARC: Add PCI support (Joao Pinto)
   - Add generic dw_pcie_wait_for_link() (Joao Pinto)
   - Add default link up check if sub-driver doesn't override (Joao Pinto)
   - Add driver for prototyping kits based on ARC SDP (Joao Pinto)

  TI Keystone host bridge driver:
   - Defer probing if devm_phy_get() returns -EPROBE_DEFER (Shawn Lin)

  Xilinx AXI host bridge driver:
   - Use of_pci_get_host_bridge_resources() to parse DT (Bharat Kumar Gogada)
   - Remove dependency on ARM-specific struct hw_pci (Bharat Kumar Gogada)
   - Don't call pci_fixup_irqs() on Microblaze (Bharat Kumar Gogada)
   - Update Zynq binding with Microblaze node (Bharat Kumar Gogada)
   - microblaze: Support generic Xilinx AXI PCIe Host Bridge IP driver (Bharat Kumar Gogada)

  Xilinx NWL host bridge driver:
   - Add support for Xilinx NWL PCIe Host Controller (Bharat Kumar Gogada)

  Miscellaneous:
   - Check device_attach() return value always (Bjorn Helgaas)
   - Move pci_set_flags() from asm-generic/pci-bridge.h to linux/pci.h (Bjorn Helgaas)
   - Remove includes of empty asm-generic/pci-bridge.h (Bjorn Helgaas)
   - ARM64: Remove generated include of asm-generic/pci-bridge.h (Bjorn Helgaas)
   - Remove empty asm-generic/pci-bridge.h (Bjorn Helgaas)
   - Remove includes of asm/pci-bridge.h (Bjorn Helgaas)
   - Consolidate PCI DMA constants and interfaces in linux/pci-dma-compat.h (Bjorn Helgaas)
   - unicore32: Remove unused HAVE_ARCH_PCI_SET_DMA_MASK definition (Bjorn Helgaas)
   - Cleanup pci/pcie/Kconfig whitespace (Andreas Ziegler)
   - Include pci/hotplug Kconfig directly from pci/Kconfig (Bjorn Helgaas)
   - Include pci/pcie/Kconfig directly from pci/Kconfig (Bogicevic Sasa)
   - frv: Remove stray pci_{alloc,free}_consistent() declaration (Christoph Hellwig)
   - Move pci_dma_* helpers to common code (Christoph Hellwig)
   - Add PCI_CLASS_SERIAL_USB_DEVICE definition (Heikki Krogerus)
   - Add QEMU top-level IDs for (sub)vendor & device (Robin H. Johnson)
   - Fix broken URL for Dell biosdevname (Naga Venkata Sai Indubhaskar Jupudi)"

* tag 'pci-v4.6-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: (94 commits)
  PCI: Add PCI_CLASS_SERIAL_USB_DEVICE definition
  PCI: designware: Add driver for prototyping kits based on ARC SDP
  PCI: designware: Add default link up check if sub-driver doesn't override
  PCI: designware: Add generic dw_pcie_wait_for_link()
  PCI: Cleanup pci/pcie/Kconfig whitespace
  PCI: Simplify pci_create_attr() control flow
  PCI: Don't leak memory if sysfs_create_bin_file() fails
  PCI: Simplify sysfs ROM cleanup
  PCI: Remove unused IORESOURCE_ROM_COPY and IORESOURCE_ROM_BIOS_COPY
  MIPS: Loongson 3: Keep CPU physical (not virtual) addresses in shadow ROM resource
  MIPS: Loongson 3: Use temporary struct resource * to avoid repetition
  ia64/PCI: Keep CPU physical (not virtual) addresses in shadow ROM resource
  ia64/PCI: Use ioremap() instead of open-coded equivalent
  ia64/PCI: Use temporary struct resource * to avoid repetition
  PCI: Clean up pci_map_rom() whitespace
  PCI: Remove arch-specific IORESOURCE_ROM_SHADOW size from sysfs
  PCI: thunder: Add driver for ThunderX-pass{1,2} on-chip devices
  PCI: thunder: Add PCIe host driver for ThunderX processors
  PCI: generic: Expose pci_host_common_probe() for use by other drivers
  PCI: generic: Add pci_host_common_probe(), based on gen_pci_probe()
  ...

17 files changed:
1  2 
MAINTAINERS
arch/arc/Kconfig
arch/arm64/Kconfig
arch/m32r/Kconfig
arch/mips/Kconfig
arch/powerpc/Kconfig
arch/s390/Kconfig
arch/s390/include/asm/pci.h
arch/x86/Kconfig
arch/x86/pci/common.c
drivers/misc/cxl/pci.c
drivers/pci/host/Kconfig
drivers/pci/host/pci-layerscape.c
drivers/pci/pci.c
drivers/virtio/virtio_pci_common.c
include/linux/ioport.h
include/linux/pci.h

diff --combined MAINTAINERS
@@@ -223,7 -223,9 +223,7 @@@ F: drivers/scsi/aacraid
  
  ABI/API
  L:    linux-api@vger.kernel.org
 -F:    Documentation/ABI/
  F:    include/linux/syscalls.h
 -F:    include/uapi/
  F:    kernel/sys_ni.c
  
  ABIT UGURU 1,2 HARDWARE MONITOR DRIVER
@@@ -684,6 -686,13 +684,6 @@@ M:        Michael Hanselmann <linux-kernel@han
  S:    Supported
  F:    drivers/macintosh/ams/
  
 -AMSO1100 RNIC DRIVER
 -M:    Tom Tucker <tom@opengridcomputing.com>
 -M:    Steve Wise <swise@opengridcomputing.com>
 -L:    linux-rdma@vger.kernel.org
 -S:    Maintained
 -F:    drivers/infiniband/hw/amso1100/
 -
  ANALOG DEVICES INC AD9389B DRIVER
  M:    Hans Verkuil <hans.verkuil@cisco.com>
  L:    linux-media@vger.kernel.org
@@@ -920,24 -929,17 +920,24 @@@ M:      Emilio López <emilio@elopez.com.ar
  S:    Maintained
  F:    drivers/clk/sunxi/
  
 -ARM/Amlogic MesonX SoC support
 +ARM/Amlogic Meson SoC support
  M:    Carlo Caione <carlo@caione.org>
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
 +L:    linux-meson@googlegroups.com
 +W:    http://linux-meson.com/
  S:    Maintained
 -F:    drivers/media/rc/meson-ir.c
 -N:    meson[x68]
 +F:    arch/arm/mach-meson/
 +F:    arch/arm/boot/dts/meson*
 +N:    meson
  
  ARM/Annapurna Labs ALPINE ARCHITECTURE
  M:    Tsahee Zidenberg <tsahee@annapurnalabs.com>
 +M:    Antoine Tenart <antoine.tenart@free-electrons.com>
  S:    Maintained
  F:    arch/arm/mach-alpine/
 +F:    arch/arm/boot/dts/alpine*
 +F:    arch/arm64/boot/dts/al/
 +F:    drivers/*/*alpine*
  
  ARM/ATMEL AT91RM9200, AT91SAM9 AND SAMA5 SOC SUPPORT
  M:    Nicolas Ferre <nicolas.ferre@atmel.com>
@@@ -965,8 -967,6 +965,8 @@@ M: Rob Herring <robh@kernel.org
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
  S:    Maintained
  F:    arch/arm/mach-highbank/
 +F:    arch/arm/boot/dts/highbank.dts
 +F:    arch/arm/boot/dts/ecx-*.dts*
  
  ARM/CAVIUM NETWORKS CNS3XXX MACHINE SUPPORT
  M:    Krzysztof Halasa <khalasa@piap.pl>
@@@ -1042,7 -1042,6 +1042,7 @@@ M:      Barry Song <baohua@kernel.org
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/baohua/linux.git
  S:    Maintained
 +F:    arch/arm/boot/dts/prima2*
  F:    arch/arm/mach-prima2/
  F:    drivers/clk/sirf/
  F:    drivers/clocksource/timer-prima2.c
@@@ -1144,10 -1143,6 +1144,10 @@@ W:    http://www.hisilicon.co
  S:    Supported
  T:    git git://github.com/hisilicon/linux-hisi.git
  F:    arch/arm/mach-hisi/
 +F:    arch/arm/boot/dts/hi3*
 +F:    arch/arm/boot/dts/hip*
 +F:    arch/arm/boot/dts/hisi*
 +F:    arch/arm64/boot/dts/hisilicon/
  
  ARM/HP JORNADA 7XX MACHINE SUPPORT
  M:    Kristoffer Ericson <kristoffer.ericson@gmail.com>
@@@ -1224,7 -1219,6 +1224,7 @@@ M:      Santosh Shilimkar <ssantosh@kernel.o
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
  S:    Maintained
  F:    arch/arm/mach-keystone/
 +F:    arch/arm/boot/dts/k2*
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone.git
  
  ARM/TEXAS INSTRUMENT KEYSTONE CLOCK FRAMEWORK
@@@ -1293,7 -1287,6 +1293,7 @@@ L:      linux-arm-kernel@lists.infradead.or
  S:    Maintained
  F:    arch/arm/mach-berlin/
  F:    arch/arm/boot/dts/berlin*
 +F:    arch/arm64/boot/dts/marvell/berlin*
  
  
  ARM/Marvell Dove/MV78xx0/Orion SOC support
@@@ -1432,7 -1425,6 +1432,7 @@@ S:      Maintaine
  F:    arch/arm/boot/dts/qcom-*.dts
  F:    arch/arm/boot/dts/qcom-*.dtsi
  F:    arch/arm/mach-qcom/
 +F:    arch/arm64/boot/dts/qcom/*
  F:    drivers/soc/qcom/
  F:    drivers/tty/serial/msm_serial.h
  F:    drivers/tty/serial/msm_serial.c
@@@ -1449,8 -1441,8 +1449,8 @@@ S:      Maintaine
  ARM/RENESAS ARM64 ARCHITECTURE
  M:    Simon Horman <horms@verge.net.au>
  M:    Magnus Damm <magnus.damm@gmail.com>
 -L:    linux-sh@vger.kernel.org
 -Q:    http://patchwork.kernel.org/project/linux-sh/list/
 +L:    linux-renesas-soc@vger.kernel.org
 +Q:    http://patchwork.kernel.org/project/linux-renesas-soc/list/
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas.git next
  S:    Supported
  F:    arch/arm64/boot/dts/renesas/
@@@ -1492,8 -1484,6 +1492,8 @@@ L:      linux-arm-kernel@lists.infradead.or
  L:    linux-samsung-soc@vger.kernel.org (moderated for non-subscribers)
  S:    Maintained
  F:    arch/arm/boot/dts/s3c*
 +F:    arch/arm/boot/dts/s5p*
 +F:    arch/arm/boot/dts/samsung*
  F:    arch/arm/boot/dts/exynos*
  F:    arch/arm64/boot/dts/exynos/
  F:    arch/arm/plat-samsung/
@@@ -1573,7 -1563,6 +1573,7 @@@ S:      Maintaine
  F:    arch/arm/mach-socfpga/
  F:    arch/arm/boot/dts/socfpga*
  F:    arch/arm/configs/socfpga_defconfig
 +F:    arch/arm64/boot/dts/altera/
  W:    http://www.rocketboards.org
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux.git
  
@@@ -1727,7 -1716,7 +1727,7 @@@ M:      Lorenzo Pieralisi <lorenzo.pieralisi
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
  S:    Maintained
  F:    arch/arm/boot/dts/vexpress*
 -F:    arch/arm64/boot/dts/arm/vexpress*
 +F:    arch/arm64/boot/dts/arm/
  F:    arch/arm/mach-vexpress/
  F:    */*/vexpress*
  F:    */*/*/vexpress*
@@@ -2354,7 -2343,6 +2354,7 @@@ F:      arch/arm/mach-bcm
  F:    arch/arm/boot/dts/bcm113*
  F:    arch/arm/boot/dts/bcm216*
  F:    arch/arm/boot/dts/bcm281*
 +F:    arch/arm64/boot/dts/broadcom/
  F:    arch/arm/configs/bcm_defconfig
  F:    drivers/mmc/host/sdhci-bcm-kona.c
  F:    drivers/clocksource/bcm_kona_timer.c
@@@ -2369,6 -2357,14 +2369,6 @@@ T:     git git://git.kernel.org/pub/scm/lin
  S:    Maintained
  N:    bcm2835
  
 -BROADCOM BCM33XX MIPS ARCHITECTURE
 -M:    Kevin Cernekee <cernekee@gmail.com>
 -L:    linux-mips@linux-mips.org
 -S:    Maintained
 -F:    arch/mips/bcm3384/*
 -F:    arch/mips/include/asm/mach-bcm3384/*
 -F:    arch/mips/kernel/*bmips*
 -
  BROADCOM BCM47XX MIPS ARCHITECTURE
  M:    Hauke Mehrtens <hauke@hauke-m.de>
  M:    Rafał Miłecki <zajec5@gmail.com>
@@@ -2422,7 -2418,6 +2422,7 @@@ F:      arch/mips/bmips/
  F:    arch/mips/include/asm/mach-bmips/*
  F:    arch/mips/kernel/*bmips*
  F:    arch/mips/boot/dts/brcm/bcm*.dts*
 +F:    drivers/irqchip/irq-bcm63*
  F:    drivers/irqchip/irq-bcm7*
  F:    drivers/irqchip/irq-brcmstb*
  F:    include/linux/bcm963xx_nvram.h
@@@ -3450,8 -3445,9 +3450,8 @@@ S:      Maintaine
  F:    drivers/usb/dwc2/
  
  DESIGNWARE USB3 DRD IP DRIVER
 -M:    Felipe Balbi <balbi@ti.com>
 +M:    Felipe Balbi <balbi@kernel.org>
  L:    linux-usb@vger.kernel.org
 -L:    linux-omap@vger.kernel.org
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
  S:    Maintained
  F:    drivers/usb/dwc3/
@@@ -4188,6 -4184,13 +4188,6 @@@ W:     http://aeschi.ch.eu.org/efs
  S:    Orphan
  F:    fs/efs/
  
 -EHCA (IBM GX bus InfiniBand adapter) DRIVER
 -M:    Hoang-Nam Nguyen <hnguyen@de.ibm.com>
 -M:    Christoph Raisch <raisch@de.ibm.com>
 -L:    linux-rdma@vger.kernel.org
 -S:    Supported
 -F:    drivers/infiniband/hw/ehca/
 -
  EHEA (IBM pSeries eHEA 10Gb ethernet adapter) DRIVER
  M:    Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
  L:    netdev@vger.kernel.org
@@@ -4519,12 -4522,6 +4519,12 @@@ L:    linuxppc-dev@lists.ozlabs.or
  S:    Maintained
  F:    drivers/dma/fsldma.*
  
 +FREESCALE GPMI NAND DRIVER
 +M:    Han Xu <han.xu@nxp.com>
 +L:    linux-mtd@lists.infradead.org
 +S:    Maintained
 +F:    drivers/mtd/nand/gpmi-nand/*
 +
  FREESCALE I2C CPM DRIVER
  M:    Jochen Friedrich <jochen@scram.de>
  L:    linuxppc-dev@lists.ozlabs.org
@@@ -4541,7 -4538,7 +4541,7 @@@ F:      include/linux/platform_data/video-im
  F:    drivers/video/fbdev/imxfb.c
  
  FREESCALE QUAD SPI DRIVER
 -M:    Han Xu <han.xu@freescale.com>
 +M:    Han Xu <han.xu@nxp.com>
  L:    linux-mtd@lists.infradead.org
  S:    Maintained
  F:    drivers/mtd/spi-nor/fsl-quadspi.c
@@@ -4555,15 -4552,6 +4555,15 @@@ S:    Maintaine
  F:    drivers/net/ethernet/freescale/fs_enet/
  F:    include/linux/fs_enet_pd.h
  
 +FREESCALE IMX / MXC FEC DRIVER
 +M:    Fugang Duan <fugang.duan@nxp.com>
 +L:    netdev@vger.kernel.org
 +S:    Maintained
 +F:    drivers/net/ethernet/freescale/fec_main.c
 +F:    drivers/net/ethernet/freescale/fec_ptp.c
 +F:    drivers/net/ethernet/freescale/fec.h
 +F:    Documentation/devicetree/bindings/net/fsl-fec.txt
 +
  FREESCALE QUICC ENGINE LIBRARY
  L:    linuxppc-dev@lists.ozlabs.org
  S:    Orphan
@@@ -5205,6 -5193,7 +5205,7 @@@ F:      arch/x86/kernel/cpu/mshyperv.
  F:    drivers/hid/hid-hyperv.c
  F:    drivers/hv/
  F:    drivers/input/serio/hyperv-keyboard.c
+ F:    drivers/pci/host/pci-hyperv.c
  F:    drivers/net/hyperv/
  F:    drivers/scsi/storvsc_drv.c
  F:    drivers/video/fbdev/hyperv_fb.c
@@@ -5821,6 -5810,12 +5822,6 @@@ M:     Juanjo Ciarlante <jjciarla@raiz.uncu
  S:    Maintained
  F:    net/ipv4/netfilter/ipt_MASQUERADE.c
  
 -IPATH DRIVER
 -M:    Mike Marciniszyn <infinipath@intel.com>
 -L:    linux-rdma@vger.kernel.org
 -S:    Maintained
 -F:    drivers/staging/rdma/ipath/
 -
  IPMI SUBSYSTEM
  M:    Corey Minyard <minyard@acm.org>
  L:    openipmi-developer@lists.sourceforge.net (moderated for non-subscribers)
@@@ -6150,7 -6145,7 +6151,7 @@@ F:      include/uapi/linux/sunrpc
  
  KERNEL SELFTEST FRAMEWORK
  M:    Shuah Khan <shuahkh@osg.samsung.com>
 -L:    linux-api@vger.kernel.org
 +L:    linux-kselftest@vger.kernel.org
  T:    git git://git.kernel.org/pub/scm/shuah/linux-kselftest
  S:    Maintained
  F:    tools/testing/selftests
@@@ -6780,7 -6775,6 +6781,7 @@@ S:      Maintaine
  F:    Documentation/networking/mac80211-injection.txt
  F:    include/net/mac80211.h
  F:    net/mac80211/
 +F:    drivers/net/wireless/mac80211_hwsim.[ch]
  
  MACVLAN DRIVER
  M:    Patrick McHardy <kaber@trash.net>
@@@ -6910,7 -6904,7 +6911,7 @@@ MAXIM MAX77802 MULTIFUNCTION PMIC DEVIC
  M:    Javier Martinez Canillas <javier@osg.samsung.com>
  L:    linux-kernel@vger.kernel.org
  S:    Supported
 -F:    drivers/*/*max77802.c
 +F:    drivers/*/*max77802*.c
  F:    Documentation/devicetree/bindings/*/*max77802.txt
  F:    include/dt-bindings/*/*max77802.h
  
@@@ -6920,7 -6914,7 +6921,7 @@@ M:      Krzysztof Kozlowski <k.kozlowski@sam
  L:    linux-kernel@vger.kernel.org
  S:    Supported
  F:    drivers/*/max14577.c
 -F:    drivers/*/max77686.c
 +F:    drivers/*/max77686*.c
  F:    drivers/*/max77693.c
  F:    drivers/extcon/extcon-max14577.c
  F:    drivers/extcon/extcon-max77693.c
@@@ -7377,7 -7371,7 +7378,7 @@@ F:      drivers/tty/isicom.
  F:    include/linux/isicom.h
  
  MUSB MULTIPOINT HIGH SPEED DUAL-ROLE CONTROLLER
 -M:    Felipe Balbi <balbi@ti.com>
 +M:    Bin Liu <b-liu@ti.com>
  L:    linux-usb@vger.kernel.org
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
  S:    Maintained
@@@ -7400,17 -7394,6 +7401,17 @@@ W:    https://www.myricom.com/support/down
  S:    Supported
  F:    drivers/net/ethernet/myricom/myri10ge/
  
 +NAND FLASH SUBSYSTEM
 +M:    Boris Brezillon <boris.brezillon@free-electrons.com>
 +R:    Richard Weinberger <richard@nod.at>
 +L:    linux-mtd@lists.infradead.org
 +W:    http://www.linux-mtd.infradead.org/
 +Q:    http://patchwork.ozlabs.org/project/linux-mtd/list/
 +T:    git git://github.com/linux-nand/linux.git
 +S:    Maintained
 +F:    drivers/mtd/nand/
 +F:    include/linux/mtd/nand*.h
 +
  NATSEMI ETHERNET DRIVER (DP8381x)
  S:    Orphan
  F:    drivers/net/ethernet/natsemi/natsemi.c
@@@ -7720,13 -7703,13 +7721,13 @@@ S:   Maintaine
  F:    arch/nios2/
  
  NOKIA N900 POWER SUPPLY DRIVERS
 -M:    Pali Rohár <pali.rohar@gmail.com>
 -S:    Maintained
 +R:    Pali Rohár <pali.rohar@gmail.com>
  F:    include/linux/power/bq2415x_charger.h
  F:    include/linux/power/bq27xxx_battery.h
  F:    include/linux/power/isp1704_charger.h
  F:    drivers/power/bq2415x_charger.c
  F:    drivers/power/bq27xxx_battery.c
 +F:    drivers/power/bq27xxx_battery_i2c.c
  F:    drivers/power/isp1704_charger.c
  F:    drivers/power/rx51_battery.c
  
@@@ -7957,9 -7940,11 +7958,9 @@@ F:     drivers/media/platform/omap3isp
  F:    drivers/staging/media/omap4iss/
  
  OMAP USB SUPPORT
 -M:    Felipe Balbi <balbi@ti.com>
  L:    linux-usb@vger.kernel.org
  L:    linux-omap@vger.kernel.org
 -T:    git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
 -S:    Maintained
 +S:    Orphan
  F:    drivers/usb/*/*omap*
  F:    arch/arm/*omap*/usb*
  
@@@ -8383,12 -8368,20 +8384,20 @@@ L:   linux-pci@vger.kernel.or
  S:    Maintained
  F:    drivers/pci/host/*designware*
  
+ PCI DRIVER FOR SYNOPSYS PROTOTYPING DEVICE
+ M:    Joao Pinto <jpinto@synopsys.com>
+ L:    linux-pci@vger.kernel.org
+ S:    Maintained
+ F:    Documentation/devicetree/bindings/pci/designware-pcie.txt
+ F:    drivers/pci/host/pcie-designware-plat.c
  PCI DRIVER FOR GENERIC OF HOSTS
  M:    Will Deacon <will.deacon@arm.com>
  L:    linux-pci@vger.kernel.org
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
  S:    Maintained
  F:    Documentation/devicetree/bindings/pci/host-generic-pci.txt
+ F:    drivers/pci/host/pci-host-common.c
  F:    drivers/pci/host/pci-host-generic.c
  
  PCI DRIVER FOR INTEL VOLUME MANAGEMENT DEVICE (VMD)
@@@ -8434,6 -8427,14 +8443,14 @@@ L:     linux-arm-msm@vger.kernel.or
  S:     Maintained
  F:     drivers/pci/host/*qcom*
  
+ PCIE DRIVER FOR CAVIUM THUNDERX
+ M:    David Daney <david.daney@cavium.com>
+ L:    linux-pci@vger.kernel.org
+ L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
+ S:    Supported
+ F:    Documentation/devicetree/bindings/pci/pci-thunder-*
+ F:    drivers/pci/host/pci-thunder-*
  PCMCIA SUBSYSTEM
  P:    Linux PCMCIA Team
  L:    linux-pcmcia@lists.infradead.org
@@@ -8476,7 -8477,6 +8493,7 @@@ PERFORMANCE EVENTS SUBSYSTE
  M:    Peter Zijlstra <peterz@infradead.org>
  M:    Ingo Molnar <mingo@redhat.com>
  M:    Arnaldo Carvalho de Melo <acme@kernel.org>
 +R:    Alexander Shishkin <alexander.shishkin@linux.intel.com>
  L:    linux-kernel@vger.kernel.org
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git perf/core
  S:    Supported
@@@ -8835,7 -8835,6 +8852,7 @@@ L:      linux-arm-kernel@lists.infradead.or
  T:    git git://github.com/hzhuang1/linux.git
  T:    git git://github.com/rjarzmik/linux.git
  S:    Maintained
 +F:    arch/arm/boot/dts/pxa*
  F:    arch/arm/mach-pxa/
  F:    drivers/dma/pxa*
  F:    drivers/pcmcia/pxa2xx*
@@@ -8865,7 -8864,6 +8882,7 @@@ L:      linux-arm-kernel@lists.infradead.or
  T:    git git://github.com/hzhuang1/linux.git
  T:    git git://git.linaro.org/people/ycmiao/pxa-linux.git
  S:    Maintained
 +F:    arch/arm/boot/dts/mmp*
  F:    arch/arm/mach-mmp/
  
  PXA MMCI DRIVER
@@@ -9591,12 -9589,6 +9608,12 @@@ M:    Andreas Noever <andreas.noever@gmail
  S:    Maintained
  F:    drivers/thunderbolt/
  
 +TI BQ27XXX POWER SUPPLY DRIVER
 +R:    Andrew F. Davis <afd@ti.com>
 +F:    include/linux/power/bq27xxx_battery.h
 +F:    drivers/power/bq27xxx_battery.c
 +F:    drivers/power/bq27xxx_battery_i2c.c
 +
  TIMEKEEPING, CLOCKSOURCE CORE, NTP, ALARMTIMER
  M:    John Stultz <john.stultz@linaro.org>
  M:    Thomas Gleixner <tglx@linutronix.de>
@@@ -9818,11 -9810,10 +9835,11 @@@ S:   Supporte
  F:    drivers/scsi/be2iscsi/
  
  Emulex 10Gbps NIC BE2, BE3-R, Lancer, Skyhawk-R DRIVER
 -M:    Sathya Perla <sathya.perla@avagotech.com>
 -M:    Ajit Khaparde <ajit.khaparde@avagotech.com>
 -M:    Padmanabh Ratnakar <padmanabh.ratnakar@avagotech.com>
 -M:    Sriharsha Basavapatna <sriharsha.basavapatna@avagotech.com>
 +M:    Sathya Perla <sathya.perla@broadcom.com>
 +M:    Ajit Khaparde <ajit.khaparde@broadcom.com>
 +M:    Padmanabh Ratnakar <padmanabh.ratnakar@broadcom.com>
 +M:    Sriharsha Basavapatna <sriharsha.basavapatna@broadcom.com>
 +M:    Somnath Kotur <somnath.kotur@broadcom.com>
  L:    netdev@vger.kernel.org
  W:    http://www.emulex.com
  S:    Supported
@@@ -10184,7 -10175,6 +10201,7 @@@ S:   Supporte
  F:    drivers/media/pci/solo6x10/
  
  SOFTWARE RAID (Multiple Disks) SUPPORT
 +M:    Shaohua Li <shli@kernel.org>
  L:    linux-raid@vger.kernel.org
  T:    git git://neil.brown.name/md
  S:    Supported
@@@ -10200,7 -10190,7 +10217,7 @@@ F:   drivers/net/ethernet/natsemi/sonic.
  
  SONICS SILICON BACKPLANE DRIVER (SSB)
  M:    Michael Buesch <m@bues.ch>
 -L:    netdev@vger.kernel.org
 +L:    linux-wireless@vger.kernel.org
  S:    Maintained
  F:    drivers/ssb/
  F:    include/linux/ssb/
@@@ -10318,7 -10308,6 +10335,7 @@@ L:   spear-devel@list.st.co
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
  W:    http://www.st.com/spear
  S:    Maintained
 +F:    arch/arm/boot/dts/spear*
  F:    arch/arm/mach-spear/
  
  SPEAR CLOCK FRAMEWORK SUPPORT
@@@ -11346,7 -11335,7 +11363,7 @@@ F:   Documentation/usb/ehci.tx
  F:    drivers/usb/host/ehci*
  
  USB GADGET/PERIPHERAL SUBSYSTEM
 -M:    Felipe Balbi <balbi@ti.com>
 +M:    Felipe Balbi <balbi@kernel.org>
  L:    linux-usb@vger.kernel.org
  W:    http://www.linux-usb.org/gadget
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
@@@ -11422,7 -11411,7 +11439,7 @@@ S:   Maintaine
  F:    drivers/net/usb/pegasus.*
  
  USB PHY LAYER
 -M:    Felipe Balbi <balbi@ti.com>
 +M:    Felipe Balbi <balbi@kernel.org>
  L:    linux-usb@vger.kernel.org
  T:    git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
  S:    Maintained
@@@ -12052,6 -12041,7 +12069,6 @@@ F:   arch/arm64/xen
  F:    arch/arm64/include/asm/xen/
  
  XEN NETWORK BACKEND DRIVER
 -M:    Ian Campbell <ian.campbell@citrix.com>
  M:    Wei Liu <wei.liu2@citrix.com>
  L:    xen-devel@lists.xenproject.org (moderated for non-subscribers)
  L:    netdev@vger.kernel.org
@@@ -12160,7 -12150,7 +12177,7 @@@ F:   drivers/net/hamradio/*scc.
  F:    drivers/net/hamradio/z8530.h
  
  ZBUD COMPRESSED PAGE ALLOCATOR
 -M:    Seth Jennings <sjennings@variantweb.net>
 +M:    Seth Jennings <sjenning@redhat.com>
  L:    linux-mm@kvack.org
  S:    Maintained
  F:    mm/zbud.c
@@@ -12215,7 -12205,7 +12232,7 @@@ F:   include/linux/zsmalloc.
  F:    Documentation/vm/zsmalloc.txt
  
  ZSWAP COMPRESSED SWAP CACHING
 -M:    Seth Jennings <sjennings@variantweb.net>
 +M:    Seth Jennings <sjenning@redhat.com>
  L:    linux-mm@kvack.org
  S:    Maintained
  F:    mm/zswap.c
diff --combined arch/arc/Kconfig
@@@ -12,11 -12,14 +12,12 @@@ config AR
        select BUILDTIME_EXTABLE_SORT
        select COMMON_CLK
        select CLONE_BACKWARDS
 -      # ARC Busybox based initramfs absolutely relies on DEVTMPFS for /dev
 -      select DEVTMPFS if !INITRAMFS_SOURCE=""
        select GENERIC_ATOMIC64
        select GENERIC_CLOCKEVENTS
        select GENERIC_FIND_FIRST_BIT
        # for now, we don't need GENERIC_IRQ_PROBE, CONFIG_GENERIC_IRQ_CHIP
        select GENERIC_IRQ_SHOW
+       select GENERIC_PCI_IOMAP
        select GENERIC_PENDING_IRQ if SMP
        select GENERIC_SMP_IDLE_THREAD
        select HAVE_ARCH_KGDB
@@@ -37,6 -40,9 +38,9 @@@
        select PERF_USE_VMALLOC
        select HAVE_DEBUG_STACKOVERFLOW
  
+ config MIGHT_HAVE_PCI
+       bool
  config TRACE_IRQFLAGS_SUPPORT
        def_bool y
  
@@@ -273,6 -279,14 +277,6 @@@ config ARC_DCCM_BAS
        default "0xA0000000"
        depends on ARC_HAS_DCCM
  
 -config ARC_HAS_HW_MPY
 -      bool "Use Hardware Multiplier (Normal or Faster XMAC)"
 -      default y
 -      help
 -        Influences how gcc generates code for MPY operations.
 -        If enabled, MPYxx insns are generated, provided by Standard/XMAC
 -        Multipler. Otherwise software multipy lib is used
 -
  choice
        prompt "MMU Version"
        default ARC_MMU_V3 if ARC_CPU_770
@@@ -328,19 -342,6 +332,19 @@@ config ARC_PAGE_SIZE_4
  
  endchoice
  
 +choice
 +      prompt "MMU Super Page Size"
 +      depends on ISA_ARCV2 && TRANSPARENT_HUGEPAGE
 +      default ARC_HUGEPAGE_2M
 +
 +config ARC_HUGEPAGE_2M
 +      bool "2MB"
 +
 +config ARC_HUGEPAGE_16M
 +      bool "16MB"
 +
 +endchoice
 +
  if ISA_ARCOMPACT
  
  config ARC_COMPACT_IRQ_LEVELS
@@@ -413,7 -414,7 +417,7 @@@ config ARC_HAS_RT
        default n
        depends on !SMP
  
 -config ARC_HAS_GRTC
 +config ARC_HAS_GFRC
        bool "SMP synchronized 64-bit cycle counter"
        default y
        depends on SMP
@@@ -532,6 -533,14 +536,6 @@@ config ARC_DBG_TLB_MISS_COUN
          Counts number of I and D TLB Misses and exports them via Debugfs
          The counters can be cleared via Debugfs as well
  
 -if SMP
 -
 -config ARC_IPI_DBG
 -      bool "Debug Inter Core interrupts"
 -      default n
 -
 -endif
 -
  endif
  
  config ARC_UBOOT_SUPPORT
@@@ -561,14 -570,30 +565,36 @@@ endmen
  endmenu        # "ARC Architecture Configuration"
  
  source "mm/Kconfig"
 +
 +config FORCE_MAX_ZONEORDER
 +      int "Maximum zone order"
 +      default "12" if ARC_HUGEPAGE_16M
 +      default "11"
 +
  source "net/Kconfig"
  source "drivers/Kconfig"
+ menu "Bus Support"
+ config PCI
+       bool "PCI support" if MIGHT_HAVE_PCI
+       help
+         PCI is the name of a bus system, i.e., the way the CPU talks to
+         the other stuff inside your box.  Find out if your board/platform
+         has PCI.
+         Note: PCIe support for Synopsys Device will be available only
+         when HAPS DX is configured with PCIe RC bitmap. If you have PCI,
+         say Y, otherwise N.
+ config PCI_SYSCALL
+       def_bool PCI
+ source "drivers/pci/Kconfig"
+ source "drivers/pci/pcie/Kconfig"
+ endmenu
  source "fs/Kconfig"
  source "arch/arc/Kconfig.debug"
  source "security/Kconfig"
diff --combined arch/arm64/Kconfig
@@@ -235,8 -235,6 +235,6 @@@ config PCI_SYSCAL
        def_bool PCI
  
  source "drivers/pci/Kconfig"
- source "drivers/pci/pcie/Kconfig"
- source "drivers/pci/hotplug/Kconfig"
  
  endmenu
  
@@@ -750,19 -748,6 +748,19 @@@ config ARM64_LSE_ATOMIC
          not support these instructions and requires the kernel to be
          built with binutils >= 2.25.
  
 +config ARM64_VHE
 +      bool "Enable support for Virtualization Host Extensions (VHE)"
 +      default y
 +      help
 +        Virtualization Host Extensions (VHE) allow the kernel to run
 +        directly at EL2 (instead of EL1) on processors that support
 +        it. This leads to better performance for KVM, as they reduce
 +        the cost of the world switch.
 +
 +        Selecting this option allows the VHE feature to be detected
 +        at runtime, and does not affect processors that do not
 +        implement this feature.
 +
  endmenu
  
  endmenu
diff --combined arch/m32r/Kconfig
@@@ -276,7 -276,6 +276,7 @@@ source "kernel/Kconfig.preempt
  
  config SMP
        bool "Symmetric multi-processing support"
 +      depends on MMU
        ---help---
          This enables support for systems with more than one CPU. If you have
          a system with only one CPU, say N. If you have a system with more
@@@ -387,8 -386,6 +387,6 @@@ config IS
  
  source "drivers/pcmcia/Kconfig"
  
- source "drivers/pci/hotplug/Kconfig"
  endmenu
  
  
diff --combined arch/mips/Kconfig
@@@ -151,7 -151,6 +151,7 @@@ config BMIPS_GENERI
        select CSRC_R4K
        select SYNC_R4K
        select COMMON_CLK
 +      select BCM6345_L1_IRQ
        select BCM7038_L1_IRQ
        select BCM7120_L2_IRQ
        select BRCMSTB_L2_IRQ
@@@ -2086,7 -2085,7 +2086,7 @@@ config PAGE_SIZE_32K
  
  config PAGE_SIZE_64KB
        bool "64kB"
 -      depends on !CPU_R3000 && !CPU_TX39XX
 +      depends on !CPU_R3000 && !CPU_TX39XX && !CPU_R6000
        help
          Using 64kB page size will result in higher performance kernel at
          the price of higher memory consumption.  This option is available on
@@@ -2170,6 -2169,7 +2170,6 @@@ config MIPS_MT_SM
        select CPU_MIPSR2_IRQ_VI
        select CPU_MIPSR2_IRQ_EI
        select SYNC_R4K
 -      select MIPS_GIC_IPI
        select MIPS_MT
        select SMP
        select SMP_UP
@@@ -2267,6 -2267,7 +2267,6 @@@ config MIPS_VPE_APSP_API_M
  config MIPS_CMP
        bool "MIPS CMP framework support (DEPRECATED)"
        depends on SYS_SUPPORTS_MIPS_CMP && !CPU_MIPSR6
 -      select MIPS_GIC_IPI
        select SMP
        select SYNC_R4K
        select SYS_SUPPORTS_SMP
@@@ -2286,6 -2287,7 +2286,6 @@@ config MIPS_CP
        select MIPS_CM
        select MIPS_CPC
        select MIPS_CPS_PM if HOTPLUG_CPU
 -      select MIPS_GIC_IPI
        select SMP
        select SYNC_R4K if (CEVT_R4K || CSRC_R4K)
        select SYS_SUPPORTS_HOTPLUG_CPU
@@@ -2303,6 -2305,9 +2303,6 @@@ config MIPS_CPS_P
        select MIPS_CPC
        bool
  
 -config MIPS_GIC_IPI
 -      bool
 -
  config MIPS_CM
        bool
  
@@@ -2871,8 -2876,6 +2871,6 @@@ config PCI_DOMAIN
  
  source "drivers/pci/Kconfig"
  
- source "drivers/pci/pcie/Kconfig"
  #
  # ISA support is now enabled via select.  Too many systems still have the one
  # or other ISA chip on the board that users don't know about so don't expect
@@@ -2932,8 -2935,6 +2930,6 @@@ config ZONE_DMA3
  
  source "drivers/pcmcia/Kconfig"
  
- source "drivers/pci/hotplug/Kconfig"
  config RAPIDIO
        tristate "RapidIO support"
        depends on PCI
diff --combined arch/powerpc/Kconfig
@@@ -557,7 -557,7 +557,7 @@@ choic
  
  config PPC_4K_PAGES
        bool "4k page size"
 -      select HAVE_ARCH_SOFT_DIRTY if CHECKPOINT_RESTORE && PPC_BOOK3S
 +      select HAVE_ARCH_SOFT_DIRTY if PPC_BOOK3S_64
  
  config PPC_16K_PAGES
        bool "16k page size"
  config PPC_64K_PAGES
        bool "64k page size"
        depends on !PPC_FSL_BOOK3E && (44x || PPC_STD_MMU_64 || PPC_BOOK3E_64)
 -      select HAVE_ARCH_SOFT_DIRTY if CHECKPOINT_RESTORE && PPC_BOOK3S
 +      select HAVE_ARCH_SOFT_DIRTY if PPC_BOOK3S_64
  
  config PPC_256K_PAGES
        bool "256k page size"
@@@ -828,14 -828,10 +828,10 @@@ config PCI_826
        select PPC_INDIRECT_PCI
        default y
  
- source "drivers/pci/pcie/Kconfig"
  source "drivers/pci/Kconfig"
  
  source "drivers/pcmcia/Kconfig"
  
- source "drivers/pci/hotplug/Kconfig"
  config HAS_RAPIDIO
        bool
        default n
diff --combined arch/s390/Kconfig
@@@ -254,12 -254,12 +254,12 @@@ config MARCH_ZEC1
          older machines.
  
  config MARCH_Z13
 -      bool "IBM z13"
 +      bool "IBM z13s and z13"
        select HAVE_MARCH_Z13_FEATURES
        help
 -        Select this to enable optimizations for IBM z13 (2964 series).
 -        The kernel will be slightly faster but will not work on older
 -        machines.
 +        Select this to enable optimizations for IBM z13s and z13 (2965 and
 +        2964 series). The kernel will be slightly faster but will not work on
 +        older machines.
  
  endchoice
  
@@@ -605,8 -605,6 +605,6 @@@ config PCI_NR_MS
          PCI devices.
  
  source "drivers/pci/Kconfig"
- source "drivers/pci/pcie/Kconfig"
- source "drivers/pci/hotplug/Kconfig"
  
  endif # PCI
  
@@@ -9,7 -9,6 +9,6 @@@
  #include <linux/pci.h>
  #include <linux/mutex.h>
  #include <asm-generic/pci.h>
- #include <asm-generic/pci-dma-compat.h>
  #include <asm/pci_clp.h>
  #include <asm/pci_debug.h>
  
@@@ -45,7 -44,7 +44,7 @@@ struct zpci_fmb 
        u64 rpcit_ops;
        u64 dma_rbytes;
        u64 dma_wbytes;
 -} __packed __aligned(16);
 +} __packed __aligned(64);
  
  enum zpci_state {
        ZPCI_FN_STATE_RESERVED,
@@@ -66,6 -65,7 +65,6 @@@ struct s390_domain
  
  /* Private data per function */
  struct zpci_dev {
 -      struct pci_dev  *pdev;
        struct pci_bus  *bus;
        struct list_head entry;         /* list of all zpci_devices, needed for hotplug, etc. */
  
@@@ -191,7 -191,7 +190,7 @@@ int zpci_fmb_disable_device(struct zpci
  /* Debug */
  int zpci_debug_init(void);
  void zpci_debug_exit(void);
 -void zpci_debug_init_device(struct zpci_dev *);
 +void zpci_debug_init_device(struct zpci_dev *, const char *);
  void zpci_debug_exit_device(struct zpci_dev *);
  void zpci_debug_info(struct zpci_dev *, struct seq_file *);
  
diff --combined arch/x86/Kconfig
@@@ -303,9 -303,6 +303,9 @@@ config ARCH_SUPPORTS_UPROBE
  config FIX_EARLYCON_MEM
        def_bool y
  
 +config DEBUG_RODATA
 +      def_bool y
 +
  config PGTABLE_LEVELS
        int
        default 4 if X86_64
@@@ -478,7 -475,6 +478,7 @@@ config X86_U
        depends on X86_64
        depends on X86_EXTENDED_PLATFORM
        depends on NUMA
 +      depends on EFI
        depends on X86_X2APIC
        depends on PCI
        ---help---
@@@ -513,10 -509,11 +513,10 @@@ config X86_INTEL_C
  
  config X86_INTEL_MID
        bool "Intel MID platform support"
 -      depends on X86_32
        depends on X86_EXTENDED_PLATFORM
        depends on X86_PLATFORM_DEVICES
        depends on PCI
 -      depends on PCI_GOANY
 +      depends on X86_64 || (PCI_GOANY && X86_32)
        depends on X86_IO_APIC
        select SFI
        select I2C
@@@ -781,8 -778,8 +781,8 @@@ config HPET_TIME
          HPET is the next generation timer replacing legacy 8254s.
          The HPET provides a stable time base on SMP
          systems, unlike the TSC, but it is more expensive to access,
 -        as it is off-chip.  You can find the HPET spec at
 -        <http://www.intel.com/hardwaredesign/hpetspec_1.pdf>.
 +        as it is off-chip.  The interface used is documented
 +        in the HPET spec, revision 1.
  
          You can safely choose Y here.  However, HPET will only be
          activated if the platform and the BIOS support this feature.
@@@ -1163,23 -1160,22 +1163,23 @@@ config MICROCOD
        bool "CPU microcode loading support"
        default y
        depends on CPU_SUP_AMD || CPU_SUP_INTEL
 -      depends on BLK_DEV_INITRD
        select FW_LOADER
        ---help---
 -
          If you say Y here, you will be able to update the microcode on
 -        certain Intel and AMD processors. The Intel support is for the
 -        IA32 family, e.g. Pentium Pro, Pentium II, Pentium III, Pentium 4,
 -        Xeon etc. The AMD support is for families 0x10 and later. You will
 -        obviously need the actual microcode binary data itself which is not
 -        shipped with the Linux kernel.
 -
 -        This option selects the general module only, you need to select
 -        at least one vendor specific module as well.
 -
 -        To compile this driver as a module, choose M here: the module
 -        will be called microcode.
 +        Intel and AMD processors. The Intel support is for the IA32 family,
 +        e.g. Pentium Pro, Pentium II, Pentium III, Pentium 4, Xeon etc. The
 +        AMD support is for families 0x10 and later. You will obviously need
 +        the actual microcode binary data itself which is not shipped with
 +        the Linux kernel.
 +
 +        The preferred method to load microcode from a detached initrd is described
 +        in Documentation/x86/early-microcode.txt. For that you need to enable
 +        CONFIG_BLK_DEV_INITRD in order for the loader to be able to scan the
 +        initrd for microcode blobs.
 +
 +        In addition, you can build-in the microcode into the kernel. For that you
 +        need to enable FIRMWARE_IN_KERNEL and add the vendor-supplied microcode
 +        to the CONFIG_EXTRA_FIRMWARE config option.
  
  config MICROCODE_INTEL
        bool "Intel microcode loading support"
@@@ -2435,8 -2431,6 +2435,6 @@@ config PCI_CNB20LE_QUIR
  
          You should say N unless you know you need this.
  
- source "drivers/pci/pcie/Kconfig"
  source "drivers/pci/Kconfig"
  
  # x86_64 have no ISA slots, but can have ISA-style DMA.
@@@ -2592,8 -2586,6 +2590,6 @@@ config AMD_N
  
  source "drivers/pcmcia/Kconfig"
  
- source "drivers/pci/hotplug/Kconfig"
  config RAPIDIO
        tristate "RapidIO support"
        depends on PCI
diff --combined arch/x86/pci/common.c
@@@ -12,7 -12,6 +12,6 @@@
  #include <linux/dmi.h>
  #include <linux/slab.h>
  
- #include <asm-generic/pci-bridge.h>
  #include <asm/acpi.h>
  #include <asm/segment.h>
  #include <asm/io.h>
@@@ -711,22 -710,28 +710,22 @@@ int pcibios_add_device(struct pci_dev *
        return 0;
  }
  
 -int pcibios_alloc_irq(struct pci_dev *dev)
 +int pcibios_enable_device(struct pci_dev *dev, int mask)
  {
 -      /*
 -       * If the PCI device was already claimed by core code and has
 -       * MSI enabled, probing of the pcibios IRQ will overwrite
 -       * dev->irq.  So bail out if MSI is already enabled.
 -       */
 -      if (pci_dev_msi_enabled(dev))
 -              return -EBUSY;
 +      int err;
  
 -      return pcibios_enable_irq(dev);
 -}
 +      if ((err = pci_enable_resources(dev, mask)) < 0)
 +              return err;
  
 -void pcibios_free_irq(struct pci_dev *dev)
 -{
 -      if (pcibios_disable_irq)
 -              pcibios_disable_irq(dev);
 +      if (!pci_dev_msi_enabled(dev))
 +              return pcibios_enable_irq(dev);
 +      return 0;
  }
  
 -int pcibios_enable_device(struct pci_dev *dev, int mask)
 +void pcibios_disable_device (struct pci_dev *dev)
  {
 -      return pci_enable_resources(dev, mask);
 +      if (!pci_dev_msi_enabled(dev) && pcibios_disable_irq)
 +              pcibios_disable_irq(dev);
  }
  
  int pci_ext_cfg_avail(void)
diff --combined drivers/misc/cxl/pci.c
@@@ -19,7 -19,6 +19,6 @@@
  #include <linux/delay.h>
  #include <asm/opal.h>
  #include <asm/msi_bitmap.h>
- #include <asm/pci-bridge.h> /* for struct pci_controller */
  #include <asm/pnv-pci.h>
  #include <asm/io.h>
  
@@@ -415,7 -414,7 +414,7 @@@ static int cxl_setup_psl_timebase(struc
                delta = mftb() - psl_tb;
                if (delta < 0)
                        delta = -delta;
 -      } while (cputime_to_usecs(delta) > 16);
 +      } while (tb_to_ns(delta) > 16000);
  
        return 0;
  }
diff --combined drivers/pci/host/Kconfig
@@@ -14,9 -14,30 +14,31 @@@ config PCI_DRA7X
  config PCI_MVEBU
        bool "Marvell EBU PCIe controller"
        depends on ARCH_MVEBU || ARCH_DOVE
 +      depends on ARM
        depends on OF
  
+ config PCIE_XILINX_NWL
+       bool "NWL PCIe Core"
+       depends on ARCH_ZYNQMP
+       select PCI_MSI_IRQ_DOMAIN if PCI_MSI
+       help
+        Say 'Y' here if you want kernel support for Xilinx
+        NWL PCIe controller. The controller can act as Root Port
+        or End Point. The current option selection will only
+        support root port enabling.
+ config PCIE_DW_PLAT
+       bool "Platform bus based DesignWare PCIe Controller"
+       select PCIE_DW
+       ---help---
+        This selects the DesignWare PCIe controller support. Select this if
+        you have a PCIe controller on Platform bus.
+        If you have a controller with this interface, say Y or M here.
+        If unsure, say N.
  config PCIE_DW
        bool
  
@@@ -42,7 -63,7 +64,7 @@@ config PCI_TEGR
  config PCI_RCAR_GEN2
        bool "Renesas R-Car Gen2 Internal PCI controller"
        depends on ARM
-       depends on ARCH_SHMOBILE || COMPILE_TEST
+       depends on ARCH_RENESAS || COMPILE_TEST
        help
          Say Y here if you want internal PCI support on R-Car Gen2 SoC.
          There are 3 internal PCI controllers available with a single
  
  config PCI_RCAR_GEN2_PCIE
        bool "Renesas R-Car PCIe controller"
-       depends on ARCH_SHMOBILE || (ARM && COMPILE_TEST)
+       depends on ARCH_RENESAS || (ARM && COMPILE_TEST)
        help
          Say Y here if you want PCIe controller support on R-Car Gen2 SoCs.
  
+ config PCI_HOST_COMMON
+       bool
  config PCI_HOST_GENERIC
        bool "Generic PCI host controller"
        depends on (ARM || ARM64) && OF
+       select PCI_HOST_COMMON
        help
          Say Y here if you want to support a simple generic PCI host
          controller, such as the one emulated by kvmtool.
@@@ -82,7 -107,7 +108,7 @@@ config PCI_KEYSTON
  
  config PCIE_XILINX
        bool "Xilinx AXI PCIe host bridge support"
-       depends on ARCH_ZYNQ
+       depends on ARCH_ZYNQ || MICROBLAZE
        help
          Say 'Y' here if you want kernel to support the Xilinx AXI PCIe
          Host Bridge driver.
@@@ -192,4 -217,18 +218,18 @@@ config PCIE_QCO
          PCIe controller uses the Designware core plus Qualcomm-specific
          hardware wrappers.
  
+ config PCI_HOST_THUNDER_PEM
+       bool "Cavium Thunder PCIe controller to off-chip devices"
+       depends on OF && ARM64
+       select PCI_HOST_COMMON
+       help
+         Say Y here if you want PCIe support for CN88XX Cavium Thunder SoCs.
+ config PCI_HOST_THUNDER_ECAM
+       bool "Cavium Thunder ECAM controller to on-chip devices on pass-1.x silicon"
+       depends on OF && ARM64
+       select PCI_HOST_COMMON
+       help
+         Say Y here if you want ECAM support for CN88XX-Pass-1.x Cavium Thunder SoCs.
  endmenu
@@@ -77,16 -77,6 +77,16 @@@ static void ls_pcie_fix_class(struct ls
        iowrite16(PCI_CLASS_BRIDGE_PCI, pcie->dbi + PCI_CLASS_DEVICE);
  }
  
 +/* Drop MSG TLP except for Vendor MSG */
 +static void ls_pcie_drop_msg_tlp(struct ls_pcie *pcie)
 +{
 +      u32 val;
 +
 +      val = ioread32(pcie->dbi + PCIE_STRFMR1);
 +      val &= 0xDFFFFFFF;
 +      iowrite32(val, pcie->dbi + PCIE_STRFMR1);
 +}
 +
  static int ls1021_pcie_link_up(struct pcie_port *pp)
  {
        u32 state;
  static void ls1021_pcie_host_init(struct pcie_port *pp)
  {
        struct ls_pcie *pcie = to_ls_pcie(pp);
 -      u32 val, index[2];
 +      u32 index[2];
  
        pcie->scfg = syscon_regmap_lookup_by_phandle(pp->dev->of_node,
                                                     "fsl,pcie-scfg");
  
        dw_pcie_setup_rc(pp);
  
 -      /*
 -       * LS1021A Workaround for internal TKT228622
 -       * to fix the INTx hang issue
 -       */
 -      val = ioread32(pcie->dbi + PCIE_STRFMR1);
 -      val &= 0xffff;
 -      iowrite32(val, pcie->dbi + PCIE_STRFMR1);
 +      ls_pcie_drop_msg_tlp(pcie);
  }
  
  static int ls_pcie_link_up(struct pcie_port *pp)
@@@ -151,7 -147,6 +151,7 @@@ static void ls_pcie_host_init(struct pc
        iowrite32(1, pcie->dbi + PCIE_DBI_RO_WR_EN);
        ls_pcie_fix_class(pcie);
        ls_pcie_clear_multifunction(pcie);
 +      ls_pcie_drop_msg_tlp(pcie);
        iowrite32(0, pcie->dbi + PCIE_DBI_RO_WR_EN);
  }
  
@@@ -208,6 -203,7 +208,7 @@@ static const struct of_device_id ls_pci
        { .compatible = "fsl,ls1021a-pcie", .data = &ls1021_drvdata },
        { .compatible = "fsl,ls1043a-pcie", .data = &ls1043_drvdata },
        { .compatible = "fsl,ls2080a-pcie", .data = &ls2080_drvdata },
+       { .compatible = "fsl,ls2085a-pcie", .data = &ls2080_drvdata },
        { },
  };
  MODULE_DEVICE_TABLE(of, ls_pcie_of_match);
diff --combined drivers/pci/pci.c
@@@ -25,7 -25,6 +25,6 @@@
  #include <linux/device.h>
  #include <linux/pm_runtime.h>
  #include <linux/pci_hotplug.h>
- #include <asm-generic/pci-bridge.h>
  #include <asm/setup.h>
  #include <linux/aer.h>
  #include "pci.h"
@@@ -3386,18 -3385,6 +3385,6 @@@ bool pci_check_and_unmask_intx(struct p
  }
  EXPORT_SYMBOL_GPL(pci_check_and_unmask_intx);
  
- int pci_set_dma_max_seg_size(struct pci_dev *dev, unsigned int size)
- {
-       return dma_set_max_seg_size(&dev->dev, size);
- }
- EXPORT_SYMBOL(pci_set_dma_max_seg_size);
- int pci_set_dma_seg_boundary(struct pci_dev *dev, unsigned long mask)
- {
-       return dma_set_seg_boundary(&dev->dev, mask);
- }
- EXPORT_SYMBOL(pci_set_dma_seg_boundary);
  /**
   * pci_wait_for_pending_transaction - waits for pending transaction
   * @dev: the PCI device to operate on
@@@ -3414,6 -3401,29 +3401,29 @@@ int pci_wait_for_pending_transaction(st
  }
  EXPORT_SYMBOL(pci_wait_for_pending_transaction);
  
+ /*
+  * We should only need to wait 100ms after FLR, but some devices take longer.
+  * Wait for up to 1000ms for config space to return something other than -1.
+  * Intel IGD requires this when an LCD panel is attached.  We read the 2nd
+  * dword because VFs don't implement the 1st dword.
+  */
+ static void pci_flr_wait(struct pci_dev *dev)
+ {
+       int i = 0;
+       u32 id;
+       do {
+               msleep(100);
+               pci_read_config_dword(dev, PCI_COMMAND, &id);
+       } while (i++ < 10 && id == ~0);
+       if (id == ~0)
+               dev_warn(&dev->dev, "Failed to return from FLR\n");
+       else if (i > 1)
+               dev_info(&dev->dev, "Required additional %dms to return from FLR\n",
+                        (i - 1) * 100);
+ }
  static int pcie_flr(struct pci_dev *dev, int probe)
  {
        u32 cap;
                dev_err(&dev->dev, "timed out waiting for pending transaction; performing function level reset anyway\n");
  
        pcie_capability_set_word(dev, PCI_EXP_DEVCTL, PCI_EXP_DEVCTL_BCR_FLR);
-       msleep(100);
+       pci_flr_wait(dev);
        return 0;
  }
  
@@@ -3459,7 -3469,7 +3469,7 @@@ static int pci_af_flr(struct pci_dev *d
                dev_err(&dev->dev, "timed out waiting for pending transaction; performing AF function level reset anyway\n");
  
        pci_write_config_byte(dev, pos + PCI_AF_CTRL, PCI_AF_CTRL_FLR);
-       msleep(100);
+       pci_flr_wait(dev);
        return 0;
  }
  
@@@ -4772,10 -4782,8 +4782,10 @@@ int pci_get_new_domain_nr(void
  void pci_bus_assign_domain_nr(struct pci_bus *bus, struct device *parent)
  {
        static int use_dt_domains = -1;
 -      int domain = of_get_pci_domain_nr(parent->of_node);
 +      int domain = -1;
  
 +      if (parent)
 +              domain = of_get_pci_domain_nr(parent->of_node);
        /*
         * Check DT domain and use_dt_domains values.
         *
@@@ -467,7 -467,7 +467,7 @@@ static const struct dev_pm_ops virtio_p
  
  /* Qumranet donated their vendor ID for devices 0x1000 thru 0x10FF. */
  static const struct pci_device_id virtio_pci_id_table[] = {
-       { PCI_DEVICE(0x1af4, PCI_ANY_ID) },
+       { PCI_DEVICE(PCI_VENDOR_ID_REDHAT_QUMRANET, PCI_ANY_ID) },
        { 0 }
  };
  
@@@ -545,7 -545,6 +545,7 @@@ err_enable_device
  static void virtio_pci_remove(struct pci_dev *pci_dev)
  {
        struct virtio_pci_device *vp_dev = pci_get_drvdata(pci_dev);
 +      struct device *dev = get_device(&vp_dev->vdev.dev);
  
        unregister_virtio_device(&vp_dev->vdev);
  
                virtio_pci_modern_remove(vp_dev);
  
        pci_disable_device(pci_dev);
 +      put_device(dev);
  }
  
  static struct pci_driver virtio_pci_driver = {
diff --combined include/linux/ioport.h
@@@ -20,7 -20,6 +20,7 @@@ struct resource 
        resource_size_t end;
        const char *name;
        unsigned long flags;
 +      unsigned long desc;
        struct resource *parent, *sibling, *child;
  };
  
  #define IORESOURCE_WINDOW     0x00200000      /* forwarded by bridge */
  #define IORESOURCE_MUXED      0x00400000      /* Resource is software muxed */
  
 +#define IORESOURCE_EXT_TYPE_BITS 0x01000000   /* Resource extended types */
 +#define IORESOURCE_SYSRAM     0x01000000      /* System RAM (modifier) */
 +
  #define IORESOURCE_EXCLUSIVE  0x08000000      /* Userland may not map this resource */
 +
  #define IORESOURCE_DISABLED   0x10000000
  #define IORESOURCE_UNSET      0x20000000      /* No address assigned yet */
  #define IORESOURCE_AUTO               0x40000000
  #define IORESOURCE_BUSY               0x80000000      /* Driver has marked this resource busy */
  
 +/* I/O resource extended types */
 +#define IORESOURCE_SYSTEM_RAM         (IORESOURCE_MEM|IORESOURCE_SYSRAM)
 +
  /* PnP IRQ specific bits (IORESOURCE_BITS) */
  #define IORESOURCE_IRQ_HIGHEDGE               (1<<0)
  #define IORESOURCE_IRQ_LOWEDGE                (1<<1)
  
  /* PCI ROM control bits (IORESOURCE_BITS) */
  #define IORESOURCE_ROM_ENABLE         (1<<0)  /* ROM is enabled, same as PCI_ROM_ADDRESS_ENABLE */
- #define IORESOURCE_ROM_SHADOW         (1<<1)  /* ROM is copy at C000:0 */
- #define IORESOURCE_ROM_COPY           (1<<2)  /* ROM is alloc'd copy, resource field overlaid */
- #define IORESOURCE_ROM_BIOS_COPY      (1<<3)  /* ROM is BIOS copy, resource field overlaid */
+ #define IORESOURCE_ROM_SHADOW         (1<<1)  /* Use RAM image, not ROM BAR */
  
  /* PCI control bits.  Shares IORESOURCE_BITS with above PCI ROM.  */
  #define IORESOURCE_PCI_FIXED          (1<<4)  /* Do not move resource */
  
 +/*
 + * I/O Resource Descriptors
 + *
 + * Descriptors are used by walk_iomem_res_desc() and region_intersects()
 + * for searching a specific resource range in the iomem table.  Assign
 + * a new descriptor when a resource range supports the search interfaces.
 + * Otherwise, resource.desc must be set to IORES_DESC_NONE (0).
 + */
 +enum {
 +      IORES_DESC_NONE                         = 0,
 +      IORES_DESC_CRASH_KERNEL                 = 1,
 +      IORES_DESC_ACPI_TABLES                  = 2,
 +      IORES_DESC_ACPI_NV_STORAGE              = 3,
 +      IORES_DESC_PERSISTENT_MEMORY            = 4,
 +      IORES_DESC_PERSISTENT_MEMORY_LEGACY     = 5,
 +};
  
  /* helpers to define resources */
  #define DEFINE_RES_NAMED(_start, _size, _name, _flags)                        \
                .end = (_start) + (_size) - 1,                          \
                .name = (_name),                                        \
                .flags = (_flags),                                      \
 +              .desc = IORES_DESC_NONE,                                \
        }
  
  #define DEFINE_RES_IO_NAMED(_start, _size, _name)                     \
@@@ -195,10 -168,6 +193,10 @@@ static inline unsigned long resource_ty
  {
        return res->flags & IORESOURCE_TYPE_BITS;
  }
 +static inline unsigned long resource_ext_type(const struct resource *res)
 +{
 +      return res->flags & IORESOURCE_EXT_TYPE_BITS;
 +}
  /* True iff r1 completely contains r2 */
  static inline bool resource_contains(struct resource *r1, struct resource *r2)
  {
@@@ -268,8 -237,8 +266,8 @@@ extern in
  walk_system_ram_res(u64 start, u64 end, void *arg,
                    int (*func)(u64, u64, void *));
  extern int
 -walk_iomem_res(char *name, unsigned long flags, u64 start, u64 end, void *arg,
 -             int (*func)(u64, u64, void *));
 +walk_iomem_res_desc(unsigned long desc, unsigned long flags, u64 start, u64 end,
 +                  void *arg, int (*func)(u64, u64, void *));
  
  /* True if any part of r1 overlaps r2 */
  static inline bool resource_overlaps(struct resource *r1, struct resource *r2)
diff --combined include/linux/pci.h
@@@ -70,12 -70,6 +70,6 @@@ enum pci_mmap_state 
        pci_mmap_mem
  };
  
- /* This defines the direction arg to the DMA mapping routines. */
- #define PCI_DMA_BIDIRECTIONAL 0
- #define PCI_DMA_TODEVICE      1
- #define PCI_DMA_FROMDEVICE    2
- #define PCI_DMA_NONE          3
  /*
   *  For PCI devices, the region numbers are assigned this way:
   */
@@@ -359,6 -353,7 +353,7 @@@ struct pci_dev 
        unsigned int    io_window_1k:1; /* Intel P2P bridge 1K I/O windows */
        unsigned int    irq_managed:1;
        unsigned int    has_secondary_link:1;
+       unsigned int    non_compliant_bars:1;   /* broken BARs; ignore them */
        pci_dev_flags_t dev_flags;
        atomic_t        enable_cnt;     /* pci_enable_device has been called */
  
@@@ -578,6 -573,8 +573,8 @@@ static inline int pcibios_err_to_errno(
  /* Low-level architecture-dependent routines */
  
  struct pci_ops {
+       int (*add_bus)(struct pci_bus *bus);
+       void (*remove_bus)(struct pci_bus *bus);
        void __iomem *(*map_bus)(struct pci_bus *bus, unsigned int devfn, int where);
        int (*read)(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 *val);
        int (*write)(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 val);
@@@ -746,9 -743,26 +743,26 @@@ struct pci_driver 
        .vendor = PCI_VENDOR_ID_##vend, .device = (dev), \
        .subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID, 0, 0
  
+ enum {
+       PCI_REASSIGN_ALL_RSRC   = 0x00000001,   /* ignore firmware setup */
+       PCI_REASSIGN_ALL_BUS    = 0x00000002,   /* reassign all bus numbers */
+       PCI_PROBE_ONLY          = 0x00000004,   /* use existing setup */
+       PCI_CAN_SKIP_ISA_ALIGN  = 0x00000008,   /* don't do ISA alignment */
+       PCI_ENABLE_PROC_DOMAINS = 0x00000010,   /* enable domains in /proc */
+       PCI_COMPAT_DOMAIN_0     = 0x00000020,   /* ... except domain 0 */
+       PCI_SCAN_ALL_PCIE_DEVS  = 0x00000040,   /* scan all, not just dev 0 */
+ };
  /* these external functions are only available when PCI support is enabled */
  #ifdef CONFIG_PCI
  
+ extern unsigned int pci_flags;
+ static inline void pci_set_flags(int flags) { pci_flags = flags; }
+ static inline void pci_add_flags(int flags) { pci_flags |= flags; }
+ static inline void pci_clear_flags(int flags) { pci_flags &= ~flags; }
+ static inline int pci_has_flag(int flag) { return pci_flags & flag; }
  void pcie_bus_configure_settings(struct pci_bus *bus);
  
  enum pcie_bus_config_types {
@@@ -988,6 -1002,23 +1002,6 @@@ static inline int pci_is_managed(struc
        return pdev->is_managed;
  }
  
 -static inline void pci_set_managed_irq(struct pci_dev *pdev, unsigned int irq)
 -{
 -      pdev->irq = irq;
 -      pdev->irq_managed = 1;
 -}
 -
 -static inline void pci_reset_managed_irq(struct pci_dev *pdev)
 -{
 -      pdev->irq = 0;
 -      pdev->irq_managed = 0;
 -}
 -
 -static inline bool pci_has_managed_irq(struct pci_dev *pdev)
 -{
 -      return pdev->irq_managed && pdev->irq > 0;
 -}
 -
  void pci_disable_device(struct pci_dev *dev);
  
  extern unsigned int pcibios_max_latency;
@@@ -1004,8 -1035,6 +1018,6 @@@ void pci_intx(struct pci_dev *dev, int 
  bool pci_intx_mask_supported(struct pci_dev *dev);
  bool pci_check_and_mask_intx(struct pci_dev *dev);
  bool pci_check_and_unmask_intx(struct pci_dev *dev);
- int pci_set_dma_max_seg_size(struct pci_dev *dev, unsigned int size);
- int pci_set_dma_seg_boundary(struct pci_dev *dev, unsigned long mask);
  int pci_wait_for_pending(struct pci_dev *dev, int pos, u16 mask);
  int pci_wait_for_pending_transaction(struct pci_dev *dev);
  int pcix_get_max_mmrbc(struct pci_dev *dev);
@@@ -1221,6 -1250,7 +1233,7 @@@ resource_size_t pcibios_iov_resource_al
  
  int pci_set_vga_state(struct pci_dev *pdev, bool decode,
                      unsigned int command_bits, u32 flags);
  /* kmem_cache style wrapper around pci_alloc_consistent() */
  
  #include <linux/pci-dma.h>
@@@ -1388,6 -1418,11 +1401,11 @@@ void pci_register_set_vga_state(arch_se
  
  #else /* CONFIG_PCI is not enabled */
  
+ static inline void pci_set_flags(int flags) { }
+ static inline void pci_add_flags(int flags) { }
+ static inline void pci_clear_flags(int flags) { }
+ static inline int pci_has_flag(int flag) { return 0; }
  /*
   *  If the system does not have PCI, clearly these return errors.  Define
   *  these as simple inline functions to avoid hair in drivers.
@@@ -1427,16 -1462,6 +1445,6 @@@ static inline struct pci_dev *pci_get_c
  static inline void pci_set_master(struct pci_dev *dev) { }
  static inline int pci_enable_device(struct pci_dev *dev) { return -EIO; }
  static inline void pci_disable_device(struct pci_dev *dev) { }
- static inline int pci_set_dma_mask(struct pci_dev *dev, u64 mask)
- { return -EIO; }
- static inline int pci_set_consistent_dma_mask(struct pci_dev *dev, u64 mask)
- { return -EIO; }
- static inline int pci_set_dma_max_seg_size(struct pci_dev *dev,
-                                       unsigned int size)
- { return -EIO; }
- static inline int pci_set_dma_seg_boundary(struct pci_dev *dev,
-                                       unsigned long mask)
- { return -EIO; }
  static inline int pci_assign_resource(struct pci_dev *dev, int i)
  { return -EBUSY; }
  static inline int __pci_register_driver(struct pci_driver *drv,
@@@ -1498,6 -1523,10 +1506,10 @@@ static inline int pci_get_new_domain_nr
  
  #include <asm/pci.h>
  
+ #ifndef pci_root_bus_fwnode
+ #define pci_root_bus_fwnode(bus)      NULL
+ #endif
  /* these helpers provide future and backwards compatibility
   * for accessing popular PCI BAR info */
  #define pci_resource_start(dev, bar)  ((dev)->resource[(bar)].start)
@@@ -1817,12 -1846,13 +1829,13 @@@ bool pci_acs_path_enabled(struct pci_de
  #define PCI_VPD_LRDT_RW_DATA          PCI_VPD_LRDT_ID(PCI_VPD_LTIN_RW_DATA)
  
  /* Small Resource Data Type Tag Item Names */
- #define PCI_VPD_STIN_END              0x78    /* End */
+ #define PCI_VPD_STIN_END              0x0f    /* End */
  
- #define PCI_VPD_SRDT_END              PCI_VPD_STIN_END
+ #define PCI_VPD_SRDT_END              (PCI_VPD_STIN_END << 3)
  
  #define PCI_VPD_SRDT_TIN_MASK         0x78
  #define PCI_VPD_SRDT_LEN_MASK         0x07
+ #define PCI_VPD_LRDT_TIN_MASK         0x7f
  
  #define PCI_VPD_LRDT_TAG_SIZE         3
  #define PCI_VPD_SRDT_TAG_SIZE         1
@@@ -1845,6 -1875,17 +1858,17 @@@ static inline u16 pci_vpd_lrdt_size(con
        return (u16)lrdt[1] + ((u16)lrdt[2] << 8);
  }
  
+ /**
+  * pci_vpd_lrdt_tag - Extracts the Large Resource Data Type Tag Item
+  * @lrdt: Pointer to the beginning of the Large Resource Data Type tag
+  *
+  * Returns the extracted Large Resource Data Type Tag item.
+  */
+ static inline u16 pci_vpd_lrdt_tag(const u8 *lrdt)
+ {
+     return (u16)(lrdt[0] & PCI_VPD_LRDT_TIN_MASK);
+ }
  /**
   * pci_vpd_srdt_size - Extracts the Small Resource Data Type length
   * @lrdt: Pointer to the beginning of the Small Resource Data Type tag
@@@ -1856,6 -1897,17 +1880,17 @@@ static inline u8 pci_vpd_srdt_size(cons
        return (*srdt) & PCI_VPD_SRDT_LEN_MASK;
  }
  
+ /**
+  * pci_vpd_srdt_tag - Extracts the Small Resource Data Type Tag Item
+  * @lrdt: Pointer to the beginning of the Small Resource Data Type tag
+  *
+  * Returns the extracted Small Resource Data Type Tag Item.
+  */
+ static inline u8 pci_vpd_srdt_tag(const u8 *srdt)
+ {
+       return ((*srdt) & PCI_VPD_SRDT_TIN_MASK) >> 3;
+ }
  /**
   * pci_vpd_info_field_size - Extracts the information field length
   * @lrdt: Pointer to the beginning of an information field header
@@@ -1972,4 -2024,8 +2007,8 @@@ static inline bool pci_ari_enabled(stru
  {
        return bus->self && bus->self->ari_enabled;
  }
+ /* provide the legacy pci_dma_* API */
+ #include <linux/pci-dma-compat.h>
  #endif /* LINUX_PCI_H */