hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/media/i2c/lt8619c.c
....@@ -27,6 +27,7 @@
2727 #include <linux/v4l2-dv-timings.h>
2828 #include <linux/hdmi.h>
2929 #include <linux/version.h>
30
+#include <linux/compat.h>
3031 #include <linux/rk-camera-module.h>
3132 #include <media/v4l2-dv-timings.h>
3233 #include <media/v4l2-device.h>
....@@ -36,7 +37,7 @@
3637 #include <linux/regmap.h>
3738 #include "lt8619c.h"
3839
39
-#define DRIVER_VERSION KERNEL_VERSION(0, 0x1, 0x2)
40
+#define DRIVER_VERSION KERNEL_VERSION(0, 0x01, 0x02)
4041 #define LT8619C_NAME "LT8619C"
4142
4243 static int debug;
....@@ -1141,7 +1142,7 @@
11411142 return 0;
11421143 }
11431144
1144
-static int lt8619c_g_mbus_config(struct v4l2_subdev *sd,
1145
+static int lt8619c_g_mbus_config(struct v4l2_subdev *sd, unsigned int pad,
11451146 struct v4l2_mbus_config *cfg)
11461147 {
11471148 struct lt8619c *lt8619c = to_lt8619c(sd);
....@@ -1222,8 +1223,7 @@
12221223 if (fie->index >= ARRAY_SIZE(supported_modes))
12231224 return -EINVAL;
12241225
1225
- if (fie->code != MEDIA_BUS_FMT_UYVY8_2X8)
1226
- return -EINVAL;
1226
+ fie->code = MEDIA_BUS_FMT_UYVY8_2X8;
12271227
12281228 fie->width = supported_modes[fie->index].width;
12291229 fie->height = supported_modes[fie->index].height;
....@@ -1522,7 +1522,6 @@
15221522 .s_dv_timings = lt8619c_s_dv_timings,
15231523 .g_dv_timings = lt8619c_g_dv_timings,
15241524 .query_dv_timings = lt8619c_query_dv_timings,
1525
- .g_mbus_config = lt8619c_g_mbus_config,
15261525 .s_stream = lt8619c_s_stream,
15271526 .g_frame_interval = lt8619c_g_frame_interval,
15281527 .querystd = lt8619c_querystd,
....@@ -1538,6 +1537,7 @@
15381537 .set_edid = lt8619c_s_edid,
15391538 .enum_dv_timings = lt8619c_enum_dv_timings,
15401539 .dv_timings_cap = lt8619c_dv_timings_cap,
1540
+ .get_mbus_config = lt8619c_g_mbus_config,
15411541 };
15421542
15431543 static const struct v4l2_subdev_ops lt8619c_ops = {