X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=include%2Flttng%2Flttng-bytecode.h;h=f104b0ebfdf0ff4043eb82496d4cf216f5052565;hb=f00168b56ad642e0369c03b8cd730be85dc46188;hp=cd0d8fbedc81542b55004e04826fbc29aaf5cda0;hpb=1efb0502c7dbf2487fb973636bba7f8ca3f4a5eb;p=lttng-modules.git diff --git a/include/lttng/lttng-bytecode.h b/include/lttng/lttng-bytecode.h index cd0d8fbe..f104b0eb 100644 --- a/include/lttng/lttng-bytecode.h +++ b/include/lttng/lttng-bytecode.h @@ -42,7 +42,7 @@ struct bytecode_runtime { size_t data_alloc_len; char *data; uint16_t len; - char code[0]; + char code[]; }; enum entry_type { @@ -102,6 +102,7 @@ struct bytecode_get_index_data { size_t len; enum object_type type; bool rev_bo; /* reverse byte order */ + bool user; /* from userspace */ } elem; }; @@ -111,6 +112,7 @@ struct vstack_load { enum object_type object_type; const struct lttng_kernel_event_field *field; bool rev_bo; /* reverse byte order */ + bool user; /* from userspace */ }; struct vstack_entry { @@ -180,6 +182,7 @@ struct load_ptr { const void *ptr; size_t nr_elem; bool rev_bo; + bool user; /* from userspace */ /* Temporary place-holders for contexts. */ union { int64_t s64; @@ -199,7 +202,7 @@ struct estack_entry { const char __user *user_str; size_t seq_len; enum estack_string_literal_type literal_type; - int user; /* is string from userspace ? */ + bool user; /* is string from userspace ? */ } s; struct load_ptr ptr; } u; @@ -271,7 +274,9 @@ struct lttng_interpreter_output { struct { const char *str; + const char __user *user_str; size_t len; + bool user; /* is string from userspace ? */ } str; struct { const void *ptr; @@ -287,6 +292,7 @@ const char *lttng_bytecode_print_op(enum bytecode_op op); void lttng_bytecode_sync_state(struct lttng_kernel_bytecode_runtime *runtime); int lttng_bytecode_validate(struct bytecode_runtime *bytecode); +int lttng_bytecode_validate_load(struct bytecode_runtime *bytecode); int lttng_bytecode_specialize(const struct lttng_kernel_event_desc *event_desc, struct bytecode_runtime *bytecode);