Skip to content

Commit

Permalink
rpmsg: qcom_smd: Fix redundant channel->registered assignment
Browse files Browse the repository at this point in the history
In qcom_channel_state_worker(), we are setting channel->registered
to true when registering a channel, but this is getting repeated both
before and after re-locking the channels_lock spinlock, which is
obviously a typo.
Remove the assignment done out of the spinlock to fix this redundancy.

Fixes: 53e2822 ("rpmsg: Introduce Qualcomm SMD backend")
Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Link: https://lore.kernel.org/r/20220114133259.247726-1-angelogioacchino.delregno@collabora.com
  • Loading branch information
AngeloGioacchino Del Regno authored and Bjorn Andersson committed Mar 12, 2022
1 parent 18fc82d commit db64e7e
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions drivers/rpmsg/qcom_smd.c
Original file line number Diff line number Diff line change
Expand Up @@ -1303,9 +1303,7 @@ static void qcom_channel_state_worker(struct work_struct *work)

spin_unlock_irqrestore(&edge->channels_lock, flags);
qcom_smd_create_device(channel);
channel->registered = true;
spin_lock_irqsave(&edge->channels_lock, flags);

channel->registered = true;
}

Expand Down

0 comments on commit db64e7e

Please sign in to comment.