]> git.baikalelectronics.ru Git - kernel.git/commit
remoteproc: sysmon: Send sysmon state only for running rprocs
authorSiddharth Gupta <sidgup@codeaurora.org>
Tue, 5 Jul 2022 12:08:20 +0000 (17:38 +0530)
committerBjorn Andersson <bjorn.andersson@linaro.org>
Mon, 18 Jul 2022 20:32:34 +0000 (15:32 -0500)
commitfd75c2d01a50d877b375786abbeb179564ea8ffc
tree7dd1f2aac6cb3b4c97f6fbae652d256ddcabbc37
parent47c04e00eff86a81cd357c3feed04c86089bcb85
remoteproc: sysmon: Send sysmon state only for running rprocs

When a new remoteproc boots up, send the sysmon state notification
of only running remoteprocs. Sending state of remoteprocs booting
up in parallel can cause a race between SSR clients of the remoteproc
that is booting up and the sysmon notification for the same remoteproc,
resulting in an inconsistency between which state the remoteproc that
is booting up in parallel.

For example - if remoteproc A and B crash one after the other, after
remoteproc A boots up, if the remoteproc A tries to get the state of
remoteproc B before the sysmon subdevice for B is invoked but after
the ssr subdevice of B has been invoked, clients on remoteproc A
might get confused when the sysmon notification indicates a different
state.

Signed-off-by: Siddharth Gupta <sidgup@codeaurora.org>
Signed-off-by: Sibi Sankar <quic_sibis@quicinc.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@somainline.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Link: https://lore.kernel.org/r/1657022900-2049-8-git-send-email-quic_sibis@quicinc.com
drivers/remoteproc/qcom_sysmon.c