mirror of
https://github.com/torvalds/linux.git
synced 2026-05-31 02:24:24 +02:00
PCI: qcom: Drop the assert_perst() callbacks
Previously, the pcie-qcom driver probed first, deasserted PERST#, enabled link training and scanned the bus. By the time the pwrctrl driver probe got called, link training was already enabled by the controller driver. Thus the pwrctrl drivers had to call the .assert_perst() callback, to assert PERST#, power on the needed resources, and then call the .assert_perst() callback to deassert PERST#. Now since all pwrctrl drivers and this controller driver have been converted to the new pwrctrl design where the pwrctrl drivers will first power on the devices before this driver deasserts PERST# and scan the bus. So there is no longer a need for .assert_perst() callback in this driver and in DWC core driver. Hence, drop them. Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@oss.qualcomm.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com> Link: https://patch.msgid.link/20260115-pci-pwrctrl-rework-v5-13-9d26da3ce903@oss.qualcomm.com
This commit is contained in:
parent
b921aa3f8d
commit
5861404625
|
|
@ -857,19 +857,10 @@ static void __iomem *dw_pcie_ecam_conf_map_bus(struct pci_bus *bus, unsigned int
|
|||
return pci->dbi_base + where;
|
||||
}
|
||||
|
||||
static int dw_pcie_op_assert_perst(struct pci_bus *bus, bool assert)
|
||||
{
|
||||
struct dw_pcie_rp *pp = bus->sysdata;
|
||||
struct dw_pcie *pci = to_dw_pcie_from_pp(pp);
|
||||
|
||||
return dw_pcie_assert_perst(pci, assert);
|
||||
}
|
||||
|
||||
static struct pci_ops dw_pcie_ops = {
|
||||
.map_bus = dw_pcie_own_conf_map_bus,
|
||||
.read = pci_generic_config_read,
|
||||
.write = pci_generic_config_write,
|
||||
.assert_perst = dw_pcie_op_assert_perst,
|
||||
};
|
||||
|
||||
static struct pci_ops dw_pcie_ecam_ops = {
|
||||
|
|
|
|||
|
|
@ -493,7 +493,6 @@ struct dw_pcie_ops {
|
|||
enum dw_pcie_ltssm (*get_ltssm)(struct dw_pcie *pcie);
|
||||
int (*start_link)(struct dw_pcie *pcie);
|
||||
void (*stop_link)(struct dw_pcie *pcie);
|
||||
int (*assert_perst)(struct dw_pcie *pcie, bool assert);
|
||||
};
|
||||
|
||||
struct debugfs_info {
|
||||
|
|
@ -798,14 +797,6 @@ static inline void dw_pcie_stop_link(struct dw_pcie *pci)
|
|||
pci->ops->stop_link(pci);
|
||||
}
|
||||
|
||||
static inline int dw_pcie_assert_perst(struct dw_pcie *pci, bool assert)
|
||||
{
|
||||
if (pci->ops && pci->ops->assert_perst)
|
||||
return pci->ops->assert_perst(pci, assert);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline enum dw_pcie_ltssm dw_pcie_get_ltssm(struct dw_pcie *pci)
|
||||
{
|
||||
u32 val;
|
||||
|
|
|
|||
|
|
@ -642,18 +642,6 @@ static int qcom_pcie_post_init_1_0_0(struct qcom_pcie *pcie)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int qcom_pcie_assert_perst(struct dw_pcie *pci, bool assert)
|
||||
{
|
||||
struct qcom_pcie *pcie = to_qcom_pcie(pci);
|
||||
|
||||
if (assert)
|
||||
qcom_ep_reset_assert(pcie);
|
||||
else
|
||||
qcom_ep_reset_deassert(pcie);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void qcom_pcie_2_3_2_ltssm_enable(struct qcom_pcie *pcie)
|
||||
{
|
||||
u32 val;
|
||||
|
|
@ -1514,7 +1502,6 @@ static const struct qcom_pcie_cfg cfg_fw_managed = {
|
|||
static const struct dw_pcie_ops dw_pcie_ops = {
|
||||
.link_up = qcom_pcie_link_up,
|
||||
.start_link = qcom_pcie_start_link,
|
||||
.assert_perst = qcom_pcie_assert_perst,
|
||||
};
|
||||
|
||||
static int qcom_pcie_icc_init(struct qcom_pcie *pcie)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user