EXPORT_SYMBOL_GPL(us_proc_info);
EXPORT_SYMBOL_GPL(dex_proc_info);
+typedef void *(*get_my_uprobes_info_t)(void);
int (*mec_post_event)(char *data, unsigned long len) = NULL;
unsigned copy_into_cyclic_buffer (char *buffer, unsigned dst_offset, char *src, unsigned size)
int link_bundle()
{
- inst_us_proc_t *my_uprobes_info;
+ get_my_uprobes_info_t get_uprobes = NULL;
+ inst_us_proc_t *my_uprobes_info = 0;
inst_us_proc_t empty_uprobes_info =
{
.libs_count = 0,
int handler_index;
/* Get user-defined us handlers (if they are provided) */
- my_uprobes_info = (inst_us_proc_t *)lookup_name("my_uprobes_info");
+ get_uprobes = (get_my_uprobes_info_t)lookup_name("get_my_uprobes_info");
+ if (get_uprobes)
+ my_uprobes_info = (inst_us_proc_t *)get_uprobes();
+
if (my_uprobes_info == 0)
my_uprobes_info = &empty_uprobes_info;
{
int i, k, size = 0, probe_size, result, j;
char *buf, *sep1, *sep2;
+ get_my_uprobes_info_t get_uprobes = NULL;
+ inst_us_proc_t *my_uprobes_info = NULL;
+
+ get_uprobes = (get_my_uprobes_info_t)lookup_name("get_my_uprobes_info");
+ if (get_uprobes)
+ my_uprobes_info = (inst_us_proc_t *)get_uprobes();
- inst_us_proc_t *my_uprobes_info = (inst_us_proc_t *)lookup_name("my_uprobes_info");
DPRINTF("my_uprobes_info lookup result: 0x%p", my_uprobes_info);
inst_us_proc_t empty_uprobes_info =
{
int get_predef_uprobes_size(int *size)
{
int i, k;
+ get_my_uprobes_info_t get_uprobes = NULL;
+ inst_us_proc_t *my_uprobes_info = NULL;
+
+ get_uprobes = (get_my_uprobes_info_t)lookup_name("get_my_uprobes_info");
+ if (get_uprobes)
+ my_uprobes_info = (inst_us_proc_t *)get_uprobes();
- inst_us_proc_t *my_uprobes_info = (inst_us_proc_t *)lookup_name("my_uprobes_info");
inst_us_proc_t empty_uprobes_info =
{
.libs_count = 0,
int i, k, size, lib_size, func_size, result;
unsigned count = 0;
char sep[] = ":";
+ get_my_uprobes_info_t get_uprobes = NULL;
+ inst_us_proc_t *my_uprobes_info = NULL;
+
+ get_uprobes = (get_my_uprobes_info_t)lookup_name("get_my_uprobes_info");
+ if (get_uprobes)
+ my_uprobes_info = (inst_us_proc_t *)get_uprobes();
- inst_us_proc_t *my_uprobes_info = (inst_us_proc_t *)lookup_name("my_uprobes_info");
inst_us_proc_t empty_uprobes_info =
{
.libs_count = 0,