Lines Matching +full:- +full:- +full:enable +full:- +full:debug

1 // SPDX-License-Identifier: GPL-2.0+
4 * Author: Eric Gao <eric.gao@rock-chips.com>
19 #include <dm/uclass-internal.h>
30 struct rk3399_grf_regs *grf = priv->grf; in rk_mipi_dsi_source_select()
34 switch (disp_uc_plat->source_id) { in rk_mipi_dsi_source_select()
36 rk_clrsetreg(&grf->soc_con20, GRF_DSI0_VOP_SEL_MASK, in rk_mipi_dsi_source_select()
40 rk_clrsetreg(&grf->soc_con20, GRF_DSI0_VOP_SEL_MASK, in rk_mipi_dsi_source_select()
44 debug("%s: Invalid VOP id\n", __func__); in rk_mipi_dsi_source_select()
45 return -EINVAL; in rk_mipi_dsi_source_select()
55 struct rk3399_grf_regs *grf = priv->grf; in rk_mipi_dphy_mode_set()
60 rk_clrsetreg(&grf->soc_con22, GRF_DPHY_TX0_RXMODE_MASK, val); in rk_mipi_dphy_mode_set()
64 rk_clrsetreg(&grf->soc_con22, GRF_DPHY_TX0_TXSTOPMODE_MASK, val); in rk_mipi_dphy_mode_set()
68 rk_clrsetreg(&grf->soc_con22, GRF_DPHY_TX0_TURNREQUEST_MASK, val); in rk_mipi_dphy_mode_set()
74 * enable backlight.
83 priv->ref_clk = 24 * MHz; in rk_display_enable()
84 priv->sys_clk = priv->ref_clk; in rk_display_enable()
85 priv->pix_clk = timing->pixelclock.typ; in rk_display_enable()
86 priv->phy_clk = priv->pix_clk * 6; in rk_display_enable()
87 priv->txbyte_clk = priv->phy_clk / 8; in rk_display_enable()
88 priv->txesc_clk = 20 * MHz; in rk_display_enable()
96 /* Config and enable mipi dsi according to timing */ in rk_display_enable()
99 debug("%s: rk_mipi_dsi_enable() failed (err=%d)\n", in rk_display_enable()
104 /* Config and enable mipi phy */ in rk_display_enable()
107 debug("%s: rk_mipi_phy_enable() failed (err=%d)\n", in rk_display_enable()
112 /* Enable backlight */ in rk_display_enable()
113 ret = panel_enable_backlight(priv->panel); in rk_display_enable()
115 debug("%s: panel_enable_backlight() failed (err=%d)\n", in rk_display_enable()
127 priv->grf = syscon_get_first_range(ROCKCHIP_SYSCON_GRF); in rk_mipi_ofdata_to_platdata()
128 if (IS_ERR_OR_NULL(priv->grf)) { in rk_mipi_ofdata_to_platdata()
129 debug("%s: Get syscon grf failed (ret=%p)\n", in rk_mipi_ofdata_to_platdata()
130 __func__, priv->grf); in rk_mipi_ofdata_to_platdata()
131 return -ENXIO; in rk_mipi_ofdata_to_platdata()
133 priv->regs = dev_read_addr(dev); in rk_mipi_ofdata_to_platdata()
134 if (priv->regs == FDT_ADDR_T_NONE) { in rk_mipi_ofdata_to_platdata()
135 debug("%s: Get MIPI dsi address failed\n", __func__); in rk_mipi_ofdata_to_platdata()
136 return -ENXIO; in rk_mipi_ofdata_to_platdata()
144 * mipi dsi controller and enable it according to the timing parameter.
152 &priv->panel); in rk_mipi_probe()
154 debug("%s: Can not find panel (err=%d)\n", __func__, ret); in rk_mipi_probe()
163 .enable = rk_display_enable,