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

Commit f9c6f9cb authored by Prateek Shrivastava's avatar Prateek Shrivastava Committed by Shivendra Kakrania
Browse files

msm: vidc: Correct Validation of new operating rate



ops left is defined as remaining frequency per load
on the core which is remaining frequency per mb per
sec. This can be interpretated as fraction of the
current operation rate that can be increased as per
the load on current core.

CRs-Fixed: 2183108
Change-Id: I1579efdf4d96777b786870bbe94928f0622b790b
Signed-off-by: default avatarPrateek Shrivastava <pshrivas@codeaurora.org>
parent e81208da
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
/* Copyright (c) 2017, The Linux Foundation. All rights reserved.
/* Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -710,7 +710,7 @@ int msm_vidc_validate_operating_rate(struct msm_vidc_inst *inst,

	operating_rate = operating_rate >> 16;

	if ((curr_operating_rate + ops_left) >= operating_rate ||
	if ((curr_operating_rate * (1 + ops_left)) >= operating_rate ||
			!msm_vidc_clock_scaling ||
			inst->clk_data.buffer_counter < DCVS_FTB_WINDOW) {
		dprintk(VIDC_DBG,