Skip to content

Commit f58078d

Browse files
rostedtbroonie
authored andcommitted
regmap: Move tracing header into drivers/base/regmap
The tracing events for regmap are confined to the regmap subsystem. It also requires accessing an internal header. Instead of including the internal header from a generic file location, move the tracing file into the regmap directory. Also rename the regmap tracing header to trace.h, as it is redundant to keep the regmap.h name when it is in the regmap directory. Signed-off-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent c6b570d commit f58078d

4 files changed

Lines changed: 12 additions & 3 deletions

File tree

‎drivers/base/regmap/Makefile‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# For include/trace/define_trace.h to include trace.h
2+
CFLAGS_regmap.o := -I$(src)
3+
14
obj-$(CONFIG_REGMAP) += regmap.o regcache.o
25
obj-$(CONFIG_REGMAP) += regcache-rbtree.o regcache-lzo.o regcache-flat.o
36
obj-$(CONFIG_DEBUG_FS) += regmap-debugfs.o

‎drivers/base/regmap/regcache.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
#include <linux/export.h>
1616
#include <linux/slab.h>
1717
#include <linux/sort.h>
18-
#include <trace/events/regmap.h>
1918

19+
#include "trace.h"
2020
#include "internal.h"
2121

2222
static const struct regcache_ops *cache_types[] = {

‎drivers/base/regmap/regmap.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
#include <linux/sched.h>
2121

2222
#define CREATE_TRACE_POINTS
23-
#include <trace/events/regmap.h>
23+
#include "trace.h"
2424

2525
#include "internal.h"
2626

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#include <linux/ktime.h>
88
#include <linux/tracepoint.h>
99

10-
#include "../../../drivers/base/regmap/internal.h"
10+
#include "internal.h"
1111

1212
/*
1313
* Log register events
@@ -247,5 +247,11 @@ TRACE_EVENT(regcache_drop_region,
247247

248248
#endif /* _TRACE_REGMAP_H */
249249

250+
#undef TRACE_INCLUDE_PATH
251+
#define TRACE_INCLUDE_PATH .
252+
253+
#undef TRACE_INCLUDE_FILE
254+
#define TRACE_INCLUDE_FILE trace
255+
250256
/* This part must be outside protection */
251257
#include <trace/define_trace.h>

0 commit comments

Comments
 (0)