Skip to content
Permalink
Krzysztof-Ha-a…
Switch branches/tags

Commits on Aug 16, 2021

  1. PCIe: limit Max Read Request Size on i.MX to 512 bytes

    DWC PCIe controller imposes limits on the Read Request Size that it can
    handle. For i.MX6 family it's fixed at 512 bytes by default.
    
    If a memory read larger than the limit is requested, the CPU responds
    with Completer Abort (CA) (on i.MX6 Unsupported Request (UR) is returned
    instead due to a design error).
    
    The i.MX6 documentation states that the limit can be changed by writing
    to the PCIE_PL_MRCCR0 register, however there is a fixed (and
    undocumented) maximum (CX_REMOTE_RD_REQ_SIZE constant). Tests indicate
    that values larger than 512 bytes don't work, though.
    
    This patch makes the RTL8111 work on i.MX6.
    
    Signed-off-by: Krzysztof Hałasa <khalasa@piap.pl>
    Krzysztof Hałasa authored and intel-lab-lkp committed Aug 16, 2021

Commits on Aug 10, 2021

  1. Merge branch 'remotes/lorenzo/pci/tools'

    - Zero-initialize pcitest param to avoid random "-d" setting (Shunyong
      Yang)
    
    * remotes/lorenzo/pci/tools:
      tools: PCI: Zero-initialize param
    bjorn-helgaas committed Aug 10, 2021
  2. Merge branch 'remotes/lorenzo/pci/misc'

    - Make ixp4xx driver depend on ARCH_IXP4XX (Geert Uytterhoeven)
    
    * remotes/lorenzo/pci/misc:
      PCI: controller: PCI_IXP4XX should depend on ARCH_IXP4XX
    bjorn-helgaas committed Aug 10, 2021
  3. Merge branch 'remotes/lorenzo/pci/xgene'

    - Remove redundant dev_err() after devm_ioremap_resource() (ErKun Yang)
    
    * remotes/lorenzo/pci/xgene:
      PCI: xgene-msi: Remove redundant dev_err() call in xgene_msi_probe()
    bjorn-helgaas committed Aug 10, 2021
  4. Merge branch 'remotes/lorenzo/pci/tegra194'

    - Fix handling BME_CHGED event (Om Prakash Singh)
    
    - Fix MSI-X programming (Om Prakash Singh)
    
    - Disable interrupts before entering L2 (Om Prakash Singh)
    
    - Don't allow suspend when Tegra PCIe is in EP mode (Om Prakash Singh)
    
    * remotes/lorenzo/pci/tegra194:
      PCI: tegra194: Cleanup unused code
      PCI: tegra194: Don't allow suspend when Tegra PCIe is in EP mode
      PCI: tegra194: Disable interrupts before entering L2
      PCI: tegra194: Fix MSI-X programming
      PCI: tegra194: Fix handling BME_CHGED event
    bjorn-helgaas committed Aug 10, 2021
  5. Merge branch 'remotes/lorenzo/pci/tegra'

    - Remove unused struct tegra_pcie_bus (Krzysztof Wilczyński)
    
    * remotes/lorenzo/pci/tegra:
      PCI: tegra: make const array err_msg static
      PCI: tegra: Use 'seq_puts' instead of 'seq_printf'
      PCI: tegra: Fix OF node reference leak
      PCI: tegra: Remove unused struct tegra_pcie_bus
    bjorn-helgaas committed Aug 10, 2021
  6. Merge branch 'remotes/lorenzo/pci/rcar'

    - Fix runtime PM imbalance in rcar_pcie_ep_probe() (Dinghao Liu)
    
    * remotes/lorenzo/pci/rcar:
      PCI: rcar: Fix runtime PM imbalance in rcar_pcie_ep_probe()
    bjorn-helgaas committed Aug 10, 2021
  7. Merge branch 'remotes/lorenzo/pci/mediatek'

    - Split DT bindings for PCIe controllers with independent MSI domains into
      separate nodes for MT2712/MT7622 (Chuanjia Liu)
    
    - Locate shared registers from "mediatek,generic-pciecfg" property, pay
      attention to ""linux,pci-domain" property,  use "interrupt-names" and
      "pcie_irq" to fix MSI issue (Chuanjia Liu)
    
    * remotes/lorenzo/pci/mediatek:
      PCI: mediatek: Add new method to get shared pcie-cfg base address and parse node
      dt-bindings: PCI: mediatek: Update the Device tree bindings
    bjorn-helgaas committed Aug 10, 2021
  8. Merge branch 'remotes/lorenzo/pci/iproc'

    - Don't fail devm_pci_alloc_host_bridge() on missing 'ranges' (Rob Herring)
    
    - Fix BCMA probe resource handling (Rob Herring)
    
    * remotes/lorenzo/pci/iproc:
      PCI: iproc: Fix BCMA probe resource handling
      PCI: of: Don't fail devm_pci_alloc_host_bridge() on missing 'ranges'
    bjorn-helgaas committed Aug 10, 2021
  9. Merge branch 'remotes/lorenzo/pci/dwc'

    - Remove surplus break statements (Krzysztof Wilczyński)
    
    - Add Rockchip RK356X host controller driver (Simon Xue)
    
    * remotes/lorenzo/pci/dwc:
      PCI: rockchip-dwc: Add Rockchip RK356X host controller driver
      PCI: dwc: Remove surplus break statement after return
      PCI: artpec6: Remove local code block from within switch statement
      PCI: artpec6: Remove surplus break statement after return
    bjorn-helgaas committed Aug 10, 2021
  10. Merge branch 'remotes/lorenzo/pci/aardvark'

    - Fix PIO config access status checking (Evan Wang)
    
    - Increase config access polling delay to 1.5s (Pali Rohár)
    
    - Add PCIe Root Capabilities to bridge emulation (Pali Rohár)
    
    - Report Config Request Retry Status when Software Visibility enabled (Pali
      Rohár)
    
    * remotes/lorenzo/pci/aardvark:
      PCI: aardvark: Fix reporting CRS value
      PCI: pci-bridge-emul: Add PCIe Root Capabilities Register
      PCI: aardvark: Increase polling delay to 1.5s while waiting for PIO response
      PCI: aardvark: Fix checking for PIO status
    bjorn-helgaas committed Aug 10, 2021
  11. Merge branch 'pci/vpd'

    - Check Resource Item Names against those defined for type (Bjorn Helgaas)
    
    - Treat initial 0xff as missing EEPROM (Heiner Kallweit)
    
    - Reject resource tags with invalid size (Bjorn Helgaas)
    
    - Don't check Large Resource Item Names for validity (Bjorn Helgaas)
    
    - Allow access to valid parts of VPD if some is invalid (Bjorn Helgaas)
    
    - Remove pci_vpd_size() old_size argument (Heiner Kallweit)
    
    - Make pci_vpd_wait() uninterruptible (Heiner Kallweit)
    
    - Remove struct pci_vpd.flag (Heiner Kallweit)
    
    * pci/vpd:
      PCI/VPD: Remove struct pci_vpd.flag
      PCI/VPD: Make pci_vpd_wait() uninterruptible
      PCI/VPD: Remove pci_vpd_size() old_size argument
      PCI/VPD: Allow access to valid parts of VPD if some is invalid
      PCI/VPD: Don't check Large Resource Item Names for validity
      PCI/VPD: Reject resource tags with invalid size
      PCI/VPD: Treat initial 0xff as missing EEPROM
      PCI/VPD: Check Resource Item Names against those valid for type
      PCI/VPD: Correct diagnostic for VPD read failure
    bjorn-helgaas committed Aug 10, 2021
  12. Merge branch 'pci/virtualization'

    - Add ACS quirks for NXP LX2xx0 and LX2xx2 platforms (Wasim Khan)
    
    - Enforce pci=noats with Transaction Blocking (Alex Williamson)
    
    * pci/virtualization:
      PCI/ACS: Enforce pci=noats with Transaction Blocking
      PCI: Add ACS quirks for NXP LX2xx0 and LX2xx2 platforms
    bjorn-helgaas committed Aug 10, 2021
  13. Merge branch 'pci/resource'

    - Refactor pci_ioremap_bar() and pci_ioremap_wc_bar() (Krzysztof
      Wilczyński)
    
    * pci/resource:
      PCI: Refactor pci_ioremap_bar() and pci_ioremap_wc_bar()
    bjorn-helgaas committed Aug 10, 2021
  14. Merge branch 'pci/irq'

    - Convert irq_find_mapping() + generic_handle_irq() to
      generic_handle_domain_irq() (Marc Zyngier)
    
    * pci/irq:
      PCI: Bulk conversion to generic_handle_domain_irq()
    bjorn-helgaas committed Aug 10, 2021
  15. Merge branch 'pci/enumeration'

    - Call Max Payload Size-related fixup quirks early, so they're considered
      by pci_configure_mps() (Marek Behún)
    
    - Restrict Max Payload Size Supported to work around ASMedia ASM1062 SATA
      erratum (Marek Behún)
    
    - Return ~0 data on pciconfig_read() CAP_SYS_ADMIN failure (Krzysztof
      Wilczyński)
    
    * pci/enumeration:
      PCI: Return int from pciconfig_read() syscall
      PCI: Return ~0 data on pciconfig_read() CAP_SYS_ADMIN failure
      PCI: Restrict ASMedia ASM1062 SATA Max Payload Size Supported
      PCI: Call Max Payload Size-related fixup quirks early
    bjorn-helgaas committed Aug 10, 2021

