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

Commit 59430433 authored by Tingwei Zhang's avatar Tingwei Zhang
Browse files

coresight: tmc: Fix mem_lock dead lock



Mem_lock was not unlocked when multiple sources were enabled and
one of them was disabled first. Free mem_lock in that path.

Change-Id: I380b2ce89c2df2dfd91754d2257503ade69545ce
Signed-off-by: default avatarTingwei Zhang <tingwei@codeaurora.org>
parent a70116e1
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1650,6 +1650,7 @@ static int tmc_disable_etr_sink(struct coresight_device *csdev)

	if (atomic_dec_return(csdev->refcnt)) {
		spin_unlock_irqrestore(&drvdata->spinlock, flags);
		mutex_unlock(&drvdata->mem_lock);
		return -EBUSY;
	}