Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b096d6c1 authored by Subhash Jadavani's avatar Subhash Jadavani
Browse files

scsi: ufs-qcom: fix symbol clocks handling



We are only enabling the lane-0 symbol clock in 1-lane configuration
but it seems during disabling we are trying to disable lane-1 symbol
clocks as well even if they were never enable in 1-lane configuration,
this change fixes this minor issue.

Change-Id: I619a7c2e83a96caa338a56d53e61bba3d982ea13
Signed-off-by: default avatarSubhash Jadavani <subhashj@codeaurora.org>
parent 861a4ae9
Loading
Loading
Loading
Loading
+6 −3
Original line number Diff line number Diff line
@@ -121,8 +121,10 @@ static void ufs_qcom_disable_lane_clks(struct ufs_qcom_host *host)
	if (!host->is_lane_clks_enabled)
		return;

	if (host->hba->lanes_per_direction > 1)
		clk_disable_unprepare(host->tx_l1_sync_clk);
	clk_disable_unprepare(host->tx_l0_sync_clk);
	if (host->hba->lanes_per_direction > 1)
		clk_disable_unprepare(host->rx_l1_sync_clk);
	clk_disable_unprepare(host->rx_l0_sync_clk);

@@ -162,6 +164,7 @@ static int ufs_qcom_enable_lane_clks(struct ufs_qcom_host *host)
	goto out;

disable_rx_l1:
	if (host->hba->lanes_per_direction > 1)
		clk_disable_unprepare(host->rx_l1_sync_clk);
disable_tx_l0:
	clk_disable_unprepare(host->tx_l0_sync_clk);