From 1543e317f1da31b75942316931e8f491a8920811 Mon Sep 17 00:00:00 2001
From: hc <hc@nodka.com>
Date: Thu, 04 Jan 2024 10:08:02 +0000
Subject: [PATCH] disable FB
---
kernel/drivers/media/i2c/lt8619c.c | 13 ++++++++-----
1 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/kernel/drivers/media/i2c/lt8619c.c b/kernel/drivers/media/i2c/lt8619c.c
index ab4c926..6255318 100644
--- a/kernel/drivers/media/i2c/lt8619c.c
+++ b/kernel/drivers/media/i2c/lt8619c.c
@@ -27,6 +27,7 @@
#include <linux/v4l2-dv-timings.h>
#include <linux/hdmi.h>
#include <linux/version.h>
+#include <linux/compat.h>
#include <linux/rk-camera-module.h>
#include <media/v4l2-dv-timings.h>
#include <media/v4l2-device.h>
@@ -36,7 +37,7 @@
#include <linux/regmap.h>
#include "lt8619c.h"
-#define DRIVER_VERSION KERNEL_VERSION(0, 0x1, 0x2)
+#define DRIVER_VERSION KERNEL_VERSION(0, 0x01, 0x02)
#define LT8619C_NAME "LT8619C"
static int debug;
@@ -1141,7 +1142,7 @@
return 0;
}
-static int lt8619c_g_mbus_config(struct v4l2_subdev *sd,
+static int lt8619c_g_mbus_config(struct v4l2_subdev *sd, unsigned int pad,
struct v4l2_mbus_config *cfg)
{
struct lt8619c *lt8619c = to_lt8619c(sd);
@@ -1222,8 +1223,7 @@
if (fie->index >= ARRAY_SIZE(supported_modes))
return -EINVAL;
- if (fie->code != MEDIA_BUS_FMT_UYVY8_2X8)
- return -EINVAL;
+ fie->code = MEDIA_BUS_FMT_UYVY8_2X8;
fie->width = supported_modes[fie->index].width;
fie->height = supported_modes[fie->index].height;
@@ -1522,7 +1522,6 @@
.s_dv_timings = lt8619c_s_dv_timings,
.g_dv_timings = lt8619c_g_dv_timings,
.query_dv_timings = lt8619c_query_dv_timings,
- .g_mbus_config = lt8619c_g_mbus_config,
.s_stream = lt8619c_s_stream,
.g_frame_interval = lt8619c_g_frame_interval,
.querystd = lt8619c_querystd,
@@ -1538,6 +1537,7 @@
.set_edid = lt8619c_s_edid,
.enum_dv_timings = lt8619c_enum_dv_timings,
.dv_timings_cap = lt8619c_dv_timings_cap,
+ .get_mbus_config = lt8619c_g_mbus_config,
};
static const struct v4l2_subdev_ops lt8619c_ops = {
@@ -1727,6 +1727,8 @@
const struct i2c_device_id *id)
{
struct device *dev = &client->dev;
+ struct v4l2_dv_timings default_timing =
+ V4L2_DV_BT_CEA_640X480P59_94;
struct lt8619c *lt8619c;
struct v4l2_subdev *sd;
char facing[2];
@@ -1743,6 +1745,7 @@
sd = <8619c->sd;
lt8619c->i2c_client = client;
+ lt8619c->timings = default_timing;
lt8619c->cur_mode = &supported_modes[0];
lt8619c->mbus_fmt_code = MEDIA_BUS_FMT_UYVY8_2X8;
--
Gitblit v1.6.2