diff options
author | Vineel Kumar Reddy Kovvuri <vineelkumarr@nvidia.com> | 2014-07-16 07:23:34 -0400 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2015-03-18 15:10:31 -0400 |
commit | 42134c7f6e6d8a545778f17efe16bbcdacfd3d68 (patch) | |
tree | 905dfd82130f73182f574fb02a768d148e43d447 /drivers/video/tegra/dc/dsi.c | |
parent | 000135bab3568193ea010b44bee363b4ca7083df (diff) |
video: tegra: dsi: turn off pads after calibration
Turn off mipi bias pads after calibration
Bug 200021693
Change-Id: Ia62e2e386fc766b15e1abaee1bacb873a326d1bf
Signed-off-by: Vineel Kumar Reddy Kovvuri <vineelkumarr@nvidia.com>
Reviewed-on: http://git-master/r/438645
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Tested-by: Laxman Dewangan <ldewangan@nvidia.com>
Diffstat (limited to 'drivers/video/tegra/dc/dsi.c')
-rw-r--r-- | drivers/video/tegra/dc/dsi.c | 34 |
1 files changed, 16 insertions, 18 deletions
diff --git a/drivers/video/tegra/dc/dsi.c b/drivers/video/tegra/dc/dsi.c index 3c31e3975..866cdf931 100644 --- a/drivers/video/tegra/dc/dsi.c +++ b/drivers/video/tegra/dc/dsi.c | |||
@@ -2514,6 +2514,8 @@ static void tegra_dsi_mipi_calibration_11x(struct tegra_dc_dsi_data *dsi) | |||
2514 | #endif | 2514 | #endif |
2515 | static void tegra_dsi_pad_calibration(struct tegra_dc_dsi_data *dsi) | 2515 | static void tegra_dsi_pad_calibration(struct tegra_dc_dsi_data *dsi) |
2516 | { | 2516 | { |
2517 | u32 val = 0; | ||
2518 | |||
2517 | if (!dsi->ulpm) | 2519 | if (!dsi->ulpm) |
2518 | tegra_dsi_pad_enable(dsi); | 2520 | tegra_dsi_pad_enable(dsi); |
2519 | else | 2521 | else |
@@ -2525,6 +2527,13 @@ static void tegra_dsi_pad_calibration(struct tegra_dc_dsi_data *dsi) | |||
2525 | 2527 | ||
2526 | tegra_mipi_cal_clk_enable(dsi->mipi_cal); | 2528 | tegra_mipi_cal_clk_enable(dsi->mipi_cal); |
2527 | 2529 | ||
2530 | /* enable mipi bias pad */ | ||
2531 | val = tegra_mipi_cal_read(dsi->mipi_cal, | ||
2532 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
2533 | val &= ~MIPI_BIAS_PAD_PDVCLAMP(0x1); | ||
2534 | tegra_mipi_cal_write(dsi->mipi_cal, val, | ||
2535 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
2536 | |||
2528 | #if defined(CONFIG_ARCH_TEGRA_11x_SOC) || \ | 2537 | #if defined(CONFIG_ARCH_TEGRA_11x_SOC) || \ |
2529 | defined(CONFIG_ARCH_TEGRA_14x_SOC) || \ | 2538 | defined(CONFIG_ARCH_TEGRA_14x_SOC) || \ |
2530 | defined(CONFIG_ARCH_TEGRA_12x_SOC) | 2539 | defined(CONFIG_ARCH_TEGRA_12x_SOC) |
@@ -2548,6 +2557,13 @@ static void tegra_dsi_pad_calibration(struct tegra_dc_dsi_data *dsi) | |||
2548 | #elif defined(CONFIG_ARCH_TEGRA_12x_SOC) | 2557 | #elif defined(CONFIG_ARCH_TEGRA_12x_SOC) |
2549 | tegra_dsi_mipi_calibration_12x(dsi); | 2558 | tegra_dsi_mipi_calibration_12x(dsi); |
2550 | #endif | 2559 | #endif |
2560 | /* disable mipi bias pad */ | ||
2561 | val = tegra_mipi_cal_read(dsi->mipi_cal, | ||
2562 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
2563 | val |= MIPI_BIAS_PAD_PDVCLAMP(0x1); | ||
2564 | tegra_mipi_cal_write(dsi->mipi_cal, val, | ||
2565 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
2566 | |||
2551 | tegra_mipi_cal_clk_disable(dsi->mipi_cal); | 2567 | tegra_mipi_cal_clk_disable(dsi->mipi_cal); |
2552 | } else { | 2568 | } else { |
2553 | #ifdef CONFIG_ARCH_TEGRA_3x_SOC | 2569 | #ifdef CONFIG_ARCH_TEGRA_3x_SOC |
@@ -4615,15 +4631,6 @@ static int _tegra_dsi_host_suspend(struct tegra_dc *dc, | |||
4615 | val |= DSI_PAD_PDVCLAMP(0x1); | 4631 | val |= DSI_PAD_PDVCLAMP(0x1); |
4616 | tegra_dsi_writel(dsi, val, DSI_PAD_CONTROL_3_VS1); | 4632 | tegra_dsi_writel(dsi, val, DSI_PAD_CONTROL_3_VS1); |
4617 | 4633 | ||
4618 | /* disable mipi bias pad */ | ||
4619 | tegra_mipi_cal_clk_enable(dsi->mipi_cal); | ||
4620 | val = tegra_mipi_cal_read(dsi->mipi_cal, | ||
4621 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
4622 | val |= MIPI_BIAS_PAD_PDVCLAMP(0x1); | ||
4623 | tegra_mipi_cal_write(dsi->mipi_cal, val, | ||
4624 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
4625 | tegra_mipi_cal_clk_disable(dsi->mipi_cal); | ||
4626 | |||
4627 | /* fall through */ | 4634 | /* fall through */ |
4628 | case DSI_HOST_SUSPEND_LV1: | 4635 | case DSI_HOST_SUSPEND_LV1: |
4629 | /* Disable dsi fast and slow clock */ | 4636 | /* Disable dsi fast and slow clock */ |
@@ -4666,15 +4673,6 @@ static int _tegra_dsi_host_resume(struct tegra_dc *dc, | |||
4666 | tegra_dsi_config_phy_clk(dsi, TEGRA_DSI_ENABLE); | 4673 | tegra_dsi_config_phy_clk(dsi, TEGRA_DSI_ENABLE); |
4667 | tegra_dsi_clk_enable(dsi); | 4674 | tegra_dsi_clk_enable(dsi); |
4668 | 4675 | ||
4669 | /* enable mipi bias pad */ | ||
4670 | tegra_mipi_cal_clk_enable(dsi->mipi_cal); | ||
4671 | val = tegra_mipi_cal_read(dsi->mipi_cal, | ||
4672 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
4673 | val &= ~MIPI_BIAS_PAD_PDVCLAMP(0x1); | ||
4674 | tegra_mipi_cal_write(dsi->mipi_cal, val, | ||
4675 | MIPI_CAL_MIPI_BIAS_PAD_CFG0_0); | ||
4676 | tegra_mipi_cal_clk_disable(dsi->mipi_cal); | ||
4677 | |||
4678 | /* enable HS logic */ | 4676 | /* enable HS logic */ |
4679 | val = tegra_dsi_readl(dsi, DSI_PAD_CONTROL_3_VS1); | 4677 | val = tegra_dsi_readl(dsi, DSI_PAD_CONTROL_3_VS1); |
4680 | val &= ~DSI_PAD_PDVCLAMP(0x1); | 4678 | val &= ~DSI_PAD_PDVCLAMP(0x1); |