#include <wrapper/poll.h>
#include <wrapper/file.h>
#include <wrapper/kref.h>
+#include <lttng-string-utils.h>
#include <lttng-abi.h>
#include <lttng-abi-old.h>
#include <lttng-events.h>
fops = <tng_metadata_fops;
break;
}
-
+
chan_file = anon_inode_getfile("[lttng_channel]",
fops,
NULL, O_RDWR);
*/
return -ENOSYS;
}
+ case RING_BUFFER_FLUSH_EMPTY: /* Fall-through. */
case RING_BUFFER_FLUSH:
{
struct lttng_metadata_stream *stream = filp->private_data;
return put_u64(stream->version, arg);
}
- case RING_BUFFER_SNAPSHOT:
- {
- /*
- * Force the buffer to quiescent so the ring buffer
- * don't attempt to perform a SWITCH_FLUSH, which would
- * desynchronize the client accounting of the amount of
- * data available in the buffer from the ring buffer
- * view.
- */
- buf->quiescent = true;
- break;
- }
default:
break;
}
*/
return -ENOSYS;
}
+ case RING_BUFFER_FLUSH_EMPTY: /* Fall-through. */
case RING_BUFFER_FLUSH:
{
struct lttng_metadata_stream *stream = filp->private_data;
return put_u64(stream->version, arg);
}
- case RING_BUFFER_SNAPSHOT:
- {
- /*
- * Force the buffer to quiescent so the ring buffer
- * don't attempt to perform a SWITCH_FLUSH, which would
- * desynchronize the client accounting of the amount of
- * data available in the buffer from the ring buffer
- * view.
- */
- buf->quiescent = true;
- break;
- }
default:
break;
}
|| event_param->instrumentation == LTTNG_KERNEL_SYSCALL) {
struct lttng_enabler *enabler;
- if (event_param->name[strlen(event_param->name) - 1] == '*') {
- enabler = lttng_enabler_create(LTTNG_ENABLER_WILDCARD,
+ if (strutils_is_star_glob_pattern(event_param->name)) {
+ /*
+ * If the event name is a star globbing pattern,
+ * we create the special star globbing enabler.
+ */
+ enabler = lttng_enabler_create(LTTNG_ENABLER_STAR_GLOB,
event_param, channel);
} else {
enabler = lttng_enabler_create(LTTNG_ENABLER_NAME,
lttng_clock_ref();
lttng_proc_dentry = proc_create_data("lttng", S_IRUSR | S_IWUSR, NULL,
<tng_fops, NULL);
-
+
if (!lttng_proc_dentry) {
printk(KERN_ERR "Error creating LTTng control file\n");
ret = -ENOMEM;