projects
/
lttng-modules.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Refactoring: kretprobes: use event common argument types
[lttng-modules.git]
/
src
/
lttng-ring-buffer-metadata-client.h
diff --git
a/src/lttng-ring-buffer-metadata-client.h
b/src/lttng-ring-buffer-metadata-client.h
index 6c7f64c244cd6a241cdf9611a37eb8ae0b3923de..763ebaf1274592a3dd5c665491ad81f59fb31c75 100644
(file)
--- a/
src/lttng-ring-buffer-metadata-client.h
+++ b/
src/lttng-ring-buffer-metadata-client.h
@@
-326,15
+326,17
@@
void lttng_event_commit(struct lttng_kernel_ring_buffer_ctx *ctx)
static
void lttng_event_write(struct lttng_kernel_ring_buffer_ctx *ctx, const void *src,
static
void lttng_event_write(struct lttng_kernel_ring_buffer_ctx *ctx, const void *src,
- size_t len)
+ size_t len
, size_t alignment
)
{
{
+ lib_ring_buffer_align_ctx(ctx, alignment);
lib_ring_buffer_write(&client_config, ctx, src, len);
}
static
void lttng_event_write_from_user(struct lttng_kernel_ring_buffer_ctx *ctx,
lib_ring_buffer_write(&client_config, ctx, src, len);
}
static
void lttng_event_write_from_user(struct lttng_kernel_ring_buffer_ctx *ctx,
- const void __user *src, size_t len)
+ const void __user *src, size_t len
, size_t alignment
)
{
{
+ lib_ring_buffer_align_ctx(ctx, alignment);
lib_ring_buffer_copy_from_user_inatomic(&client_config, ctx, src, len);
}
lib_ring_buffer_copy_from_user_inatomic(&client_config, ctx, src, len);
}
@@
-352,6
+354,13
@@
void lttng_event_strcpy(struct lttng_kernel_ring_buffer_ctx *ctx, const char *sr
lib_ring_buffer_strcpy(&client_config, ctx, src, len, '#');
}
lib_ring_buffer_strcpy(&client_config, ctx, src, len, '#');
}
+static
+void lttng_event_pstrcpy_pad(struct lttng_kernel_ring_buffer_ctx *ctx, const char *src,
+ size_t len)
+{
+ lib_ring_buffer_pstrcpy(&client_config, ctx, src, len, '\0');
+}
+
static
size_t lttng_packet_avail_size(struct lttng_kernel_ring_buffer_channel *chan)
{
static
size_t lttng_packet_avail_size(struct lttng_kernel_ring_buffer_channel *chan)
{
@@
-427,6
+436,7
@@
static struct lttng_transport lttng_relay_transport = {
.event_memset = lttng_event_memset,
.event_write = lttng_event_write,
.event_strcpy = lttng_event_strcpy,
.event_memset = lttng_event_memset,
.event_write = lttng_event_write,
.event_strcpy = lttng_event_strcpy,
+ .event_pstrcpy_pad = lttng_event_pstrcpy_pad,
},
};
},
};
This page took
0.023796 seconds
and
4
git commands to generate.