• Bjorn Helgaas's avatar
    PCI: designware: Make config accessor override checking symmetric · 67de2dc3
    Bjorn Helgaas authored
    Drivers based on the DesignWare core can override the config read accessors
    by supplying rd_own_conf() and rd_other_conf() function pointers.
    dw_pcie_rd_conf() calls dw_pcie_rd_own_conf() (for accesses to the root
    bus) or dw_pcie_rd_other_conf():
    
      dw_pcie_rd_conf
        dw_pcie_rd_own_conf                # if on root bus
        dw_pcie_rd_other_conf              # if not on root bus
    
    Previously we checked for rd_other_conf() directly in dw_pcie_rd_conf(),
    but we checked for rd_own_conf() in dw_pcie_rd_own_conf().
    
    Check for rd_other_conf() in dw_pcie_rd_other_conf() to make this symmetric
    with the rd_own_conf() checking, and similarly for the write path.
    
    No functional change intended.
    Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
    Acked-by: default avatarPratyush Anand <pratyush.anand@gmail.com>
    67de2dc3
pcie-designware.c 19.5 KB