drivers/media/usb/gspca/m5602/m5602_sensor.h

Source file repositories/reference/linux-study-clean/drivers/media/usb/gspca/m5602/m5602_sensor.h

File Facts

System
Linux kernel
Corpus path
drivers/media/usb/gspca/m5602/m5602_sensor.h
Extension
.h
Size
1648 bytes
Lines
70
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.

Dependency Surface

Detected Declarations

Annotated Snippet

struct m5602_sensor {
	/* Defines the name of a sensor */
	char name[32];

	/* What i2c address the sensor is connected to */
	u8 i2c_slave_id;

	/* Width of each i2c register (in bytes) */
	u8 i2c_regW;

	/* Probes if the sensor is connected */
	int (*probe)(struct sd *sd);

	/* Performs a initialization sequence */
	int (*init)(struct sd *sd);

	/* Controls initialization, maybe NULL */
	int (*init_controls)(struct sd *sd);

	/* Executed when the camera starts to send data */
	int (*start)(struct sd *sd);

	/* Executed when the camera ends to send data */
	int (*stop)(struct sd *sd);

	/* Executed when the device is disconnected */
	void (*disconnect)(struct sd *sd);
};

#endif

Annotation

Implementation Notes