mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-24 10:34:43 +03:00
gpu: nvgpu: nvgpu_pmu_enable_elpg to return status
nvgpu_pmu_enable_elpg was always returning 0 when a proper status could be returned instead. This patch fixes the issue and makes use of it in fifo_gv11b. JIRA NVGPU-677 Change-Id: Idfcae786ce40ca5498e527e61b2b5cbb1fd1413c Signed-off-by: Nicolas Benech <nbenech@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1996855 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
a93b350c67
commit
6cbae2c28f
@@ -178,10 +178,15 @@ static int pmu_enable_elpg_locked(struct gk20a *g, u8 pg_engine_id)
|
||||
status = nvgpu_pmu_cmd_post(g, &cmd, NULL, NULL,
|
||||
PMU_COMMAND_QUEUE_HPQ, pmu_handle_pg_elpg_msg,
|
||||
pmu, &seq);
|
||||
WARN_ON(status != 0);
|
||||
|
||||
nvgpu_log_fn(g, "done");
|
||||
return 0;
|
||||
if (status != 0) {
|
||||
nvgpu_log_fn(g, "pmu_enable_elpg_locked FAILED err=%d",
|
||||
status);
|
||||
} else {
|
||||
nvgpu_log_fn(g, "done");
|
||||
}
|
||||
|
||||
return status;
|
||||
}
|
||||
|
||||
int nvgpu_pmu_enable_elpg(struct gk20a *g)
|
||||
|
||||
@@ -1279,7 +1279,9 @@ void gv11b_fifo_teardown_ch_tsg(struct gk20a *g, u32 act_eng_bitmask,
|
||||
|
||||
/* It is safe to enable ELPG again. */
|
||||
if (g->support_pmu && g->elpg_enabled) {
|
||||
nvgpu_pmu_enable_elpg(g);
|
||||
if (nvgpu_pmu_enable_elpg(g) != 0) {
|
||||
nvgpu_err(g, "ELPG enable failed");
|
||||
}
|
||||
}
|
||||
|
||||
/* release runlist_lock */
|
||||
|
||||
Reference in New Issue
Block a user