Skip to content
This repository has been archived by the owner on Oct 31, 2024. It is now read-only.

Commit

Permalink
remoteproc: k3-r5: Delay notification of wakeup event
Browse files Browse the repository at this point in the history
[ Upstream commit 8fa052c ]

Few times, core1 was scheduled to boot first before core0, which leads
to error:

'k3_r5_rproc_start: can not start core 1 before core 0'.

This was happening due to some scheduling between prepare and start
callback. The probe function waits for event, which is getting
triggered by prepare callback. To avoid above condition move event
trigger to start instead of prepare callback.

Fixes: 61f6f68 ("remoteproc: k3-r5: Wait for core0 power-up before powering up core1")
Signed-off-by: Udit Kumar <u-kumar1@ti.com>
[ Applied wakeup event trigger only for Split-Mode booted rprocs ]
Signed-off-by: Beleswar Padhi <b-padhi@ti.com>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20240820105004.2788327-1-b-padhi@ti.com
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
uditkumarti authored and gregkh committed Oct 10, 2024
1 parent 46b8279 commit bf6dee1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions drivers/remoteproc/ti_k3_r5_remoteproc.c
Original file line number Diff line number Diff line change
Expand Up @@ -469,8 +469,6 @@ static int k3_r5_rproc_prepare(struct rproc *rproc)
ret);
return ret;
}
core->released_from_reset = true;
wake_up_interruptible(&cluster->core_transition);

/*
* Newer IP revisions like on J7200 SoCs support h/w auto-initialization
Expand Down Expand Up @@ -587,6 +585,9 @@ static int k3_r5_rproc_start(struct rproc *rproc)
ret = k3_r5_core_run(core);
if (ret)
return ret;

core->released_from_reset = true;
wake_up_interruptible(&cluster->core_transition);
}

return 0;
Expand Down

0 comments on commit bf6dee1

Please sign in to comment.