summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/i915/intel_overlay.c
diff options
context:
space:
mode:
authorDan Carpenter <error27@gmail.com>2010-10-27 23:17:25 +0200
committerChris Wilson <chris@chris-wilson.co.uk>2010-10-27 22:57:59 +0100
commit8f28f54aad8bcf52a47afb6447fac34f96597b6f (patch)
tree4d6f3b91909ec80b5015ac73b293279d3e5dfce1 /drivers/gpu/drm/i915/intel_overlay.c
parentdd2b379f071424f36f9f90ff83cb4ad058c7b6ed (diff)
i915: signedness bug in check_overlay_src()
"depth" should be signed in case packed_depth_bytes() returns -EINVAL. This probably doesn't make a difference at runtime. In the original code we would return -EINVAL later if (rec->offset_Y % 4294967274) is non-zero. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_overlay.c')
-rw-r--r--drivers/gpu/drm/i915/intel_overlay.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/intel_overlay.c b/drivers/gpu/drm/i915/intel_overlay.c
index afb96d25219a..02ff0a481f47 100644
--- a/drivers/gpu/drm/i915/intel_overlay.c
+++ b/drivers/gpu/drm/i915/intel_overlay.c
@@ -946,7 +946,9 @@ static int check_overlay_src(struct drm_device *dev,
{
int uv_hscale = uv_hsubsampling(rec->flags);
int uv_vscale = uv_vsubsampling(rec->flags);
- u32 stride_mask, depth, tmp;
+ u32 stride_mask;
+ int depth;
+ u32 tmp;
/* check src dimensions */
if (IS_845G(dev) || IS_I830(dev)) {