#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/i2c.h>
#include <linux/slab.h>
#include <linux/videodev2.h>
#include <media/v4l2-device.h>
MODULE_DESCRIPTION(…) …;
MODULE_AUTHOR(…) …;
MODULE_LICENSE(…) …;
static inline int cs3308_write(struct v4l2_subdev *sd, u8 reg, u8 value)
{ … }
static inline int cs3308_read(struct v4l2_subdev *sd, u8 reg)
{ … }
#ifdef CONFIG_VIDEO_ADV_DEBUG
static int cs3308_g_register(struct v4l2_subdev *sd, struct v4l2_dbg_register *reg)
{ … }
static int cs3308_s_register(struct v4l2_subdev *sd, const struct v4l2_dbg_register *reg)
{ … }
#endif
static const struct v4l2_subdev_core_ops cs3308_core_ops = …;
static const struct v4l2_subdev_ops cs3308_ops = …;
static int cs3308_probe(struct i2c_client *client)
{ … }
static void cs3308_remove(struct i2c_client *client)
{ … }
static const struct i2c_device_id cs3308_id[] = …;
MODULE_DEVICE_TABLE(i2c, cs3308_id);
static struct i2c_driver cs3308_driver = …;
module_i2c_driver(…) …;