projects
/
lttng-ust.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update tracepoint comments
[lttng-ust.git]
/
liblttng-ust
/
tracepoint.c
diff --git
a/liblttng-ust/tracepoint.c
b/liblttng-ust/tracepoint.c
index 8bf875281a97769ed26f2d96974343427f7aa314..1e252ce39d859fc10cc1766757db9ace908da7fe 100644
(file)
--- a/
liblttng-ust/tracepoint.c
+++ b/
liblttng-ust/tracepoint.c
@@
-21,16
+21,24
@@
#define _LGPL_SOURCE
#include <errno.h>
#define _LGPL_SOURCE
#include <errno.h>
-#include <
lttng/tracepo
int.h>
-#include <
lttng/tracepoint-internal
.h>
-#include <lttng/core.h>
-#include <
lttng/kcompat/kcompat
.h>
+#include <
std
int.h>
+#include <
stddef
.h>
+
+#include <
urcu/arch
.h>
#include <urcu-bp.h>
#include <urcu/hlist.h>
#include <urcu/uatomic.h>
#include <urcu-bp.h>
#include <urcu/hlist.h>
#include <urcu/uatomic.h>
+#include <urcu/compiler.h>
+
+#include <lttng/tracepoint.h>
-#include <lttng/usterr-signal-safe.h>
+#include <usterr-signal-safe.h>
+#include <helper.h>
+
+#include "tracepoint-internal.h"
#include "ltt-tracer-core.h"
#include "ltt-tracer-core.h"
+#include "jhash.h"
+#include "error.h"
/* Set to 1 to enable tracepoint debug output */
static const int tracepoint_debug;
/* Set to 1 to enable tracepoint debug output */
static const int tracepoint_debug;
@@
-89,7
+97,7
@@
static inline void *allocate_probes(int count)
static inline void release_probes(void *old)
{
if (old) {
static inline void release_probes(void *old)
{
if (old) {
- struct tp_probes *tp_probes =
_ust
_container_of(old,
+ struct tp_probes *tp_probes =
caa
_container_of(old,
struct tp_probes, probes[0]);
synchronize_rcu();
free(tp_probes);
struct tp_probes, probes[0]);
synchronize_rcu();
free(tp_probes);
@@
-196,7
+204,7
@@
static struct tracepoint_entry *get_tracepoint(const char *name)
struct cds_hlist_head *head;
struct cds_hlist_node *node;
struct tracepoint_entry *e;
struct cds_hlist_head *head;
struct cds_hlist_node *node;
struct tracepoint_entry *e;
- u
32
hash = jhash(name, strlen(name), 0);
+ u
int32_t
hash = jhash(name, strlen(name), 0);
head = &tracepoint_table[hash & (TRACEPOINT_TABLE_SIZE - 1)];
cds_hlist_for_each_entry(e, node, head, hlist) {
head = &tracepoint_table[hash & (TRACEPOINT_TABLE_SIZE - 1)];
cds_hlist_for_each_entry(e, node, head, hlist) {
@@
-216,7
+224,7
@@
static struct tracepoint_entry *add_tracepoint(const char *name)
struct cds_hlist_node *node;
struct tracepoint_entry *e;
size_t name_len = strlen(name) + 1;
struct cds_hlist_node *node;
struct tracepoint_entry *e;
size_t name_len = strlen(name) + 1;
- u
32
hash = jhash(name, name_len-1, 0);
+ u
int32_t
hash = jhash(name, name_len-1, 0);
head = &tracepoint_table[hash & (TRACEPOINT_TABLE_SIZE - 1)];
cds_hlist_for_each_entry(e, node, head, hlist) {
head = &tracepoint_table[hash & (TRACEPOINT_TABLE_SIZE - 1)];
cds_hlist_for_each_entry(e, node, head, hlist) {
@@
-411,7
+419,7
@@
static void tracepoint_add_old_probes(void *old)
{
need_update = 1;
if (old) {
{
need_update = 1;
if (old) {
- struct tp_probes *tp_probes =
_ust
_container_of(old,
+ struct tp_probes *tp_probes =
caa
_container_of(old,
struct tp_probes, probes[0]);
cds_list_add(&tp_probes->u.list, &old_probes);
}
struct tp_probes, probes[0]);
cds_list_add(&tp_probes->u.list, &old_probes);
}
@@
-487,7
+495,7
@@
void tracepoint_probe_update_all(void)
* Returns 0 if current not found.
* Returns 1 if current found.
*
* Returns 0 if current not found.
* Returns 1 if current found.
*
- * Called with
tracepoint mutex
held
+ * Called with
UST lock
held
*/
int lib_get_iter_tracepoints(struct tracepoint_iter *iter)
{
*/
int lib_get_iter_tracepoints(struct tracepoint_iter *iter)
{
@@
-519,7
+527,7
@@
int lib_get_iter_tracepoints(struct tracepoint_iter *iter)
* Returns whether a next tracepoint has been found (1) or not (0).
* Will return the first tracepoint in the range if the input tracepoint is
* NULL.
* Returns whether a next tracepoint has been found (1) or not (0).
* Will return the first tracepoint in the range if the input tracepoint is
* NULL.
- * Called with
tracepoint mutex
held.
+ * Called with
UST lock
held.
*/
int tracepoint_get_iter_range(struct tracepoint * const **tracepoint,
struct tracepoint * const *begin, struct tracepoint * const *end)
*/
int tracepoint_get_iter_range(struct tracepoint * const **tracepoint,
struct tracepoint * const *begin, struct tracepoint * const *end)
@@
-536,7
+544,7
@@
int tracepoint_get_iter_range(struct tracepoint * const **tracepoint,
}
/*
}
/*
- * Called with
tracepoint mutex
held.
+ * Called with
UST lock
held.
*/
static void tracepoint_get_iter(struct tracepoint_iter *iter)
{
*/
static void tracepoint_get_iter(struct tracepoint_iter *iter)
{
@@
-565,7
+573,7
@@
void tracepoint_iter_next(struct tracepoint_iter *iter)
/*
* iter->tracepoint may be invalid because we blindly incremented it.
* Make sure it is valid by marshalling on the tracepoints, getting the
/*
* iter->tracepoint may be invalid because we blindly incremented it.
* Make sure it is valid by marshalling on the tracepoints, getting the
- * tracepoints from following
modules
if necessary.
+ * tracepoints from following
library
if necessary.
*/
tracepoint_get_iter(iter);
}
*/
tracepoint_get_iter(iter);
}
This page took
0.037662 seconds
and
4
git commands to generate.