X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=include%2Finstrumentation%2Fevents%2Fworkqueue.h;h=585731710b67eafbc9eab94e94f1aa1e175806c1;hb=f39b4a3cbff6d286025bd692aaa24ae6f8efb40b;hp=023b65a8d8df00b2f62b5ca6a29e57eda0ed8f86;hpb=5f4c791e2ad2c814101ccdb500e65543f2792c41;p=lttng-modules.git diff --git a/include/instrumentation/events/workqueue.h b/include/instrumentation/events/workqueue.h index 023b65a8..58573171 100644 --- a/include/instrumentation/events/workqueue.h +++ b/include/instrumentation/events/workqueue.h @@ -28,10 +28,11 @@ LTTNG_TRACEPOINT_EVENT_CLASS(workqueue_work, ) ) +#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(5,19,0)) /** * workqueue_queue_work - called when a work gets queued * @req_cpu: the requested cpu - * @cwq: pointer to struct cpu_workqueue_struct + * @pwq: pointer to struct pool_workqueue * @work: pointer to struct work_struct * * This event occurs when a work is queued immediately or once a @@ -40,17 +41,34 @@ LTTNG_TRACEPOINT_EVENT_CLASS(workqueue_work, */ LTTNG_TRACEPOINT_EVENT(workqueue_queue_work, -#if (LTTNG_LINUX_VERSION_CODE >= LTTNG_KERNEL_VERSION(3,9,0)) - TP_PROTO(unsigned int req_cpu, struct pool_workqueue *pwq, + TP_PROTO(int req_cpu, struct pool_workqueue *pwq, struct work_struct *work), TP_ARGS(req_cpu, pwq, work), + + TP_FIELDS( + ctf_integer_hex(void *, work, work) + ctf_integer_hex(void *, function, work->func) + ctf_integer(int, req_cpu, req_cpu) + ) +) #else - TP_PROTO(unsigned int req_cpu, struct cpu_workqueue_struct *cwq, +/** + * workqueue_queue_work - called when a work gets queued + * @req_cpu: the requested cpu + * @pwq: pointer to struct pool_workqueue + * @work: pointer to struct work_struct + * + * This event occurs when a work is queued immediately or once a + * delayed work is actually queued on a workqueue (ie: once the delay + * has been reached). + */ +LTTNG_TRACEPOINT_EVENT(workqueue_queue_work, + + TP_PROTO(unsigned int req_cpu, struct pool_workqueue *pwq, struct work_struct *work), - TP_ARGS(req_cpu, cwq, work), -#endif + TP_ARGS(req_cpu, pwq, work), TP_FIELDS( ctf_integer_hex(void *, work, work) @@ -58,6 +76,7 @@ LTTNG_TRACEPOINT_EVENT(workqueue_queue_work, ctf_integer(unsigned int, req_cpu, req_cpu) ) ) +#endif /** * workqueue_activate_work - called when a work gets activated