projects
/
lttng-modules.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Namespace kernel version macros
[lttng-modules.git]
/
lttng-context-perf-counters.c
diff --git
a/lttng-context-perf-counters.c
b/lttng-context-perf-counters.c
index 260e5d0d9a5873cef635b93bbc93548d70104a46..bc3121d88fe071751bfd9ac172ba159682d6eebd 100644
(file)
--- a/
lttng-context-perf-counters.c
+++ b/
lttng-context-perf-counters.c
@@
-72,7
+72,7
@@
void perf_counter_record(struct lttng_ctx_field *field,
chan->ops->event_write(ctx, &value, sizeof(value));
}
chan->ops->event_write(ctx, &value, sizeof(value));
}
-#if defined(CONFIG_PERF_EVENTS) && (L
INUX_VERSION_CODE >=
KERNEL_VERSION(3,0,99))
+#if defined(CONFIG_PERF_EVENTS) && (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(3,0,99))
static
void overflow_callback(struct perf_event *event,
struct perf_sample_data *data,
static
void overflow_callback(struct perf_event *event,
struct perf_sample_data *data,
@@
-93,7
+93,7
@@
void lttng_destroy_perf_counter_field(struct lttng_ctx_field *field)
{
struct perf_event **events = field->u.perf_counter->e;
{
struct perf_event **events = field->u.perf_counter->e;
-#if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0))
+#if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0))
{
int ret;
{
int ret;
@@
-104,7
+104,7
@@
void lttng_destroy_perf_counter_field(struct lttng_ctx_field *field)
&field->u.perf_counter->cpuhp_prepare.node);
WARN_ON(ret);
}
&field->u.perf_counter->cpuhp_prepare.node);
WARN_ON(ret);
}
-#else /* #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#else /* #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
{
int cpu;
{
int cpu;
@@
-116,14
+116,14
@@
void lttng_destroy_perf_counter_field(struct lttng_ctx_field *field)
unregister_cpu_notifier(&field->u.perf_counter->nb);
#endif
}
unregister_cpu_notifier(&field->u.perf_counter->nb);
#endif
}
-#endif /* #else #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#endif /* #else #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
kfree(field->event_field.name);
kfree(field->u.perf_counter->attr);
lttng_kvfree(events);
kfree(field->u.perf_counter);
}
kfree(field->event_field.name);
kfree(field->u.perf_counter->attr);
lttng_kvfree(events);
kfree(field->u.perf_counter);
}
-#if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0))
+#if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0))
int lttng_cpuhp_perf_counter_online(unsigned int cpu,
struct lttng_cpuhp_node *node)
int lttng_cpuhp_perf_counter_online(unsigned int cpu,
struct lttng_cpuhp_node *node)
@@
-164,7
+164,7
@@
int lttng_cpuhp_perf_counter_dead(unsigned int cpu,
return 0;
}
return 0;
}
-#else /* #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#else /* #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
#ifdef CONFIG_HOTPLUG_CPU
#ifdef CONFIG_HOTPLUG_CPU
@@
-223,7
+223,7
@@
int lttng_perf_counter_cpu_hp_callback(struct notifier_block *nb,
#endif
#endif
-#endif /* #else #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#endif /* #else #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
int lttng_add_perf_counter_to_ctx(uint32_t type,
uint64_t config,
int lttng_add_perf_counter_to_ctx(uint32_t type,
uint64_t config,
@@
-277,7
+277,7
@@
int lttng_add_perf_counter_to_ctx(uint32_t type,
goto find_error;
}
goto find_error;
}
-#if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0))
+#if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0))
perf_field->cpuhp_prepare.component = LTTNG_CONTEXT_PERF_COUNTERS;
ret = cpuhp_state_add_instance(lttng_hp_prepare,
perf_field->cpuhp_prepare.component = LTTNG_CONTEXT_PERF_COUNTERS;
ret = cpuhp_state_add_instance(lttng_hp_prepare,
@@
-291,7
+291,7
@@
int lttng_add_perf_counter_to_ctx(uint32_t type,
if (ret)
goto cpuhp_online_error;
if (ret)
goto cpuhp_online_error;
-#else /* #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#else /* #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
{
int cpu;
{
int cpu;
@@
-317,7
+317,7
@@
int lttng_add_perf_counter_to_ctx(uint32_t type,
put_online_cpus();
perf_field->hp_enable = 1;
}
put_online_cpus();
perf_field->hp_enable = 1;
}
-#endif /* #else #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#endif /* #else #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
field->destroy = lttng_destroy_perf_counter_field;
field->destroy = lttng_destroy_perf_counter_field;
@@
-337,7
+337,7
@@
int lttng_add_perf_counter_to_ctx(uint32_t type,
wrapper_vmalloc_sync_all();
return 0;
wrapper_vmalloc_sync_all();
return 0;
-#if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0))
+#if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0))
cpuhp_online_error:
{
int remove_ret;
cpuhp_online_error:
{
int remove_ret;
@@
-347,7
+347,7
@@
cpuhp_online_error:
WARN_ON(remove_ret);
}
cpuhp_prepare_error:
WARN_ON(remove_ret);
}
cpuhp_prepare_error:
-#else /* #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#else /* #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
counter_busy:
counter_error:
{
counter_busy:
counter_error:
{
@@
-362,7
+362,7
@@
counter_error:
unregister_cpu_notifier(&perf_field->nb);
#endif
}
unregister_cpu_notifier(&perf_field->nb);
#endif
}
-#endif /* #else #if (L
INUX_VERSION_CODE >=
KERNEL_VERSION(4,10,0)) */
+#endif /* #else #if (L
TTNG_LINUX_VERSION_CODE >= LTTNG_
KERNEL_VERSION(4,10,0)) */
find_error:
lttng_remove_context_field(ctx, field);
append_context_error:
find_error:
lttng_remove_context_field(ctx, field);
append_context_error:
This page took
0.025678 seconds
and
4
git commands to generate.