diff options
author | Archit Taneja <archit@ti.com> | 2012-06-04 10:06:34 +0200 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2012-06-04 12:07:51 +0200 |
commit | 2e063c305a3da896ec3db99e66891411d0e38820 (patch) | |
tree | b3c432f2d92d8391c555225f1a7cd25cd73a4c87 /drivers/video | |
parent | OMAPDSS: fix bogus WARN_ON in dss_runtime_put() (diff) | |
download | linux-2e063c305a3da896ec3db99e66891411d0e38820.tar.xz linux-2e063c305a3da896ec3db99e66891411d0e38820.zip |
OMAPDSS: DSI: Fix bug when calculating LP command interleaving parameters
In function dsi_compute_interleave_lp(), the escape clock/LP clock time period
is calculated incorrectly. The escape clock/LP clock is calculated as:
LP Clock(Hz) = DSI_FCLK(Hz) / lp_clk_div
Since we are calculating the time period of LP clock, the LP clock divider
should be multiplied with the time period of DSI_FCLK.
Calculating incorrect value of txclkesc results in incorrect calculation of LP
interleaving parameters, it also creates a possibility of a divide by zero
error.
Reported-by: Sureshkumar Manimuthu <mail2msuresh@ti.com>
Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/video')
-rw-r--r-- | drivers/video/omap2/dss/dsi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/video/omap2/dss/dsi.c b/drivers/video/omap2/dss/dsi.c index ec363d8390ed..ca8382d346e9 100644 --- a/drivers/video/omap2/dss/dsi.c +++ b/drivers/video/omap2/dss/dsi.c @@ -3724,7 +3724,7 @@ static int dsi_compute_interleave_lp(int blank, int enter_hs, int exit_hs, /* CLKIN4DDR = 16 * TXBYTECLKHS */ tlp_avail = thsbyte_clk * (blank - trans_lp); - ttxclkesc = tdsi_fclk / lp_clk_div; + ttxclkesc = tdsi_fclk * lp_clk_div; lp_inter = ((tlp_avail - 8 * thsbyte_clk - 5 * tdsi_fclk) / ttxclkesc - 26) / 16; |