Commits on Aug 9, 2021

  1. PCI/VPD: Remove struct pci_vpd.flag

    The struct pci_vpd.flag member was used only to communicate between
    pci_vpd_wait() and its callers.  Remove the flag member and pass the value
    directly to pci_vpd_wait() to simplify the code.
    
    [bhelgaas: commit log]
    Link: https://lore.kernel.org/r/e4ef6845-6b23-1646-28a0-d5c5a28347b6@gmail.com
    Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
    Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
    hkallweit authored and bjorn-helgaas committed Aug 9, 2021
  2. PCI/VPD: Make pci_vpd_wait() uninterruptible

    Reading/writing 4 bytes should be fast enough even on a slow bus, therefore
    pci_vpd_wait() doesn't have to be interruptible.  Making it uninterruptible
    allows to simplify the code.
    
    In addition make VPD writes uninterruptible in general.  It's about vital
    data, and allowing writes to be interruptible may leave the VPD in an
    inconsistent state.
    
    Link: https://lore.kernel.org/r/258bf994-bc2a-2907-9181-2c7a562986d5@gmail.com
    Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
    Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
    hkallweit authored and bjorn-helgaas committed Aug 9, 2021
  3. PCI/VPD: Remove pci_vpd_size() old_size argument

    vpd->len is initialized to PCI_VPD_MAX_SIZE, and if a quirk is used to set
    a specific VPD size, then pci_vpd_set_size() sets vpd->valid, resulting in
    pci_vpd_size() not being called. Therefore we can remove the old_size
    argument. Note that we don't have to check off < PCI_VPD_MAX_SIZE because
    that's implicitly done by pci_read_vpd().
    
    Link: https://lore.kernel.org/r/ede36c16-5335-6867-43a1-293641348430@gmail.com
    Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
    Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
    hkallweit authored and bjorn-helgaas committed Aug 9, 2021
  4. PCI/VPD: Allow access to valid parts of VPD if some is invalid

    Previously, if we found any error in the VPD, we returned size 0, which
    prevents access to all of VPD.  But there may be valid resources in VPD
    before the error, and there's no reason to prevent access to those.
    
    "off" covers only VPD resources known to have valid header tags.  In case
    of error, return "off" (which may be zero if we haven't found any valid
    header tags at all).
    
    Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
    Reviewed-by: Hannes Reinecke <hare@suse.de>
    bjorn-helgaas committed Aug 9, 2021
  5. PCI/VPD: Don't check Large Resource Item Names for validity

    VPD consists of a series of Small and Large Resources.  Computing the size
    of VPD requires only the length of each, which is specified in the generic
    tag of each resource.  We only expect to see ID_STRING, RO_DATA, and
    RW_DATA in VPD, but it's not a problem if it contains other resource types
    because all we care about is the size.
    
    Drop the validity checking of Large Resource items.
    
    Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
    Reviewed-by: Hannes Reinecke <hare@suse.de>
    bjorn-helgaas committed Aug 9, 2021
  6. PCI/VPD: Reject resource tags with invalid size

    VPD is limited in size by the 15-bit VPD Address field in the VPD
    Capability.  Each resource tag includes a length that determines the
    overall size of the resource.  Reject any resources that would extend past
    the maximum VPD size.
    
    Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
    Reviewed-by: Hannes Reinecke <hare@suse.de>
    bjorn-helgaas committed Aug 9, 2021
  7. PCI: rockchip-dwc: Add Rockchip RK356X host controller driver

    Add a driver for the DesignWare-based PCIe controller found on
    RK356X. The existing pcie-rockchip-host driver is only used for
    the Rockchip-designed IP found on RK3399.
    
    Link: https://lore.kernel.org/r/20210625065511.1096935-1-xxm@rock-chips.com
    Tested-by: Peter Geis <pgwipeout@gmail.com>
    Signed-off-by: Simon Xue <xxm@rock-chips.com>
    Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
    Reviewed-by: Rob Herring <robh@kernel.org>
    Simon Xue authored and Lorenzo Pieralisi committed Aug 9, 2021

