drivers/media/usb/dvb-usb/cxusb.h
Source file repositories/reference/linux-study-clean/drivers/media/usb/dvb-usb/cxusb.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/media/usb/dvb-usb/cxusb.h- Extension
.h- Size
- 4778 bytes
- Lines
- 205
- 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/completion.hlinux/i2c.hlinux/list.hlinux/mutex.hlinux/usb.hlinux/workqueue.hmedia/v4l2-common.hmedia/v4l2-dev.hmedia/v4l2-device.hmedia/videobuf2-core.hmedia/videobuf2-v4l2.hdvb-usb.h
Detected Declarations
struct cxusb_statestruct cxusb_medion_auxbufstruct cxusb_bt656_paramsstruct cxusb_medion_devstruct cxusb_medion_vbufferenum cxusb_open_typeenum cxusb_bt656_modeenum cxusb_bt656_fmodefunction cxusb_medion_analog_initfunction cxusb_medion_register_analogfunction cxusb_medion_unregister_analog
Annotated Snippet
struct cxusb_state {
u8 gpio_write_state[3];
bool gpio_write_refresh[3];
struct i2c_client *i2c_client_demod;
struct i2c_client *i2c_client_tuner;
unsigned char data[MAX_XFER_SIZE];
struct mutex stream_mutex;
u8 last_lock;
int (*fe_read_status)(struct dvb_frontend *fe,
enum fe_status *status);
};
enum cxusb_open_type {
CXUSB_OPEN_INIT,
CXUSB_OPEN_NONE,
CXUSB_OPEN_ANALOG,
CXUSB_OPEN_DIGITAL
};
struct cxusb_medion_auxbuf {
u8 *buf;
unsigned int len;
unsigned int paylen;
};
enum cxusb_bt656_mode {
NEW_FRAME, FIRST_FIELD, SECOND_FIELD
};
enum cxusb_bt656_fmode {
START_SEARCH, LINE_SAMPLES, VBI_SAMPLES
};
struct cxusb_bt656_params {
enum cxusb_bt656_mode mode;
enum cxusb_bt656_fmode fmode;
unsigned int pos;
unsigned int line;
unsigned int linesamples;
u8 *buf;
};
struct cxusb_medion_dev {
/* has to be the first one */
struct cxusb_state state;
struct dvb_usb_device *dvbdev;
enum cxusb_open_type open_type;
unsigned int open_ctr;
struct mutex open_lock;
#ifdef CONFIG_DVB_USB_CXUSB_ANALOG
struct v4l2_device v4l2dev;
struct v4l2_subdev *cx25840;
struct v4l2_subdev *tuner;
struct v4l2_subdev *tda9887;
struct video_device *videodev, *radiodev;
struct mutex dev_lock;
struct vb2_queue videoqueue;
u32 input;
bool stop_streaming;
u32 width, height;
u32 field_order;
struct cxusb_medion_auxbuf auxbuf;
v4l2_std_id norm;
struct urb *streamurbs[CXUSB_VIDEO_URBS];
unsigned long urbcomplete;
struct work_struct urbwork;
unsigned int nexturb;
struct cxusb_bt656_params bt656;
struct cxusb_medion_vbuffer *vbuf;
__u32 vbuf_sequence;
struct list_head buflist;
struct completion v4l2_release;
#endif
};
struct cxusb_medion_vbuffer {
struct vb2_v4l2_buffer vb2;
struct list_head list;
};
Annotation
- Immediate include surface: `linux/completion.h`, `linux/i2c.h`, `linux/list.h`, `linux/mutex.h`, `linux/usb.h`, `linux/workqueue.h`, `media/v4l2-common.h`, `media/v4l2-dev.h`.
- Detected declarations: `struct cxusb_state`, `struct cxusb_medion_auxbuf`, `struct cxusb_bt656_params`, `struct cxusb_medion_dev`, `struct cxusb_medion_vbuffer`, `enum cxusb_open_type`, `enum cxusb_bt656_mode`, `enum cxusb_bt656_fmode`, `function cxusb_medion_analog_init`, `function cxusb_medion_register_analog`.
- 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.