forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f70575805708cabdedea7498aaa3f710fde4d920
kernel/drivers/gpu/drm/msm/dsi/phy/dsi_phy.h
....@@ -1,14 +1,6 @@
1
+/* SPDX-License-Identifier: GPL-2.0-only */
12 /*
23 * Copyright (c) 2015, The Linux Foundation. All rights reserved.
3
- *
4
- * This program is free software; you can redistribute it and/or modify
5
- * it under the terms of the GNU General Public License version 2 and
6
- * only version 2 as published by the Free Software Foundation.
7
- *
8
- * This program is distributed in the hope that it will be useful,
9
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
10
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
- * GNU General Public License for more details.
124 */
135
146 #ifndef __DSI_PHY_H__
....@@ -20,6 +12,9 @@
2012
2113 #define dsi_phy_read(offset) msm_readl((offset))
2214 #define dsi_phy_write(offset, data) msm_writel((data), (offset))
15
+
16
+/* v3.0.0 10nm implementation that requires the old timings settings */
17
+#define V3_0_0_10NM_OLD_TIMINGS_QUIRK BIT(0)
2318
2419 struct msm_dsi_phy_ops {
2520 int (*init) (struct msm_dsi_phy *phy);
....@@ -41,18 +36,22 @@
4136 bool src_pll_truthtable[DSI_MAX][DSI_MAX];
4237 const resource_size_t io_start[DSI_MAX];
4338 const int num_dsi_phy;
39
+ const int quirks;
4440 };
4541
4642 extern const struct msm_dsi_phy_cfg dsi_phy_28nm_hpm_cfgs;
43
+extern const struct msm_dsi_phy_cfg dsi_phy_28nm_hpm_famb_cfgs;
4744 extern const struct msm_dsi_phy_cfg dsi_phy_28nm_lp_cfgs;
4845 extern const struct msm_dsi_phy_cfg dsi_phy_20nm_cfgs;
4946 extern const struct msm_dsi_phy_cfg dsi_phy_28nm_8960_cfgs;
5047 extern const struct msm_dsi_phy_cfg dsi_phy_14nm_cfgs;
48
+extern const struct msm_dsi_phy_cfg dsi_phy_14nm_660_cfgs;
5149 extern const struct msm_dsi_phy_cfg dsi_phy_10nm_cfgs;
50
+extern const struct msm_dsi_phy_cfg dsi_phy_10nm_8998_cfgs;
51
+extern const struct msm_dsi_phy_cfg dsi_phy_7nm_cfgs;
52
+extern const struct msm_dsi_phy_cfg dsi_phy_7nm_8150_cfgs;
5253
5354 struct msm_dsi_dphy_timing {
54
- u32 clk_pre;
55
- u32 clk_post;
5655 u32 clk_zero;
5756 u32 clk_trail;
5857 u32 clk_prepare;
....@@ -103,6 +102,8 @@
103102 struct msm_dsi_phy_clk_request *clk_req);
104103 int msm_dsi_dphy_timing_calc_v3(struct msm_dsi_dphy_timing *timing,
105104 struct msm_dsi_phy_clk_request *clk_req);
105
+int msm_dsi_dphy_timing_calc_v4(struct msm_dsi_dphy_timing *timing,
106
+ struct msm_dsi_phy_clk_request *clk_req);
106107 void msm_dsi_phy_set_src_pll(struct msm_dsi_phy *phy, int pll_id, u32 reg,
107108 u32 bit_mask);
108109 int msm_dsi_phy_init_common(struct msm_dsi_phy *phy);