summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinux Build Service Account <lnxbuild@localhost>2017-03-31 21:24:17 -0700
committerGerrit - the friendly Code Review server <code-review@localhost>2017-03-31 21:24:16 -0700
commit6b41d84c53f26dfe24539a21c503bc29cfe27080 (patch)
tree3a02df2dbb4acbdd9879d2d1a7af5cfa2ea6d0b2
parent29a84088160446ea8c7b30b16ff65c45bcde9b03 (diff)
parent618dde7de185ccb069e2e1f6b7a364efb9e05de3 (diff)
Merge "soc: qcom: spcom: lock ion buf, decrement ref count if no free entry"
-rw-r--r--drivers/soc/qcom/spcom.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/soc/qcom/spcom.c b/drivers/soc/qcom/spcom.c
index 457361ba5ff8..0c44d76bc7c7 100644
--- a/drivers/soc/qcom/spcom.c
+++ b/drivers/soc/qcom/spcom.c
@@ -1744,7 +1744,9 @@ static int spcom_handle_lock_ion_buf_command(struct spcom_channel *ch,
}
}
- pr_err("fd [%d] ion buf not found.\n", fd);
+ pr_err("no free entry to store ion handle of fd [%d].\n", fd);
+ /* decrement back the ref count */
+ ion_free(spcom_dev->ion_client, ion_handle);
return -EFAULT;
}