Commits on Aug 6, 2021

  1. PCI: mediatek: Add new method to get shared pcie-cfg base address and…

    … parse node
    
    For the new dts format, add a new method to get
    shared pcie-cfg base address and parse node.
    
    Link: https://lore.kernel.org/r/20210719073456.28666-3-chuanjia.liu@mediatek.com
    Signed-off-by: Chuanjia Liu <chuanjia.liu@mediatek.com>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Acked-by: Ryder Lee <ryder.lee@mediatek.com>
    Chuanjia Liu authored and Lorenzo Pieralisi committed Aug 6, 2021
  2. dt-bindings: PCI: mediatek: Update the Device tree bindings

    There are two independent PCIe controllers in MT2712 and MT7622
    platform. Each of them should contain an independent MSI domain.
    
    In old dts architecture, MSI domain will be inherited from the root
    bridge, and all of the devices will share the same MSI domain.
    Hence that, the PCIe devices will not work properly if the irq number
    which required is more than 32.
    
    Split the PCIe node for MT2712 and MT7622 platform to comply with
    the hardware design and fix MSI issue.
    
    Link: https://lore.kernel.org/r/20210719073456.28666-2-chuanjia.liu@mediatek.com
    Signed-off-by: Chuanjia Liu <chuanjia.liu@mediatek.com>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Acked-by: Ryder Lee <ryder.lee@mediatek.com>
    Chuanjia Liu authored and Lorenzo Pieralisi committed Aug 6, 2021

