#include <linux/module.h>
#include <linux/types.h>
#include <linux/slab.h>
#include <linux/ioctl.h>
#include <linux/uaccess.h>
#include <linux/i2c.h>
#include <linux/videodev2.h>
#include <media/i2c/m52790.h>
#include <media/v4l2-device.h>
MODULE_DESCRIPTION(…) …;
MODULE_AUTHOR(…) …;
MODULE_LICENSE(…) …;
struct m52790_state { … };
static inline struct m52790_state *to_state(struct v4l2_subdev *sd)
{ … }
static int m52790_write(struct v4l2_subdev *sd)
{ … }
static int m52790_s_routing(struct v4l2_subdev *sd,
u32 input, u32 output, u32 config)
{ … }
#ifdef CONFIG_VIDEO_ADV_DEBUG
static int m52790_g_register(struct v4l2_subdev *sd, struct v4l2_dbg_register *reg)
{ … }
static int m52790_s_register(struct v4l2_subdev *sd, const struct v4l2_dbg_register *reg)
{ … }
#endif
static int m52790_log_status(struct v4l2_subdev *sd)
{ … }
static const struct v4l2_subdev_core_ops m52790_core_ops = …;
static const struct v4l2_subdev_audio_ops m52790_audio_ops = …;
static const struct v4l2_subdev_video_ops m52790_video_ops = …;
static const struct v4l2_subdev_ops m52790_ops = …;
static int m52790_probe(struct i2c_client *client)
{ … }
static void m52790_remove(struct i2c_client *client)
{ … }
static const struct i2c_device_id m52790_id[] = …;
MODULE_DEVICE_TABLE(i2c, m52790_id);
static struct i2c_driver m52790_driver = …;
module_i2c_driver(…) …;