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/gpu/drm/bridge/maxim-max96755f.c | 14 ++++++++++++--
1 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/kernel/drivers/gpu/drm/bridge/maxim-max96755f.c b/kernel/drivers/gpu/drm/bridge/maxim-max96755f.c
index bfabb61..95dcd52 100644
--- a/kernel/drivers/gpu/drm/bridge/maxim-max96755f.c
+++ b/kernel/drivers/gpu/drm/bridge/maxim-max96755f.c
@@ -41,6 +41,7 @@
bool dv_swp_ab;
bool dpi_deskew_en;
bool split_mode;
+ bool bridge_dual_link;
u32 dsi_lane_map[4];
struct {
@@ -283,7 +284,7 @@
static void max96755f_bridge_reset_oneshot(struct max96755f_bridge *ser)
{
- regmap_update_bits(ser->regmap, 0x10, RESET_ONESHOT,
+ regmap_update_bits(ser->regmap, 0x0010, RESET_ONESHOT,
FIELD_PREP(RESET_ONESHOT, 1));
mdelay(100);
@@ -324,6 +325,12 @@
FIELD_PREP(START_PORTAY, 1));
regmap_update_bits(ser->regmap, 0x02, VID_TX_EN_X,
FIELD_PREP(VID_TX_EN_X, 1));
+ if (ser->bridge_dual_link) {
+ regmap_update_bits(ser->regmap, 0x0010,
+ AUTO_LINK | LINK_CFG,
+ FIELD_PREP(AUTO_LINK, 0) |
+ FIELD_PREP(LINK_CFG, DUAL_LINK));
+ }
}
max96755f_bridge_reset_oneshot(ser);
@@ -358,7 +365,7 @@
FIELD_PREP(VID_TX_EN_X, 0) |
FIELD_PREP(VID_TX_EN_Y, 0));
- if (ser->split_mode)
+ if (ser->split_mode || ser->bridge_dual_link)
regmap_update_bits(ser->regmap, 0x0010,
AUTO_LINK | LINK_CFG,
FIELD_PREP(AUTO_LINK, 1) |
@@ -487,6 +494,7 @@
static int max96755f_bridge_probe(struct platform_device *pdev)
{
struct device *dev = &pdev->dev;
+ struct device_node *np = dev->of_node;
struct max96755f_bridge *ser;
int ret;
@@ -529,6 +537,8 @@
if (ret)
return dev_err_probe(dev, ret, "failed to request lock IRQ\n");
+ ser->bridge_dual_link = of_property_read_bool(np, "bridge_dual_link");
+
ser->bridge.funcs = &max96755f_bridge_funcs;
ser->bridge.of_node = dev->of_node;
ser->bridge.ops = DRM_BRIDGE_OP_DETECT;
--
Gitblit v1.6.2