rpmsg: smd: Use spinlock in tx path
authorBjorn Andersson <bjorn.andersson@linaro.org>
Tue, 13 Feb 2018 19:04:11 +0000 (11:04 -0800)
committerBjorn Andersson <bjorn.andersson@linaro.org>
Tue, 20 Mar 2018 02:52:17 +0000 (10:52 +0800)
commit33e3820dda8876792bd8135db633c741a07263be
tree263a1d4b53c52ba6860056d00fa6f9d9edb4c570
parentbe5acd246daa04edad9d758b8be37e5e2f989243
rpmsg: smd: Use spinlock in tx path

By switching the tx_lock to a spinlock we allow clients to use
rpmsg_trysend() from atomic context.

The mutex was interruptable as it was previously held for the duration
of some client waiting for available space in the FIFO, but this was
recently changed to only be held temporarily - allowing us to replace it
with a spinlock.

Tested-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
drivers/rpmsg/qcom_smd.c