drivers/media/test-drivers/visl/visl.h
Source file repositories/reference/linux-study-clean/drivers/media/test-drivers/visl/visl.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/media/test-drivers/visl/visl.h- Extension
.h- Size
- 4519 bytes
- Lines
- 174
- Domain
- Driver Families
- Bucket
- drivers/media
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/debugfs.hlinux/list.hmedia/v4l2-ctrls.hmedia/v4l2-device.hmedia/tpg/v4l2-tpg.h
Detected Declarations
struct visl_ctrlsstruct visl_coded_format_descstruct visl_q_datastruct visl_devstruct visl_blobstruct visl_ctxstruct visl_ctrl_descenum visl_codec
Annotated Snippet
struct visl_ctrls {
const struct visl_ctrl_desc *ctrls;
unsigned int num_ctrls;
};
struct visl_coded_format_desc {
u32 pixelformat;
struct v4l2_frmsize_stepwise frmsize;
const struct visl_ctrls *ctrls;
unsigned int num_decoded_fmts;
const u32 *decoded_fmts;
};
extern const struct visl_coded_format_desc visl_coded_fmts[];
extern const size_t num_coded_fmts;
enum {
V4L2_M2M_SRC = 0,
V4L2_M2M_DST = 1,
};
extern unsigned int visl_debug;
#define dprintk(dev, fmt, arg...) \
v4l2_dbg(1, visl_debug, &(dev)->v4l2_dev, "%s: " fmt, __func__, ## arg)
extern int visl_dprintk_frame_start;
extern unsigned int visl_dprintk_nframes;
extern bool keep_bitstream_buffers;
extern int bitstream_trace_frame_start;
extern unsigned int bitstream_trace_nframes;
extern bool tpg_verbose;
#define frame_dprintk(dev, current, fmt, arg...) \
do { \
if (visl_dprintk_frame_start > -1 && \
(current) >= visl_dprintk_frame_start && \
(current) < visl_dprintk_frame_start + visl_dprintk_nframes) \
dprintk(dev, fmt, ## arg); \
} while (0) \
struct visl_q_data {
unsigned int sequence;
};
struct visl_dev {
struct v4l2_device v4l2_dev;
struct video_device vfd;
#ifdef CONFIG_MEDIA_CONTROLLER
struct media_device mdev;
#endif
struct mutex dev_mutex;
struct v4l2_m2m_dev *m2m_dev;
#ifdef CONFIG_VISL_DEBUGFS
struct dentry *debugfs_root;
struct dentry *bitstream_debugfs;
struct list_head bitstream_blobs;
/* Protects the "blob" list */
struct mutex bitstream_lock;
#endif
};
enum visl_codec {
VISL_CODEC_NONE,
VISL_CODEC_FWHT,
VISL_CODEC_MPEG2,
VISL_CODEC_VP8,
VISL_CODEC_VP9,
VISL_CODEC_H264,
VISL_CODEC_HEVC,
VISL_CODEC_AV1,
};
struct visl_blob {
struct list_head list;
struct dentry *dentry;
struct debugfs_blob_wrapper blob;
};
struct visl_ctx {
struct v4l2_fh fh;
struct visl_dev *dev;
struct v4l2_ctrl_handler hdl;
struct mutex vb_mutex;
struct visl_q_data q_data[VISL_M2M_NQUEUES];
Annotation
- Immediate include surface: `linux/debugfs.h`, `linux/list.h`, `media/v4l2-ctrls.h`, `media/v4l2-device.h`, `media/tpg/v4l2-tpg.h`.
- Detected declarations: `struct visl_ctrls`, `struct visl_coded_format_desc`, `struct visl_q_data`, `struct visl_dev`, `struct visl_blob`, `struct visl_ctx`, `struct visl_ctrl_desc`, `enum visl_codec`.
- Atlas domain: Driver Families / drivers/media.
- 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.