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

Commit 5f3ab697 authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "coresight: tpdm: disable tpdm when resetting tpdm"

parents 044cf938 6d1f6ce9
Loading
Loading
Loading
Loading
+3 −10
Original line number Diff line number Diff line
@@ -943,18 +943,11 @@ static ssize_t reset_store(struct device *dev,
	/* Init the default data */
	tpdm_init_default_data(drvdata);

	/* Disable tpdm if enabled */
	if (drvdata->enable) {
		__tpdm_disable(drvdata);
		drvdata->enable = false;
	}

	mutex_unlock(&drvdata->lock);

	if (drvdata->enable) {
		tpdm_setup_disable(drvdata);
		dev_info(drvdata->dev, "TPDM tracing disabled\n");
	}
	/* Disable tpdm if enabled */
	if (drvdata->enable)
		coresight_disable(drvdata->csdev);

	return size;
}