video: tegra: add utility function to compute framebuffer stride
authorGary King <gking@nvidia.com>
Sun, 15 Aug 2010 18:26:49 +0000 (11:26 -0700)
committerRebecca Schultz Zavin <rebecca@android.com>
Fri, 8 Oct 2010 22:59:00 +0000 (15:59 -0700)
commit10c751b8f5bb78f674d4939b47be933934bb23dd
treeb95e56d694adbff43be05a4daa93010830a2cfe8
parent93fa4f2a2df9f536f12b929fbe916c72c5422cf1
video: tegra: add utility function to compute framebuffer stride

framebuffers will generally not be exactly width * bpp / 8 bytes wide;
on tegra, linearly-addressed framebuffers will generally be rounded
up so that the stride is a multiple of 16B (so that they are compatible
with rendering from the hardware engines), and tiled framebuffers
will be a multiple of the tile width (64B).

add a utility function to tegra_dc to compute the correct stride
given a width, bpp and pixel layout, and use this in set_par.

Change-Id: I803a55b49c12476f20d5644707899c3fe1336c2d
Signed-off-by: Gary King <gking@nvidia.com>
arch/arm/mach-tegra/include/mach/dc.h
drivers/video/tegra/dc/dc.c
drivers/video/tegra/fb.c