X-Git-Url: http://git.liburcu.org/?a=blobdiff_plain;f=instrumentation%2Fevents%2Flttng-module%2Fregmap.h;h=f02d3af49969c8d7da94bc3e77877b34f132bcc9;hb=104eadd2e2a00b0ab09e3a459a893f78b006ae17;hp=358d744f9e815c7482071986e0654334a0710ec3;hpb=6bdc39b10e8a16c966e2c338084ef13f84af3af3;p=lttng-modules.git diff --git a/instrumentation/events/lttng-module/regmap.h b/instrumentation/events/lttng-module/regmap.h index 358d744f..f02d3af4 100644 --- a/instrumentation/events/lttng-module/regmap.h +++ b/instrumentation/events/lttng-module/regmap.h @@ -1,12 +1,13 @@ +/* SPDX-License-Identifier: GPL-2.0 */ #undef TRACE_SYSTEM #define TRACE_SYSTEM regmap #if !defined(LTTNG_TRACE_REGMAP_H) || defined(TRACE_HEADER_MULTI_READ) #define LTTNG_TRACE_REGMAP_H -#include "../../../probes/lttng-tracepoint-event.h" +#include #include -#include +#include #ifndef _TRACE_REGMAP_DEF_ #define _TRACE_REGMAP_DEF_ @@ -14,7 +15,6 @@ struct device; struct regmap; #endif -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,19,4)) /* * Log register events */ @@ -46,42 +46,7 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_reg, regmap_reg_read, TP_ARGS(map, reg, val) ) -#else -/* - * Log register events - */ -LTTNG_TRACEPOINT_EVENT_CLASS(regmap_reg, - - TP_PROTO(struct device *dev, unsigned int reg, - unsigned int val), - - TP_ARGS(dev, reg, val), - - TP_FIELDS( - ctf_string(name, dev_name(dev)) - ctf_integer(unsigned int, reg, reg) - ctf_integer(unsigned int, val, val) - ) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_reg, regmap_reg_write, - - TP_PROTO(struct device *dev, unsigned int reg, - unsigned int val), - - TP_ARGS(dev, reg, val) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_reg, regmap_reg_read, - TP_PROTO(struct device *dev, unsigned int reg, - unsigned int val), - - TP_ARGS(dev, reg, val) -) -#endif - -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,19,4)) LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_reg, regmap_reg_read_cache, TP_PROTO(struct regmap *map, unsigned int reg, @@ -89,17 +54,7 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_reg, regmap_reg_read_cache, TP_ARGS(map, reg, val) ) -#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(3,3,0)) -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_reg, regmap_reg_read_cache, - - TP_PROTO(struct device *dev, unsigned int reg, - unsigned int val), - - TP_ARGS(dev, reg, val) -) -#endif -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,19,4)) LTTNG_TRACEPOINT_EVENT_CLASS(regmap_block, TP_PROTO(struct regmap *map, unsigned int reg, int count), @@ -140,50 +95,7 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_block, regmap_hw_write_done, TP_ARGS(map, reg, count) ) -#else -LTTNG_TRACEPOINT_EVENT_CLASS(regmap_block, - - TP_PROTO(struct device *dev, unsigned int reg, int count), - - TP_ARGS(dev, reg, count), - - TP_FIELDS( - ctf_string(name, dev_name(dev)) - ctf_integer(unsigned int, reg, reg) - ctf_integer(int, count, count) - ) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_block, regmap_hw_read_start, - - TP_PROTO(struct device *dev, unsigned int reg, int count), - - TP_ARGS(dev, reg, count) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_block, regmap_hw_read_done, - - TP_PROTO(struct device *dev, unsigned int reg, int count), - - TP_ARGS(dev, reg, count) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_block, regmap_hw_write_start, - - TP_PROTO(struct device *dev, unsigned int reg, int count), - - TP_ARGS(dev, reg, count) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_block, regmap_hw_write_done, - - TP_PROTO(struct device *dev, unsigned int reg, int count), - - TP_ARGS(dev, reg, count) -) -#endif -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,19,4)) LTTNG_TRACEPOINT_EVENT_MAP(regcache_sync, regmap_regcache_sync, @@ -199,25 +111,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(regcache_sync, ctf_string(type, type) ) ) -#else -LTTNG_TRACEPOINT_EVENT_MAP(regcache_sync, - - regmap_regcache_sync, - TP_PROTO(struct device *dev, const char *type, - const char *status), - - TP_ARGS(dev, type, status), - - TP_FIELDS( - ctf_string(name, dev_name(dev)) - ctf_string(status, status) - ctf_string(type, type) - ) -) -#endif - -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,19,4)) LTTNG_TRACEPOINT_EVENT_CLASS(regmap_bool, TP_PROTO(struct regmap *map, bool flag), @@ -244,35 +138,8 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_bool, regmap_cache_bypass, TP_ARGS(map, flag) ) -#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(3,4,0)) -LTTNG_TRACEPOINT_EVENT_CLASS(regmap_bool, - - TP_PROTO(struct device *dev, bool flag), - - TP_ARGS(dev, flag), - - TP_FIELDS( - ctf_string(name, dev_name(dev)) - ctf_integer(int, flag, flag) - ) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_bool, regmap_cache_only, - - TP_PROTO(struct device *dev, bool flag), - - TP_ARGS(dev, flag) -) - -LTTNG_TRACEPOINT_EVENT_INSTANCE(regmap_bool, regmap_cache_bypass, - - TP_PROTO(struct device *dev, bool flag), - - TP_ARGS(dev, flag) -) -#endif #endif /* LTTNG_TRACE_REGMAP_H */ /* This part must be outside protection */ -#include "../../../probes/define_trace.h" +#include