[PATCH 3/3] clk: qcom: smd-rpm: Drop binary value handling for buffered clock
From: Shawn Guo
Date: Sat Oct 30 2021 - 22:07:59 EST
The buffered clock binary value handling added by commit 36354c32bd76
("clk: qcom: smd-rpm: Add .recalc_rate hook for clk_smd_rpm_branch_ops")
is redundant, because buffered clock is branch type, and the binary
value handling for branch clock has been handled by
clk_smd_rpm_prepare/unprepare functions.
Signed-off-by: Shawn Guo <shawn.guo@xxxxxxxxxx>
---
drivers/clk/qcom/clk-smd-rpm.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/drivers/clk/qcom/clk-smd-rpm.c b/drivers/clk/qcom/clk-smd-rpm.c
index dd3d373a1309..ea28e45ca371 100644
--- a/drivers/clk/qcom/clk-smd-rpm.c
+++ b/drivers/clk/qcom/clk-smd-rpm.c
@@ -189,10 +189,6 @@ static int clk_smd_rpm_set_rate_active(struct clk_smd_rpm *r,
.value = cpu_to_le32(DIV_ROUND_UP(rate, 1000)), /* to kHz */
};
- /* Buffered clock needs a binary value */
- if (r->rpm_res_type == QCOM_SMD_RPM_CLK_BUF_A)
- req.value = cpu_to_le32(!!req.value);
-
return qcom_rpm_smd_write(r->rpm, QCOM_SMD_RPM_ACTIVE_STATE,
r->rpm_res_type, r->rpm_clk_id, &req,
sizeof(req));
@@ -207,10 +203,6 @@ static int clk_smd_rpm_set_rate_sleep(struct clk_smd_rpm *r,
.value = cpu_to_le32(DIV_ROUND_UP(rate, 1000)), /* to kHz */
};
- /* Buffered clock needs a binary value */
- if (r->rpm_res_type == QCOM_SMD_RPM_CLK_BUF_A)
- req.value = cpu_to_le32(!!req.value);
-
return qcom_rpm_smd_write(r->rpm, QCOM_SMD_RPM_SLEEP_STATE,
r->rpm_res_type, r->rpm_clk_id, &req,
sizeof(req));
--
2.17.1