projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
30f82d8
)
vmwgfx: Fix unitialized stack read in vmw_setup_otable_base
author
Dave Jones
<
[email protected]
>
Fri, 31 Jan 2014 02:27:25 +0000
(21:27 -0500)
committer
Thomas Hellstrom
<
[email protected]
>
Wed, 5 Feb 2014 07:52:34 +0000
(08:52 +0100)
One of the error paths in vmw_setup_otable_base causes us to return with
'ret' having never been set to anything causing us to return whatever was
on the stack.
Found with Coverity
Signed-off-by: Dave Jones <
[email protected]
>
Reviewed-by: Thomas Hellstrom <
[email protected]
>
drivers/gpu/drm/vmwgfx/vmwgfx_mob.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/vmwgfx/vmwgfx_mob.c
b/drivers/gpu/drm/vmwgfx/vmwgfx_mob.c
index 4910e7b8181111c63f0ceb586249b1f740409d95..d4a5a19cb8c3ca1bd9db9424aad745ecfea5f868 100644
(file)
--- a/
drivers/gpu/drm/vmwgfx/vmwgfx_mob.c
+++ b/
drivers/gpu/drm/vmwgfx/vmwgfx_mob.c
@@
-134,6
+134,7
@@
static int vmw_setup_otable_base(struct vmw_private *dev_priv,
cmd = vmw_fifo_reserve(dev_priv, sizeof(*cmd));
if (unlikely(cmd == NULL)) {
DRM_ERROR("Failed reserving FIFO space for OTable setup.\n");
+ ret = -ENOMEM;
goto out_no_fifo;
}