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

Commit 73cc5a61 authored by Pavan Kumar Chilamkurthi's avatar Pavan Kumar Chilamkurthi
Browse files

msm: camera: cpas: Use turbo requested freq is higher



Use TURBO vote for ahb if clients requests ahb vote with
freq higher than the clock freq supported by that device.
opp_find_freq_ceil api fails if called with freq higher
than what that device supports, use turbo in such cases.

Change-Id: I146a01e77c459341396ef6df5dc1ff5286fea808
Signed-off-by: default avatarPavan Kumar Chilamkurthi <pchilamk@codeaurora.org>
parent 40987cc0
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -662,9 +662,10 @@ static int cam_cpas_util_get_ahb_level(struct cam_hw_info *cpas_hw,

	opp = dev_pm_opp_find_freq_ceil(dev, &corner_freq);
	if (IS_ERR(opp)) {
		CAM_ERR(CAM_CPAS, "Error on OPP freq :%ld, %pK",
		CAM_DBG(CAM_CPAS, "OPP Ceil not available for freq :%ld, %pK",
			corner_freq, opp);
		return -EINVAL;
		*req_level = CAM_TURBO_VOTE;
		return 0;
	}

	corner = dev_pm_opp_get_voltage(opp);