Commits on Aug 5, 2021

  1. PCI: rcar: Fix runtime PM imbalance in rcar_pcie_ep_probe()

    pm_runtime_get_sync() will increase the runtime PM counter
    even it returns an error. Thus a pairing decrement is needed
    to prevent refcount leak. Fix this by replacing this API with
    pm_runtime_resume_and_get(), which will not change the runtime
    PM counter on error.
    
    Link: https://lore.kernel.org/r/20210408072402.15069-1-dinghao.liu@zju.edu.cn
    Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
    dinghaoliu authored and Lorenzo Pieralisi committed Aug 5, 2021
  2. PCI: xgene-msi: Remove redundant dev_err() call in xgene_msi_probe()

    devm_ioremap_resource() internally calls __devm_ioremap_resource() which
    is where error checking and handling is actually taking place. i
    
    Therefore, the dev_err() call in xgene_msi_probe() is redundant.
    
    Remove it.
    
    Link: https://lore.kernel.org/r/20210408132751.1198171-1-yangerkun@huawei.com
    Reported-by: Hulk Robot <hulkci@huawei.com>
    Signed-off-by: ErKun Yang <yangerkun@huawei.com>
    [lorenzo.pieralisi@arm.com: commit log]
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Krzysztof Wilczyński <kw@linux.com>
    ErKun Yang authored and Lorenzo Pieralisi committed Aug 5, 2021
  3. PCI: tegra: make const array err_msg static

    Don't populate the array err_msg on the stack but instead make it
    static. Makes the object code smaller by 64 bytes.
    
    While at it, add a missing const, as reported by checkpatch.
    
    Compiled with gcc 11.0.1
    
    Before:
    $ size drivers/pci/controller/pci-tegra.o
       text	   data	    bss	    dec	    hex	filename
      25623	   2844	     32	  28499	   6f53	drivers/pci/controller/pci-tegra.o
    
    After:
    $ size drivers/pci/controller/pci-tegra.o
       text	   data	    bss	    dec	    hex	filename
      25559	   2844	     32	  28435	   6f13	drivers/pci/controller/pci-tegra.o
    
    Link: https://lore.kernel.org/r/5f3f35296b944b94546cc7d1e9cc6186484620d8.1620148539.git.christophe.jaillet@wanadoo.fr
    Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Vidya Sagar <vidyas@nvidia.com>
    tititiou36 authored and Lorenzo Pieralisi committed Aug 5, 2021
  4. PCI: tegra: Use 'seq_puts' instead of 'seq_printf'

    As spotted by checkpatch, use 'seq_puts' instead of 'seq_printf' when
    possible.
    It is slightly more efficient.
    
    Link: https://lore.kernel.org/r/7bdedb342b9221169ab085540cf25d1992e8b97a.1620148539.git.christophe.jaillet@wanadoo.fr
    Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Vidya Sagar <vidyas@nvidia.com>
    tititiou36 authored and Lorenzo Pieralisi committed Aug 5, 2021
  5. PCI: tegra: Fix OF node reference leak

    Commit 9e38e69 ("PCI: tegra: Fix OF node reference leak") has fixed
    some node reference leaks in this function but missed some of them.
    
    In fact, having 'port' referenced in the 'rp' structure is not enough to
    prevent the leak, until 'rp' is actually added in the 'pcie->ports' list.
    
    Add the missing 'goto err_node_put' accordingly.
    
    Link: https://lore.kernel.org/r/55b11e9a7fa2987fbc0869d68ae59888954d65e2.1620148539.git.christophe.jaillet@wanadoo.fr
    Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Vidya Sagar <vidyas@nvidia.com>
    tititiou36 authored and Lorenzo Pieralisi committed Aug 5, 2021
  6. tools: PCI: Zero-initialize param

    The values in param may be random if they are not initialized, which
    may cause use_dma flag set even when "-d" option is not provided
    in command line. Initializing all members to 0 to solve this.
    
    Link: https://lore.kernel.org/r/20210714132331.5200-1-yang.shunyong@gmail.com
    Signed-off-by: Shunyong Yang <yang.shunyong@gmail.com>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
    yangshunyong authored and Lorenzo Pieralisi committed Aug 5, 2021
  7. PCI: aardvark: Fix reporting CRS value

    Set CRSVIS flag in emulated root PCI bridge to indicate support for
    Completion Retry Status.
    
    Add check for CRSSVE flag from root PCI brige when issuing Configuration
    Read Request via PIO to correctly returns fabricated CRS value as it is
    required by PCIe spec.
    
    Link: https://lore.kernel.org/r/20210722144041.12661-5-pali@kernel.org
    Fixes: 8a3ebd8 ("PCI: aardvark: Implement emulated root PCI bridge config space")
    Signed-off-by: Pali Rohár <pali@kernel.org>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Cc: stable@vger.kernel.org # e0d9d30 ("PCI: pci-bridge-emul: Fix big-endian support")
    pali authored and Lorenzo Pieralisi committed Aug 5, 2021
  8. PCI: pci-bridge-emul: Add PCIe Root Capabilities Register

    The 16-bit Root Capabilities register is at offset 0x1e in the PCIe
    Capability. Rename current 'rsvd' struct member to 'rootcap'.
    
    Link: https://lore.kernel.org/r/20210722144041.12661-4-pali@kernel.org
    Signed-off-by: Pali Rohár <pali@kernel.org>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Marek Behún <kabel@kernel.org>
    pali authored and Lorenzo Pieralisi committed Aug 5, 2021
  9. PCI: aardvark: Increase polling delay to 1.5s while waiting for PIO r…

    …esponse
    
    Measurements in different conditions showed that aardvark hardware PIO
    response can take up to 1.44s. Increase wait timeout from 1ms to 1.5s to
    ensure that we do not miss responses from hardware. After 1.44s hardware
    returns errors (e.g. Completer abort).
    
    The previous two patches fixed checking for PIO status, so now we can use
    it to also catch errors which are reported by hardware after 1.44s.
    
    After applying this patch, kernel can detect and print PIO errors to dmesg:
    
        [    6.879999] advk-pcie d0070000.pcie: Non-posted PIO Response Status: CA, 0xe00 @ 0x100004
        [    6.896436] advk-pcie d0070000.pcie: Posted PIO Response Status: COMP_ERR, 0x804 @ 0x100004
        [    6.913049] advk-pcie d0070000.pcie: Posted PIO Response Status: COMP_ERR, 0x804 @ 0x100010
        [    6.929663] advk-pcie d0070000.pcie: Non-posted PIO Response Status: CA, 0xe00 @ 0x100010
        [    6.953558] advk-pcie d0070000.pcie: Posted PIO Response Status: COMP_ERR, 0x804 @ 0x100014
        [    6.970170] advk-pcie d0070000.pcie: Non-posted PIO Response Status: CA, 0xe00 @ 0x100014
        [    6.994328] advk-pcie d0070000.pcie: Posted PIO Response Status: COMP_ERR, 0x804 @ 0x100004
    
    Without this patch kernel prints only a generic error to dmesg:
    
        [    5.246847] advk-pcie d0070000.pcie: config read/write timed out
    
    Link: https://lore.kernel.org/r/20210722144041.12661-3-pali@kernel.org
    Signed-off-by: Pali Rohár <pali@kernel.org>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Marek Behún <kabel@kernel.org>
    Cc: stable@vger.kernel.org # 7fbcb5d ("PCI: aardvark: Don't rely on jiffies while holding spinlock")
    pali authored and Lorenzo Pieralisi committed Aug 5, 2021
  10. PCI: aardvark: Fix checking for PIO status

    There is an issue that when PCIe switch is connected to an Armada 3700
    board, there will be lots of warnings about PIO errors when reading the
    config space. According to Aardvark PIO read and write sequence in HW
    specification, the current way to check PIO status has the following
    issues:
    
    1) For PIO read operation, it reports the error message, which should be
       avoided according to HW specification.
    
    2) For PIO read and write operations, it only checks PIO operation complete
       status, which is not enough, and error status should also be checked.
    
    This patch aligns the code with Aardvark PIO read and write sequence in HW
    specification on PIO status check and fix the warnings when reading config
    space.
    
    [pali: Fix CRS handling when CRSSVE is not enabled]
    
    Link: https://lore.kernel.org/r/20210722144041.12661-2-pali@kernel.org
    Tested-by: Victor Gu <xigu@marvell.com>
    Signed-off-by: Evan Wang <xswang@marvell.com>
    Signed-off-by: Pali Rohár <pali@kernel.org>
    Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
    Reviewed-by: Victor Gu <xigu@marvell.com>
    Reviewed-by: Marek Behún <kabel@kernel.org>
    Cc: stable@vger.kernel.org # b1bd571 ("PCI: aardvark: Indicate error in 'val' when config read fails")
    Evan Wang authored and Lorenzo Pieralisi committed Aug 5, 2021
Older