#include "../ltt-events.h"
#include "../wrapper/ringbuffer/frontend_types.h"
#include "../wrapper/ftrace.h"
+#include "../wrapper/vmalloc.h"
#include "../ltt-tracer.h"
static
if (!event->u.ftrace.symbol_name)
goto name_error;
+ /* Ensure the memory we just allocated don't trigger page faults */
+ wrapper_vmalloc_sync_all();
+
ret = wrapper_register_ftrace_function_probe(event->u.ftrace.symbol_name,
<tng_ftrace_ops, event);
if (ret)
/* This module is permanent. */
int lttng_ftrace_init(void)
{
+ wrapper_vmalloc_sync_all();
return 0;
}
module_init(lttng_ftrace_init)
#include <linux/slab.h>
#include "../ltt-events.h"
#include "../wrapper/ringbuffer/frontend_types.h"
+#include "../wrapper/vmalloc.h"
#include "../ltt-tracer.h"
static
event->u.kprobe.symbol_name;
event->u.kprobe.kp.offset = offset;
event->u.kprobe.kp.addr = (void *) addr;
+
+ /*
+ * Ensure the memory we just allocated don't trigger page faults.
+ * Well.. kprobes itself puts the page fault handler on the blacklist,
+ * but we can never be too careful.
+ */
+ wrapper_vmalloc_sync_all();
+
ret = register_kprobe(&event->u.kprobe.kp);
if (ret)
goto register_error;