*/
String fieldHRtimerNow();
+ /**
+ * The field containing the return value of a system call exit.
+ *
+ * @return The name of return field
+ * @since 2.0
+ */
+ default String fieldSyscallRet() {
+ return "ret"; //$NON-NLS-1$
+ }
+
+ // ------------------------------------------------------------------------
+ // I/O events and fields
+ // ------------------------------------------------------------------------
+
+ /**
+ * A request to a block IO has just been inserted in the waiting queue.
+ *
+ * @return The name of the event
+ * @since 2.0
+ */
+ default String eventBlockRqInsert() {
+ return "block_rq_insert"; //$NON-NLS-1$
+ }
+
+ /**
+ * A request to a block IO has just been issued and passed from the waiting
+ * queue to the driver queue. It is being served.
+ *
+ * @return The name of the event
+ * @since 2.0
+ */
+ default String eventBlockRqIssue() {
+ return "block_rq_issue"; //$NON-NLS-1$
+ }
+
+ /**
+ * A request to a block IO has just been completed.
+ *
+ * @return The name of the event
+ * @since 2.0
+ */
+ default String eventBlockRqComplete() {
+ return "block_rq_complete"; //$NON-NLS-1$
+ }
+
+ /**
+ * A BIO operation is being merged at the front of a waiting request
+ *
+ * @return The name of the event
+ * @since 2.0
+ */
+ default String eventBlockBioFrontmerge() {
+ return "block_bio_frontmerge"; //$NON-NLS-1$
+ }
+
+ /**
+ * A BIO operation is being merged at the back of a waiting request
+ *
+ * @return The name of the event
+ * @since 2.0
+ */
+ default String eventBlockBioBackmerge() {
+ return "block_bio_backmerge"; //$NON-NLS-1$
+ }
+
+ /**
+ * 2 requests previously inserted in the waiting queue are being merged
+ *
+ * @return The name of the event
+ * @since 2.0
+ */
+ default String eventBlockRqMerge() {
+ return "block_rq_merge"; //$NON-NLS-1$
+ }
+
+ /**
+ * Optional event used by some tracers to associate the name of the block
+ * device to a device ID
+ *
+ * @return The name of the event
+ * @since 2.0
+ */
+ default @Nullable String eventStatedumpBlockDevice() {
+ return null;
+ }
+
+ /**
+ * The field containing the device ID
+ *
+ * @return The name of the field
+ * @since 2.0
+ */
+ default String fieldBlockDeviceId() {
+ return "dev"; //$NON-NLS-1$
+ }
+
+ /**
+ * The field with the first sector of a block operation
+ *
+ * @return The name of the field
+ * @since 2.0
+ */
+ default String fieldBlockSector() {
+ return "sector"; //$NON-NLS-1$
+ }
+
+ /**
+ * The field with the number of sectors involved in a block operation
+ *
+ * @return The name of the field
+ * @since 2.0
+ */
+ default String fieldBlockNrSector() {
+ return "nr_sector"; //$NON-NLS-1$
+ }
+
+ /**
+ * The field containing the read/write flag of a block operation
+ *
+ * @return The name of the field
+ * @since 2.0
+ */
+ default String fieldBlockRwbs() {
+ return "rwbs"; //$NON-NLS-1$
+ }
+
+ /**
+ * The field with the first sector of a request in which another block
+ * operation is being merged
+ *
+ * @return The name of the field
+ * @since 2.0
+ */
+ default String fieldBlockRqSector() {
+ return "rq_sector"; //$NON-NLS-1$
+ }
+
+ /**
+ * The field with the sector of the request being merged in another one
+ *
+ * @return The name of the field
+ * @since 2.0
+ */
+ default String fieldBlockNextRqSector() {
+ return "nextrq_sector"; //$NON-NLS-1$
+ }
+
+ /**
+ * The field containing the name of the disk
+ *
+ * @return The name of the field
+ * @since 2.0
+ */
+ default String fieldDiskname() {
+ return "diskname"; //$NON-NLS-1$
+ }
+
}
private static final String COMPAT_SYSCALL_ENTRY_PREFIX = "compat_sys_";
private static final String SYSCALL_EXIT_PREFIX = "exit_syscall";
+ private static final String BLOCK_RQ_INSERT= "block_rq_insert";
+ private static final String BLOCK_RQ_ISSUE= "block_rq_issue";
+ private static final String ELV_MERGE_REQUESTS= "addons_elv_merge_requests";
+ private static final String BLOCK_RQ_COMPLETE= "block_rq_complete";
+ private static final String LTTNG_STATEDUMP_BLOCK_DEVICE= "lttng_statedump_block_device";
+ private static final String BLOCK_BIO_FRONTMERGE = "block_bio_frontmerge";
+ private static final String BLOCK_BIO_BACKMERGE = "block_bio_backmerge";
+
/* Field names */
private static final String IRQ = "irq";
private static final String TID = "tid";
private static final String HRTIMER_SOFT_EXPIRES = "softexpires";
private static final String KMEM_ALLOC = "mm_page_alloc";
private static final String KMEM_FREE = "mm_page_free";
+ private static final String SYSCALL_RET = "ret";
+ private static final String RWBS="rwbs";
+ private static final String DISKNAME="diskname";
+ private static final String BLOCK_DEV="dev";
+ private static final String SECTOR="sector";
+ private static final String NR_SECTOR="nr_sector";
+ private static final String RQ_SECTOR= "rq_sector";
+ private static final String NEXTRQ_SECTOR= "nextrq_sector";
/** All instances are the same. Only provide a static instance getter */
protected LttngEventLayout() {
return HRTIMER_NOW;
}
+ @Override
+ public String fieldSyscallRet() {
+ return SYSCALL_RET;
+ }
+
+ // ------------------------------------------------------------------------
+ // I/O events and fields
+ // ------------------------------------------------------------------------
+
+ @Override
+ public String eventBlockRqInsert() {
+ return BLOCK_RQ_INSERT;
+ }
+
+ @Override
+ public String eventBlockRqIssue() {
+ return BLOCK_RQ_ISSUE;
+ }
+
+ @Override
+ public String eventBlockRqComplete() {
+ return BLOCK_RQ_COMPLETE;
+ }
+
+ @Override
+ public String eventBlockBioFrontmerge() {
+ return BLOCK_BIO_FRONTMERGE;
+ }
+
+ @Override
+ public String eventBlockBioBackmerge() {
+ return BLOCK_BIO_BACKMERGE;
+ }
+
+ @Override
+ public String eventBlockRqMerge() {
+ return ELV_MERGE_REQUESTS;
+ }
+
+ @Override
+ public @NonNull String eventStatedumpBlockDevice() {
+ return LTTNG_STATEDUMP_BLOCK_DEVICE;
+ }
+
+ @Override
+ public String fieldBlockDeviceId() {
+ return BLOCK_DEV;
+ }
+
+ @Override
+ public String fieldBlockSector() {
+ return SECTOR;
+ }
+
+ @Override
+ public String fieldBlockNrSector() {
+ return NR_SECTOR;
+ }
+
+ @Override
+ public String fieldBlockRwbs() {
+ return RWBS;
+ }
+
+ @Override
+ public String fieldBlockRqSector() {
+ return RQ_SECTOR;
+ }
+
+ @Override
+ public String fieldBlockNextRqSector() {
+ return NEXTRQ_SECTOR;
+ }
+
+ @Override
+ public String fieldDiskname() {
+ return DISKNAME;
+ }
+
}
public String fieldHRtimerNow() {
return "now"; //$NON-NLS-1$
}
+
+ // ------------------------------------------------------------------------
+ // I/O events and fields
+ // ------------------------------------------------------------------------
+
+ @Override
+ public String eventBlockRqInsert() {
+ return "block:block_rq_insert"; //$NON-NLS-1$
+ }
+
+ @Override
+ public String eventBlockRqIssue() {
+ return "block:block_rq_issue"; //$NON-NLS-1$
+ }
+
+ @Override
+ public String eventBlockRqComplete() {
+ return "block:block_rq_complete"; //$NON-NLS-1$
+ }
+
+ @Override
+ public String eventBlockBioFrontmerge() {
+ return "block:block_bio_frontmerge"; //$NON-NLS-1$
+ }
+
+ @Override
+ public String eventBlockBioBackmerge() {
+ return "block:block_bio_backmerge"; //$NON-NLS-1$
+ }
+
}