summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmandeep Singh <amansing@codeaurora.org>2019-09-12 15:40:35 +0530
committerAmandeep Singh <amansing@codeaurora.org>2019-09-12 15:40:35 +0530
commit412a92fa0f21ce6d0b47ae3ea025cd7e705da9f5 (patch)
treeab9a1c68a1d46025f3d5592badc7a9985616343f
parenta08ceb359a912d92586bde08dea82522fd30558f (diff)
msm: qcn: Change spin_lock api to synchronize clients
Change spin_lock api to spin_lock_bh to provide synchronization between bottom halves and threads. Change-Id: Ia964796e3d91ebce60238ad110086ba06a1026c1 Signed-off-by: Amandeep Singh <amansing@codeaurora.org>
-rw-r--r--drivers/platform/msm/qcn/qcn_sdio.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/platform/msm/qcn/qcn_sdio.c b/drivers/platform/msm/qcn/qcn_sdio.c
index 21dcd3c74508..4aa5810f91f7 100644
--- a/drivers/platform/msm/qcn/qcn_sdio.c
+++ b/drivers/platform/msm/qcn/qcn_sdio.c
@@ -188,10 +188,10 @@ static struct qcn_sdio_rw_info *qcn_sdio_alloc_rw_req(void)
static void qcn_sdio_add_rw_req(struct qcn_sdio_rw_info *rw_req)
{
- spin_lock(&sdio_ctxt->lock_wait_q);
+ spin_lock_bh(&sdio_ctxt->lock_wait_q);
list_add_tail(&rw_req->list, &sdio_ctxt->rw_wait_q);
atomic_inc(&sdio_ctxt->wait_list_count);
- spin_unlock(&sdio_ctxt->lock_wait_q);
+ spin_unlock_bh(&sdio_ctxt->lock_wait_q);
}
static int qcn_enable_async_irq(bool enable)
@@ -650,15 +650,15 @@ static void qcn_sdio_rw_work(struct work_struct *work)
struct sdio_al_channel_handle *ch_handle = NULL;
while (1) {
- spin_lock(&sdio_ctxt->lock_wait_q);
+ spin_lock_bh(&sdio_ctxt->lock_wait_q);
if (list_empty(&sdio_ctxt->rw_wait_q)) {
- spin_unlock(&sdio_ctxt->lock_wait_q);
+ spin_unlock_bh(&sdio_ctxt->lock_wait_q);
break;
}
rw_req = list_first_entry(&sdio_ctxt->rw_wait_q,
struct qcn_sdio_rw_info, list);
list_del(&rw_req->list);
- spin_unlock(&sdio_ctxt->lock_wait_q);
+ spin_unlock_bh(&sdio_ctxt->lock_wait_q);
if (rw_req->dir) {
ret = qcn_sdio_recv_buff(rw_req->cid, rw_req->buf,