diff options
Diffstat (limited to 'include/uapi/linux/perf_event.h')
| -rw-r--r-- | include/uapi/linux/perf_event.h | 37 |
1 files changed, 31 insertions, 6 deletions
diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h index 009a655a5d35..e1802d6153ae 100644 --- a/include/uapi/linux/perf_event.h +++ b/include/uapi/linux/perf_event.h | |||
| @@ -136,8 +136,9 @@ enum perf_event_sample_format { | |||
| 136 | PERF_SAMPLE_WEIGHT = 1U << 14, | 136 | PERF_SAMPLE_WEIGHT = 1U << 14, |
| 137 | PERF_SAMPLE_DATA_SRC = 1U << 15, | 137 | PERF_SAMPLE_DATA_SRC = 1U << 15, |
| 138 | PERF_SAMPLE_IDENTIFIER = 1U << 16, | 138 | PERF_SAMPLE_IDENTIFIER = 1U << 16, |
| 139 | PERF_SAMPLE_TRANSACTION = 1U << 17, | ||
| 139 | 140 | ||
| 140 | PERF_SAMPLE_MAX = 1U << 17, /* non-ABI */ | 141 | PERF_SAMPLE_MAX = 1U << 18, /* non-ABI */ |
| 141 | }; | 142 | }; |
| 142 | 143 | ||
| 143 | /* | 144 | /* |
| @@ -181,6 +182,28 @@ enum perf_sample_regs_abi { | |||
| 181 | }; | 182 | }; |
| 182 | 183 | ||
| 183 | /* | 184 | /* |
| 185 | * Values for the memory transaction event qualifier, mostly for | ||
| 186 | * abort events. Multiple bits can be set. | ||
| 187 | */ | ||
| 188 | enum { | ||
| 189 | PERF_TXN_ELISION = (1 << 0), /* From elision */ | ||
| 190 | PERF_TXN_TRANSACTION = (1 << 1), /* From transaction */ | ||
| 191 | PERF_TXN_SYNC = (1 << 2), /* Instruction is related */ | ||
| 192 | PERF_TXN_ASYNC = (1 << 3), /* Instruction not related */ | ||
| 193 | PERF_TXN_RETRY = (1 << 4), /* Retry possible */ | ||
| 194 | PERF_TXN_CONFLICT = (1 << 5), /* Conflict abort */ | ||
| 195 | PERF_TXN_CAPACITY_WRITE = (1 << 6), /* Capacity write abort */ | ||
| 196 | PERF_TXN_CAPACITY_READ = (1 << 7), /* Capacity read abort */ | ||
| 197 | |||
| 198 | PERF_TXN_MAX = (1 << 8), /* non-ABI */ | ||
| 199 | |||
| 200 | /* bits 32..63 are reserved for the abort code */ | ||
| 201 | |||
| 202 | PERF_TXN_ABORT_MASK = (0xffffffffULL << 32), | ||
| 203 | PERF_TXN_ABORT_SHIFT = 32, | ||
| 204 | }; | ||
| 205 | |||
| 206 | /* | ||
| 184 | * The format of the data returned by read() on a perf event fd, | 207 | * The format of the data returned by read() on a perf event fd, |
| 185 | * as specified by attr.read_format: | 208 | * as specified by attr.read_format: |
| 186 | * | 209 | * |
| @@ -456,13 +479,15 @@ struct perf_event_mmap_page { | |||
| 456 | /* | 479 | /* |
| 457 | * Control data for the mmap() data buffer. | 480 | * Control data for the mmap() data buffer. |
| 458 | * | 481 | * |
| 459 | * User-space reading the @data_head value should issue an rmb(), on | 482 | * User-space reading the @data_head value should issue an smp_rmb(), |
| 460 | * SMP capable platforms, after reading this value -- see | 483 | * after reading this value. |
| 461 | * perf_event_wakeup(). | ||
| 462 | * | 484 | * |
| 463 | * When the mapping is PROT_WRITE the @data_tail value should be | 485 | * When the mapping is PROT_WRITE the @data_tail value should be |
| 464 | * written by userspace to reflect the last read data. In this case | 486 | * written by userspace to reflect the last read data, after issueing |
| 465 | * the kernel will not over-write unread data. | 487 | * an smp_mb() to separate the data read from the ->data_tail store. |
| 488 | * In this case the kernel will not over-write unread data. | ||
| 489 | * | ||
| 490 | * See perf_output_put_handle() for the data ordering. | ||
| 466 | */ | 491 | */ |
| 467 | __u64 data_head; /* head in the data section */ | 492 | __u64 data_head; /* head in the data section */ |
| 468 | __u64 data_tail; /* user-space written tail */ | 493 | __u64 data_tail; /* user-space written tail */ |
