diff options
author | Michael Frydrych <mfrydrych@nvidia.com> | 2011-08-15 16:19:17 +0300 |
---|---|---|
committer | Rohan Somvanshi <rsomvanshi@nvidia.com> | 2011-08-22 08:12:01 -0700 |
commit | 112bad447414fdc33e4c72393ffbbfb04d3caa78 (patch) | |
tree | 148537a993a8f377ac71131dc036655e058ab91c | |
parent | 05e23c2e5a1a33797faffc895bcf178640d8d2e9 (diff) |
video: tegra: dc: correct rounding of bandwidth for window B
Patch eb81b378 had a sideeffect in that bandwidth of window B
may have no longer been rounded up to 1MBs, contrary to original
intention. This patch fixes it.
Change-Id: Idaba2923e0316245e284e19e1a995adf1bd9cd35
Reviewed-on: http://git-master/r/47133
Reviewed-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
Tested-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
-rw-r--r-- | drivers/video/tegra/dc/dc.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/video/tegra/dc/dc.c b/drivers/video/tegra/dc/dc.c index 1652baff8419..9373acfd32fd 100644 --- a/drivers/video/tegra/dc/dc.c +++ b/drivers/video/tegra/dc/dc.c @@ -704,15 +704,17 @@ static void tegra_dc_set_latency_allowance(struct tegra_dc *dc, BUG_ON(dc->ndev->id >= ARRAY_SIZE(vfilter_tab)); BUG_ON(w->idx >= ARRAY_SIZE(*la_id_tab)); - /* our bandwidth is in bytes/sec, but LA takes MBps. - * round up bandwidth to 1MBps */ - bw = w->new_bandwidth / 1000000 + 1; + bw = w->new_bandwidth; /* tegra_dc_get_bandwidth() treats V filter windows as double * bandwidth, but LA has a seperate client for V filter */ if (w->idx == 1 && win_use_v_filter(w)) bw /= 2; + /* our bandwidth is in bytes/sec, but LA takes MBps. + * round up bandwidth to 1MBps */ + bw = bw / 1000000 + 1; + tegra_set_latency_allowance(la_id_tab[dc->ndev->id][w->idx], bw); /* if window B, also set the 1B client for the 2-tap V filter. */ |