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

Commit 12d07c9e authored by Yuanfang Zhang's avatar Yuanfang Zhang Committed by Gerrit - the friendly Code Review server
Browse files

coresight-tmc-etr: use sysfs_buf in tmc_sg_get_rwp_offset()



When usb bypass start, etr_buf may be null. If etr disable hw is
called at the same time. Use sysfs_buf in tmc_sg_get_rwp_offset to
avoid this issue.

Change-Id: Id1e45269d08f61413d385de7aa46df4cc3d8c44d
Signed-off-by: default avatarYuanfang Zhang <zhangyuanfang@codeaurora.org>
parent a0e35cc3
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -275,7 +275,7 @@ void tmc_free_sg_table(struct tmc_sg_table *sg_table)

long tmc_sg_get_rwp_offset(struct tmc_drvdata *drvdata)
{
	struct etr_buf *etr_buf = drvdata->etr_buf;
	struct etr_buf *etr_buf = drvdata->sysfs_buf;
	struct etr_sg_table *etr_table = etr_buf->private;
	struct tmc_sg_table *table = etr_table->sg_table;
	u64 rwp;