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

Commit 76c6f736 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: msm_bus: Add vote_count to tracing"

parents 26c668e3 5f0bdd90
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -43,6 +43,7 @@ struct msm_bus_cldata {
	int index;
	uint32_t clid;
	int size;
	int vote_count;
	struct dentry *file;
	struct list_head list;
	char buffer[MAX_BUFF_SIZE];
@@ -432,6 +433,7 @@ static int msm_bus_dbg_record_client(const struct msm_bus_scale_pdata *pdata,
	cldata->clid = clid;
	cldata->file = file;
	cldata->size = 0;
	cldata->vote_count = 0;
	rt_mutex_lock(&msm_bus_dbg_cllist_lock);
	list_add_tail(&cldata->list, &cl_list);
	rt_mutex_unlock(&msm_bus_dbg_cllist_lock);
@@ -486,6 +488,7 @@ static int msm_bus_dbg_fill_cl_buffer(const struct msm_bus_scale_pdata *pdata,
			clients, clid);
	}

	cldata->vote_count++;
	if (cldata->size < (MAX_BUFF_SIZE - FILL_LIMIT))
		i = cldata->size;
	else {
@@ -767,7 +770,8 @@ static ssize_t msm_bus_dbg_dump_clients_read(struct file *file,
			cldata->pdata->usecase[cldata->index].vectors[j].dst,
			cldata->pdata->usecase[cldata->index].vectors[j].ab,
			cldata->pdata->usecase[cldata->index].vectors[j].ib,
			cldata->pdata->active_only);
			cldata->pdata->active_only,
			cldata->vote_count);
		}
	}
	rt_mutex_unlock(&msm_bus_dbg_cllist_lock);
+9 −5
Original line number Diff line number Diff line
/* SPDX-License-Identifier: GPL-2.0-only */
/*
 * Copyright (c) 2014-2016, The Linux Foundation. All rights reserved.
 * Copyright (c) 2014-2016, 2019, The Linux Foundation. All rights reserved.
 */

#undef TRACE_SYSTEM
@@ -167,9 +167,10 @@ TRACE_EVENT(bus_bke_params,
TRACE_EVENT(bus_client_status,

	TP_PROTO(const char *name, int src, int dest,
		unsigned long long ab, unsigned long long ib, int active_only),
		unsigned long long ab, unsigned long long ib,
		int active_only, int vote_count),

	TP_ARGS(name, src, dest, ab, ib, active_only),
	TP_ARGS(name, src, dest, ab, ib, active_only, vote_count),

	TP_STRUCT__entry(
		__string(name, name)
@@ -178,6 +179,7 @@ TRACE_EVENT(bus_client_status,
		__field(u64, ab)
		__field(u64, ib)
		__field(int, active_only)
		__field(int, vote_count)
	),

	TP_fast_assign(
@@ -187,15 +189,17 @@ TRACE_EVENT(bus_client_status,
		__entry->ab = ab;
		__entry->ib = ib;
		__entry->active_only = active_only;
		__entry->vote_count = vote_count;
	),

	TP_printk("name=%s src=%d dest=%d ab=%llu ib=%llu active_only=%d",
	TP_printk("name=%s src=%d dest=%d ab=%llu ib=%llu active_only=%d vote_count=%d",
		__get_str(name),
		__entry->src,
		__entry->dest,
		(unsigned long long)__entry->ab,
		(unsigned long long)__entry->ib,
		__entry->active_only)
		__entry->active_only,
		__entry->vote_count)
);

TRACE_EVENT(bus_agg_bw,