summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorRobert Morell <rmorell@nvidia.com>2011-07-15 18:47:06 -0700
committerVarun Colbert <vcolbert@nvidia.com>2011-08-29 17:49:50 -0700
commitd4f30a049a1d97b350c415c3f40d5fa57724c8d4 (patch)
treec44eb2954929f2f0e1587d0f6db92d78c6bbacb0 /arch
parent9ce011627ad7255153cf78d2c7e5b09a21d16101 (diff)
video: tegra: dc: Separate allocations for U and V
Currently, dc_ext only takes a single nvmap memory ID per overlay, even in the YUV case (the U and V planes are expected to be differentiated using an offset from the beginning of the nvmap allocation). This is problematic for some software flows, such as certain video interlacing algorithms that will vary the luma plane while keeping the chrome plane constant. This change allows dc_ext clients to specify a different nvmap allocation for each of the Y, U, and V planes. If a YUV surface is used and no U or V plane allocation is specified, the old behavior is preserved: the U and V offsets are assumed to be within the same allocation as Y. Note: this changes the behavior of the offset parameter: the old code added offset to offset_u and offset_v when using it. The new code treats all three offsets as relative to the beginning of the allocation. It also fixes a bug in the code where offset was applied twice to the Y plane. I believe this is safe because the presence of this bug means that no existing clients are using offset != 0 (or if they are, they're already broken). Signed-off-by: Robert Morell <rmorell@nvidia.com> Bug 850882 Change-Id: I230e03db25baaae73a3bdc0d45a2aec162b87fa4 Reviewed-on: http://git-master/r/41471 Reviewed-by: Varun Colbert <vcolbert@nvidia.com> Tested-by: Varun Colbert <vcolbert@nvidia.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-tegra/include/mach/dc.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/arch/arm/mach-tegra/include/mach/dc.h b/arch/arm/mach-tegra/include/mach/dc.h
index 397e9d147721..d291f29268d7 100644
--- a/arch/arm/mach-tegra/include/mach/dc.h
+++ b/arch/arm/mach-tegra/include/mach/dc.h
@@ -370,9 +370,8 @@ struct tegra_dc_win {
void *virt_addr;
dma_addr_t phys_addr;
- unsigned offset;
- unsigned offset_u;
- unsigned offset_v;
+ dma_addr_t phys_addr_u;
+ dma_addr_t phys_addr_v;
unsigned stride;
unsigned stride_uv;
fixed20_12 x;