tools/testing/selftests/powerpc/pmu/event.h
Source file repositories/reference/linux-study-clean/tools/testing/selftests/powerpc/pmu/event.h
File Facts
- System
- Linux kernel
- Corpus path
tools/testing/selftests/powerpc/pmu/event.h- Extension
.h- Size
- 1398 bytes
- Lines
- 50
- Domain
- Support Tooling And Documentation
- Bucket
- tools
- Inferred role
- Support Tooling And Documentation: implementation source
- Status
- source implementation candidate
Why This File Exists
Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
unistd.hlinux/perf_event.hutils.h
Detected Declarations
struct event
Annotated Snippet
struct event {
struct perf_event_attr attr;
char *name;
int fd;
/* This must match the read_format we use */
struct {
u64 value;
u64 running;
u64 enabled;
} result;
/*
* mmap buffer used while recording sample.
* Accessed as "struct perf_event_mmap_page"
*/
void *mmap_buffer;
};
void event_init(struct event *e, u64 config);
void event_init_named(struct event *e, u64 config, char *name);
void event_init_opts(struct event *e, u64 config, int type, char *name);
void event_init_sampling(struct event *e, u64 config);
int event_open_with_options(struct event *e, pid_t pid, int cpu, int group_fd);
int event_open_with_group(struct event *e, int group_fd);
int event_open_with_pid(struct event *e, pid_t pid);
int event_open_with_cpu(struct event *e, int cpu);
int event_open(struct event *e);
void event_close(struct event *e);
int event_enable(struct event *e);
int event_disable(struct event *e);
int event_reset(struct event *e);
int event_read(struct event *e);
void event_report_justified(struct event *e, int name_width, int result_width);
void event_report(struct event *e);
#endif /* _SELFTESTS_POWERPC_PMU_EVENT_H */
Annotation
- Immediate include surface: `unistd.h`, `linux/perf_event.h`, `utils.h`.
- Detected declarations: `struct event`.
- Atlas domain: Support Tooling And Documentation / tools.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.