include/trace/events/v4l2.h
Source file repositories/reference/linux-study-clean/include/trace/events/v4l2.h
File Facts
- System
- Linux kernel
- Corpus path
include/trace/events/v4l2.h- Extension
.h- Size
- 9018 bytes
- Lines
- 269
- Domain
- Repository Root And Misc
- Bucket
- include
- Inferred role
- Repository Root And Misc: implementation source
- Status
- source implementation candidate
Why This File Exists
Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/tracepoint.hmedia/videobuf2-v4l2.htrace/define_trace.h
Detected Declarations
function EM
Annotated Snippet
#undef TRACE_SYSTEM
#define TRACE_SYSTEM v4l2
#if !defined(_TRACE_V4L2_H) || defined(TRACE_HEADER_MULTI_READ)
#define _TRACE_V4L2_H
#include <linux/tracepoint.h>
#include <media/videobuf2-v4l2.h>
/* Enums require being exported to userspace, for user tool parsing */
#undef EM
#undef EMe
#define EM(a, b) TRACE_DEFINE_ENUM(a);
#define EMe(a, b) TRACE_DEFINE_ENUM(a);
#define show_type(type) \
__print_symbolic(type, SHOW_TYPE)
#define SHOW_TYPE \
EM( V4L2_BUF_TYPE_VIDEO_CAPTURE, "VIDEO_CAPTURE" ) \
EM( V4L2_BUF_TYPE_VIDEO_OUTPUT, "VIDEO_OUTPUT" ) \
EM( V4L2_BUF_TYPE_VIDEO_OVERLAY, "VIDEO_OVERLAY" ) \
EM( V4L2_BUF_TYPE_VBI_CAPTURE, "VBI_CAPTURE" ) \
EM( V4L2_BUF_TYPE_VBI_OUTPUT, "VBI_OUTPUT" ) \
EM( V4L2_BUF_TYPE_SLICED_VBI_CAPTURE, "SLICED_VBI_CAPTURE" ) \
EM( V4L2_BUF_TYPE_SLICED_VBI_OUTPUT, "SLICED_VBI_OUTPUT" ) \
EM( V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY, "VIDEO_OUTPUT_OVERLAY" ) \
EM( V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE, "VIDEO_CAPTURE_MPLANE" ) \
EM( V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE, "VIDEO_OUTPUT_MPLANE" ) \
EM( V4L2_BUF_TYPE_SDR_CAPTURE, "SDR_CAPTURE" ) \
EM( V4L2_BUF_TYPE_SDR_OUTPUT, "SDR_OUTPUT" ) \
EM( V4L2_BUF_TYPE_META_CAPTURE, "META_CAPTURE" ) \
EMe(V4L2_BUF_TYPE_PRIVATE, "PRIVATE" )
SHOW_TYPE
#define show_field(field) \
__print_symbolic(field, SHOW_FIELD)
#define SHOW_FIELD \
EM( V4L2_FIELD_ANY, "ANY" ) \
EM( V4L2_FIELD_NONE, "NONE" ) \
EM( V4L2_FIELD_TOP, "TOP" ) \
EM( V4L2_FIELD_BOTTOM, "BOTTOM" ) \
EM( V4L2_FIELD_INTERLACED, "INTERLACED" ) \
EM( V4L2_FIELD_SEQ_TB, "SEQ_TB" ) \
EM( V4L2_FIELD_SEQ_BT, "SEQ_BT" ) \
EM( V4L2_FIELD_ALTERNATE, "ALTERNATE" ) \
EM( V4L2_FIELD_INTERLACED_TB, "INTERLACED_TB" ) \
EMe( V4L2_FIELD_INTERLACED_BT, "INTERLACED_BT" )
SHOW_FIELD
/*
* Now redefine the EM() and EMe() macros to map the enums to the strings
* that will be printed in the output.
*/
#undef EM
#undef EMe
#define EM(a, b) {a, b},
#define EMe(a, b) {a, b}
/* V4L2_TC_TYPE_* are macros, not defines, they do not need processing */
#define show_timecode_type(type) \
__print_symbolic(type, \
{ V4L2_TC_TYPE_24FPS, "24FPS" }, \
{ V4L2_TC_TYPE_25FPS, "25FPS" }, \
{ V4L2_TC_TYPE_30FPS, "30FPS" }, \
{ V4L2_TC_TYPE_50FPS, "50FPS" }, \
{ V4L2_TC_TYPE_60FPS, "60FPS" })
#define show_flags(flags) \
__print_flags(flags, "|", \
{ V4L2_BUF_FLAG_MAPPED, "MAPPED" }, \
{ V4L2_BUF_FLAG_QUEUED, "QUEUED" }, \
{ V4L2_BUF_FLAG_DONE, "DONE" }, \
{ V4L2_BUF_FLAG_KEYFRAME, "KEYFRAME" }, \
{ V4L2_BUF_FLAG_PFRAME, "PFRAME" }, \
{ V4L2_BUF_FLAG_BFRAME, "BFRAME" }, \
{ V4L2_BUF_FLAG_ERROR, "ERROR" }, \
{ V4L2_BUF_FLAG_TIMECODE, "TIMECODE" }, \
{ V4L2_BUF_FLAG_PREPARED, "PREPARED" }, \
{ V4L2_BUF_FLAG_NO_CACHE_INVALIDATE, "NO_CACHE_INVALIDATE" }, \
{ V4L2_BUF_FLAG_NO_CACHE_CLEAN, "NO_CACHE_CLEAN" }, \
{ V4L2_BUF_FLAG_TIMESTAMP_MASK, "TIMESTAMP_MASK" }, \
{ V4L2_BUF_FLAG_TIMESTAMP_UNKNOWN, "TIMESTAMP_UNKNOWN" }, \
{ V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC, "TIMESTAMP_MONOTONIC" }, \
{ V4L2_BUF_FLAG_TIMESTAMP_COPY, "TIMESTAMP_COPY" }, \
{ V4L2_BUF_FLAG_LAST, "LAST" })
Annotation
- Immediate include surface: `linux/tracepoint.h`, `media/videobuf2-v4l2.h`, `trace/define_trace.h`.
- Detected declarations: `function EM`.
- Atlas domain: Repository Root And Misc / include.
- 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.