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/platform/rockchip/isp/dev.h | 62 +++++++++++++++++++++++++++++++
1 files changed, 62 insertions(+), 0 deletions(-)
diff --git a/kernel/drivers/media/platform/rockchip/isp/dev.h b/kernel/drivers/media/platform/rockchip/isp/dev.h
index 0b73b4f..3e65864 100644
--- a/kernel/drivers/media/platform/rockchip/isp/dev.h
+++ b/kernel/drivers/media/platform/rockchip/isp/dev.h
@@ -81,6 +81,7 @@
ISP_START = BIT(9),
ISP_ERROR = BIT(10),
ISP_MIPI_ERROR = BIT(11),
+ ISP_CIF_RESET = BIT(12),
};
enum rkisp_isp_inp {
@@ -101,6 +102,25 @@
RDBK_F_RD1,
RDBK_F_RD2,
RDBK_F_MAX
+};
+
+/* unite mode for isp to process high resolution
+ * ISP_UNITE_TWO: image splits left and right to two isp hardware
+ * ISP_UNITE_ONE: image splits left and right to single isp hardware
+ */
+enum {
+ ISP_UNITE_NONE = 0,
+ ISP_UNITE_TWO = 1,
+ ISP_UNITE_ONE = 2,
+};
+
+/* left and right index
+ * ISP_UNITE_LEFT: left of image to isp process
+ * ISP_UNITE_RIGHT: right of image to isp process
+ */
+enum {
+ ISP_UNITE_LEFT = 0,
+ ISP_UNITE_RIGHT = 1,
};
/*
@@ -216,6 +236,10 @@
size_t resmem_size;
struct rkisp_thunderboot_resmem_head tb_head;
bool is_thunderboot;
+ /* first frame for rtt */
+ bool is_rtt_first;
+ /* suspend/resume with rtt */
+ bool is_rtt_suspend;
struct rkisp_tb_stream_info tb_stream_info;
unsigned int tb_addr_idx;
@@ -226,6 +250,8 @@
bool send_fbcgain;
struct rkisp_ispp_buf *cur_fbcgain;
struct rkisp_buffer *cur_spbuf;
+
+ struct completion pm_cmpl;
struct work_struct rdbk_work;
struct kfifo rdbk_kfifo;
@@ -249,11 +275,47 @@
bool is_pre_on;
bool is_first_double;
bool is_probe_end;
+ bool is_frame_double;
+ bool is_suspend;
+ bool suspend_sync;
+ bool is_suspend_one_frame;
struct rkisp_vicap_input vicap_in;
u8 multi_mode;
u8 multi_index;
u8 rawaf_irq_cnt;
+ u8 unite_index;
};
+
+static inline void
+rkisp_unite_write(struct rkisp_device *dev, u32 reg, u32 val, bool is_direct)
+{
+ rkisp_write(dev, reg, val, is_direct);
+ if (dev->hw_dev->unite)
+ rkisp_next_write(dev, reg, val, is_direct);
+}
+
+static inline void
+rkisp_unite_set_bits(struct rkisp_device *dev, u32 reg, u32 mask,
+ u32 val, bool is_direct)
+{
+ rkisp_set_bits(dev, reg, mask, val, is_direct);
+ if (dev->hw_dev->unite)
+ rkisp_next_set_bits(dev, reg, mask, val, is_direct);
+}
+
+static inline void
+rkisp_unite_clear_bits(struct rkisp_device *dev, u32 reg, u32 mask,
+ bool is_direct)
+{
+ rkisp_clear_bits(dev, reg, mask, is_direct);
+ if (dev->hw_dev->unite)
+ rkisp_next_clear_bits(dev, reg, mask, is_direct);
+}
+
+static inline bool rkisp_link_sensor(u32 isp_inp)
+{
+ return isp_inp & (INP_CSI | INP_DVP | INP_LVDS);
+}
#endif
--
Gitblit v1.6.2