else
KERNELDIR ?= /lib/modules/$(shell uname -r)/build
PWD := $(shell pwd)
+ CFLAGS = $(EXTCFLAGS)
default:
$(MAKE) -C $(KERNELDIR) M=$(PWD) modules
__init int ltt_ascii_init(void)
{
ltt_ascii_dir_dentry = debugfs_create_dir(LTT_ASCII, get_ltt_root());
- put_ltt_root();
return ltt_ascii_dir_dentry ? 0 : -EFAULT;
}
__exit void ltt_ascii_exit(void)
{
debugfs_remove(ltt_ascii_dir_dentry);
+ put_ltt_root();
}
MODULE_LICENSE("GPL and additional rights");
ltt_run_filter = ltt_run_filter_default;
}
EXPORT_SYMBOL_GPL(ltt_filter_unregister);
+
+MODULE_LICENSE("GPL and additional rights");
+MODULE_AUTHOR("Mathieu Desnoyers");
+MODULE_DESCRIPTION("Linux Trace Toolkit Next Generation Tracer Core");
struct ltt_chan *chan = container_of(buf->a.chan, struct ltt_chan, a);
ltt_relay_print_buffer_errors(chan, buf->a.cpu);
-#ifdef CONFIG_LTT_VMCORE
+#ifdef LTT_VMCORE
kfree(buf->commit_seq);
#endif
kfree(buf->commit_count);
goto free_chanbuf;
}
-#ifdef CONFIG_LTT_VMCORE
+#ifdef LTT_VMCORE
buf->commit_seq =
kzalloc_node(ALIGN(sizeof(*buf->commit_seq) * chan->a.n_sb,
1 << INTERNODE_CACHE_SHIFT),
/* Error handling */
free_init:
-#ifdef CONFIG_LTT_VMCORE
+#ifdef LTT_VMCORE
kfree(buf->commit_seq);
free_commit:
#endif
* Last timestamp written in the buffer.
*/
/* End of first 32 bytes cacheline */
-#ifdef CONFIG_LTT_VMCORE
+#ifdef LTT_VMCORE
local_t *commit_seq; /* Consecutive commits */
#endif
atomic_long_t active_readers; /*
consumed_new) != consumed_old));
}
-#ifdef CONFIG_LTT_VMCORE
+#ifdef LTT_VMCORE
static __inline__
void ltt_vmcore_check_deliver(struct ltt_chanbuf *buf, long commit_count,
long idx)
*tsc = trace_clock_read64();
-#ifdef CONFIG_LTT_VMCORE
+#ifdef LTT_VMCORE
prefetch(&buf->commit_count[SUBBUF_INDEX(*o_begin, chan)]);
prefetch(&buf->commit_seq[SUBBUF_INDEX(*o_begin, chan)]);
#else
* commit count reaches back the reserve offset (module subbuffer size). It is
* useful for crash dump.
*/
-#ifdef CONFIG_LTT_VMCORE
+#ifdef LTT_VMCORE
static __inline__
void ltt_write_commit_counter(struct ltt_chanbuf *buf, struct ltt_chan *chan,
long idx, long buf_offset, long commit_count,
continue;
if (unlikely(!ltt_run_filter(trace, eID)))
continue;
-#ifdef CONFIG_LTT_DEBUG_EVENT_SIZE
+#ifdef LTT_DEBUG_EVENT_SIZE
rflags = LTT_RFLAG_ID_SIZE;
#else
if (unlikely(eID >= LTT_FREE_EVENTS))
continue;
if (unlikely(!ltt_run_filter(trace, eID)))
continue;
-#ifdef CONFIG_LTT_DEBUG_EVENT_SIZE
+#ifdef LTT_DEBUG_EVENT_SIZE
rflags = LTT_RFLAG_ID_SIZE;
#else
if (unlikely(eID >= LTT_FREE_EVENTS))