#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/ctype.h>
#include <linux/slab.h>
#include <linux/i2c.h>
#include <linux/device.h>
#include <linux/delay.h>
#include <linux/module.h>
#include <linux/videodev2.h>
#include <linux/uaccess.h>
#include <linux/of.h>
#include <linux/of_graph.h>
#include <media/i2c/adv7343.h>
#include <media/v4l2-async.h>
#include <media/v4l2-device.h>
#include <media/v4l2-ctrls.h>
#include "adv7343_regs.h"
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;
static int debug;
module_param(debug, int, 0644);
MODULE_PARM_DESC(…) …;
struct adv7343_state { … };
static inline struct adv7343_state *to_state(struct v4l2_subdev *sd)
{ … }
static inline struct v4l2_subdev *to_sd(struct v4l2_ctrl *ctrl)
{ … }
static inline int adv7343_write(struct v4l2_subdev *sd, u8 reg, u8 value)
{ … }
static const u8 adv7343_init_reg_val[] = …;
static const struct adv7343_std_info stdinfo[] = …;
static int adv7343_setstd(struct v4l2_subdev *sd, v4l2_std_id std)
{ … }
static int adv7343_setoutput(struct v4l2_subdev *sd, u32 output_type)
{ … }
static int adv7343_log_status(struct v4l2_subdev *sd)
{ … }
static int adv7343_s_ctrl(struct v4l2_ctrl *ctrl)
{ … }
static const struct v4l2_ctrl_ops adv7343_ctrl_ops = …;
static const struct v4l2_subdev_core_ops adv7343_core_ops = …;
static int adv7343_s_std_output(struct v4l2_subdev *sd, v4l2_std_id std)
{ … }
static int adv7343_s_routing(struct v4l2_subdev *sd,
u32 input, u32 output, u32 config)
{ … }
static const struct v4l2_subdev_video_ops adv7343_video_ops = …;
static const struct v4l2_subdev_ops adv7343_ops = …;
static int adv7343_initialize(struct v4l2_subdev *sd)
{ … }
static struct adv7343_platform_data *
adv7343_get_pdata(struct i2c_client *client)
{ … }
static int adv7343_probe(struct i2c_client *client)
{ … }
static void adv7343_remove(struct i2c_client *client)
{ … }
static const struct i2c_device_id adv7343_id[] = …;
MODULE_DEVICE_TABLE(i2c, adv7343_id);
#if IS_ENABLED(CONFIG_OF)
static const struct of_device_id adv7343_of_match[] = …;
MODULE_DEVICE_TABLE(of, adv7343_of_match);
#endif
static struct i2c_driver adv7343_driver = …;
module_i2c_driver(…) …;