Skip to content

Commit 5489866

Browse files
stephan-ghandersson
authored andcommitted
remoteproc: qcom: q6v5: Avoid handling handover twice
A remoteproc could theoretically signal handover twice. This is unexpected and would break the reference counting for the handover resources (power domains, clocks, regulators, etc), so add a check to prevent that from happening. Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: Stephan Gerhold <stephan.gerhold@linaro.org> Link: https://lore.kernel.org/r/20250820-rproc-qcom-q6v5-fixes-v2-2-910b1a3aff71@linaro.org Signed-off-by: Bjorn Andersson <andersson@kernel.org>
1 parent 110be46 commit 5489866

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

drivers/remoteproc/qcom_q6v5.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,11 @@ static irqreturn_t q6v5_handover_interrupt(int irq, void *data)
164164
{
165165
struct qcom_q6v5 *q6v5 = data;
166166

167+
if (q6v5->handover_issued) {
168+
dev_err(q6v5->dev, "Handover signaled, but it already happened\n");
169+
return IRQ_HANDLED;
170+
}
171+
167172
if (q6v5->handover)
168173
q6v5->handover(q6v5);
169174

0 commit comments

Comments
 (0)