diff options
author | Bjorn Andersson | 2023-02-14 15:42:31 -0800 |
---|---|---|
committer | Greg Kroah-Hartman | 2023-03-10 09:33:45 +0100 |
commit | 09699f0e5b69a5ac6444974f7a956ad81b4026d3 (patch) | |
tree | a10f25ed471824703ea1180cb73abca6e5a588ba | |
parent | 5df521e0b2cb811e2f969f1a663017910e7edcef (diff) |
rpmsg: glink: Avoid infinite loop on intent for missing channel
[ Upstream commit 3e74ec2f39362bffbd42854acbb67c7f4cb808f9 ]
In the event that an intent advertisement arrives on an unknown channel
the fifo is not advanced, resulting in the same message being handled
over and over.
Fixes: dacbb35e930f ("rpmsg: glink: Receive and store the remote intent buffers")
Signed-off-by: Bjorn Andersson <quic_bjorande@quicinc.com>
Reviewed-by: Chris Lew <quic_clew@quicinc.com>
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Link: https://lore.kernel.org/r/20230214234231.2069751-1-quic_bjorande@quicinc.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
-rw-r--r-- | drivers/rpmsg/qcom_glink_native.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/rpmsg/qcom_glink_native.c b/drivers/rpmsg/qcom_glink_native.c index 115c0a1eddb1..bb917746ad4b 100644 --- a/drivers/rpmsg/qcom_glink_native.c +++ b/drivers/rpmsg/qcom_glink_native.c @@ -954,6 +954,7 @@ static void qcom_glink_handle_intent(struct qcom_glink *glink, spin_unlock_irqrestore(&glink->idr_lock, flags); if (!channel) { dev_err(glink->dev, "intents for non-existing channel\n"); + qcom_glink_rx_advance(glink, ALIGN(msglen, 8)); return; } |