Skip to content

Commit 7d6e64c

Browse files
Mani-Sadhasivamkwilczynski
authored andcommitted
PCI: dwc: ep: Rename dw_pcie_ep_init_complete() to dw_pcie_ep_init_registers()
The goal of the dw_pcie_ep_init_complete() API is to initialize the DWC specific registers post registering the controller with the EP framework. But the naming doesn't reflect its functionality and causes confusion. So, let's rename it to dw_pcie_ep_init_registers() to make it clear that it initializes the DWC specific registers. Link: https://lore.kernel.org/linux-pci/[email protected] Signed-off-by: Manivannan Sadhasivam <[email protected]> Signed-off-by: Krzysztof Wilczyński <[email protected]> Reviewed-by: Frank Li <[email protected]> Reviewed-by: Niklas Cassel <[email protected]>
1 parent 570d771 commit 7d6e64c

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed

drivers/pci/controller/dwc/pcie-designware-ep.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -674,14 +674,14 @@ static unsigned int dw_pcie_ep_find_ext_capability(struct dw_pcie *pci, int cap)
674674
}
675675

676676
/**
677-
* dw_pcie_ep_init_complete - Complete DWC EP initialization
677+
* dw_pcie_ep_init_registers - Initialize DWC EP specific registers
678678
* @ep: DWC EP device
679679
*
680-
* Complete the initialization of the registers (CSRs) specific to DWC EP. This
681-
* API should be called only when the endpoint receives an active refclk (either
682-
* from host or generated locally).
680+
* Initialize the registers (CSRs) specific to DWC EP. This API should be called
681+
* only when the endpoint receives an active refclk (either from host or
682+
* generated locally).
683683
*/
684-
int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep)
684+
int dw_pcie_ep_init_registers(struct dw_pcie_ep *ep)
685685
{
686686
struct dw_pcie *pci = to_dw_pcie_from_ep(ep);
687687
struct dw_pcie_ep_func *ep_func;
@@ -801,7 +801,7 @@ int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep)
801801

802802
return ret;
803803
}
804-
EXPORT_SYMBOL_GPL(dw_pcie_ep_init_complete);
804+
EXPORT_SYMBOL_GPL(dw_pcie_ep_init_registers);
805805

806806
/**
807807
* dw_pcie_ep_init - Initialize the endpoint device
@@ -880,7 +880,7 @@ int dw_pcie_ep_init(struct dw_pcie_ep *ep)
880880
* (Ex: tegra194). Any hardware access on such platforms result
881881
* in system hang.
882882
*/
883-
ret = dw_pcie_ep_init_complete(ep);
883+
ret = dw_pcie_ep_init_registers(ep);
884884
if (ret)
885885
goto err_free_epc_mem;
886886

drivers/pci/controller/dwc/pcie-designware.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -669,7 +669,7 @@ static inline void __iomem *dw_pcie_own_conf_map_bus(struct pci_bus *bus,
669669
#ifdef CONFIG_PCIE_DW_EP
670670
void dw_pcie_ep_linkup(struct dw_pcie_ep *ep);
671671
int dw_pcie_ep_init(struct dw_pcie_ep *ep);
672-
int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep);
672+
int dw_pcie_ep_init_registers(struct dw_pcie_ep *ep);
673673
void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep);
674674
void dw_pcie_ep_deinit(struct dw_pcie_ep *ep);
675675
void dw_pcie_ep_cleanup(struct dw_pcie_ep *ep);
@@ -693,7 +693,7 @@ static inline int dw_pcie_ep_init(struct dw_pcie_ep *ep)
693693
return 0;
694694
}
695695

696-
static inline int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep)
696+
static inline int dw_pcie_ep_init_registers(struct dw_pcie_ep *ep)
697697
{
698698
return 0;
699699
}

drivers/pci/controller/dwc/pcie-qcom-ep.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,7 @@ static int qcom_pcie_perst_deassert(struct dw_pcie *pci)
463463
PARF_INT_ALL_LINK_UP | PARF_INT_ALL_EDMA;
464464
writel_relaxed(val, pcie_ep->parf + PARF_INT_ALL_MASK);
465465

466-
ret = dw_pcie_ep_init_complete(&pcie_ep->pci.ep);
466+
ret = dw_pcie_ep_init_registers(&pcie_ep->pci.ep);
467467
if (ret) {
468468
dev_err(dev, "Failed to complete initialization: %d\n", ret);
469469
goto err_disable_resources;

drivers/pci/controller/dwc/pcie-tegra194.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1897,7 +1897,7 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
18971897
val = (upper_32_bits(ep->msi_mem_phys) & MSIX_ADDR_MATCH_HIGH_OFF_MASK);
18981898
dw_pcie_writel_dbi(pci, MSIX_ADDR_MATCH_HIGH_OFF, val);
18991899

1900-
ret = dw_pcie_ep_init_complete(ep);
1900+
ret = dw_pcie_ep_init_registers(ep);
19011901
if (ret) {
19021902
dev_err(dev, "Failed to complete initialization: %d\n", ret);
19031903
goto fail_init_complete;

0 commit comments

Comments
 (0)