Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 28d98977 authored by Mitchel Humpherys's avatar Mitchel Humpherys
Browse files

msm: ADSPRPC: Free contexts for current channel



When multiple channels are opened from same process, free
contexts associated only with the current channel when the
device is released.

Change-Id: Iaa1f06ee00f3b9420ef5b00995bdf8186cb83283
Acked-by: default avatarSathish Ambley <sambley@qti.qualcomm.com>
Signed-off-by: default avatarMitchel Humpherys <mitchelh@codeaurora.org>
parent 3311f658
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1663,7 +1663,8 @@ static int fastrpc_device_release(struct inode *inode, struct file *file)
		ctxfree = 0;
		spin_lock(&clst->hlock);
		hlist_for_each_entry_safe(ictx, n, &clst->interrupted, hn) {
			if (ictx->tgid == current->tgid) {
			if ((ictx->tgid == current->tgid) &&
				(ictx->fdata->cid == cid)) {
				hlist_del(&ictx->hn);
				ctxfree = ictx;
				break;