Skip to content

Commit 0614f98

Browse files
lumagLorenzo Pieralisi
authored andcommitted
PCI: qcom: Add ddrss_sf_tbu flag
Qualcomm PCIe driver uses compatible string to check if the ddrss_sf_tbu clock should be used. Since sc7280 support has added flags, switch to the new mechanism to check if this clock should be used. Link: https://lore.kernel.org/r/20220223101435.447839-4-dmitry.baryshkov@linaro.org Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org> Acked-by: Stanimir Varbanov <svarbanov@mm-sol.com>
1 parent f94c35e commit 0614f98

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,7 @@ struct qcom_pcie_ops {
195195
struct qcom_pcie_cfg {
196196
const struct qcom_pcie_ops *ops;
197197
unsigned int pipe_clk_need_muxing:1;
198+
unsigned int has_ddrss_sf_tbu_clk:1;
198199
};
199200

200201
struct qcom_pcie {
@@ -1164,7 +1165,7 @@ static int qcom_pcie_get_resources_2_7_0(struct qcom_pcie *pcie)
11641165
res->clks[3].id = "bus_slave";
11651166
res->clks[4].id = "slave_q2a";
11661167
res->clks[5].id = "tbu";
1167-
if (of_device_is_compatible(dev->of_node, "qcom,pcie-sm8250")) {
1168+
if (pcie->cfg->has_ddrss_sf_tbu_clk) {
11681169
res->clks[6].id = "ddrss_sf_tbu";
11691170
res->num_clks = 7;
11701171
} else {
@@ -1512,6 +1513,7 @@ static const struct qcom_pcie_cfg sdm845_cfg = {
15121513

15131514
static const struct qcom_pcie_cfg sm8250_cfg = {
15141515
.ops = &ops_1_9_0,
1516+
.has_ddrss_sf_tbu_clk = true,
15151517
};
15161518

15171519
static const struct qcom_pcie_cfg sc7280_cfg = {

0 commit comments

Comments
 (0)