2 * Copyright (C) ARM Limited 2010-2013. All rights reserved.
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
12 #if !defined(_TRACE_GPU_H)
15 #include <linux/tracepoint.h>
18 * UNIT - the GPU processor type
19 * 1 = Vertex Processor
20 * 2 = Fragment Processor
22 * CORE - the GPU processor core number
23 * this is not the CPU core number
27 * Tracepoint for calling GPU unit start activity on core
29 TRACE_EVENT(gpu_activity_start,
31 TP_PROTO(int gpu_unit, int gpu_core, struct task_struct *p),
33 TP_ARGS(gpu_unit, gpu_core, p),
36 __field(int, gpu_unit)
37 __field(int, gpu_core)
38 __array(char, comm, TASK_COMM_LEN)
43 __entry->gpu_unit = gpu_unit;
44 __entry->gpu_core = gpu_core;
45 memcpy(__entry->comm, p->comm, TASK_COMM_LEN);
46 __entry->pid = p->pid;
49 TP_printk("unit=%d core=%d comm=%s pid=%d",
50 __entry->gpu_unit, __entry->gpu_core, __entry->comm,
55 * Tracepoint for calling GPU unit stop activity on core
57 TRACE_EVENT(gpu_activity_stop,
59 TP_PROTO(int gpu_unit, int gpu_core),
61 TP_ARGS(gpu_unit, gpu_core),
64 __field(int, gpu_unit)
65 __field(int, gpu_core)
69 __entry->gpu_unit = gpu_unit;
70 __entry->gpu_core = gpu_core;
73 TP_printk("unit=%d core=%d", __entry->gpu_unit, __entry->gpu_core)
76 #endif /* _TRACE_GPU_H */
78 /* This part must be outside protection */
79 #include <trace/define_trace.h>