diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-04-05 10:25:18 +0200 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-04-22 15:39:37 +0200 |
commit | e39a52da87fc49eeb0a91e7db3c30bd61e87bdb7 (patch) | |
tree | 0415b00dc9ed824cab9b2ebd6cdb11e609f1c1f8 /drivers/gpu/drm/udl | |
parent | 2ffd65283bcf120f6bac0d5954c7ccdb845fcbd5 (diff) | |
download | blackbird-op-linux-e39a52da87fc49eeb0a91e7db3c30bd61e87bdb7.tar.gz blackbird-op-linux-e39a52da87fc49eeb0a91e7db3c30bd61e87bdb7.zip |
drm/udl: Initialize ret in udl_driver_load
We need to set it to -ENODEV when we don't recognize the device.
Otherwise we return/print stack garbage.
Spotted by coverity.
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/udl')
-rw-r--r-- | drivers/gpu/drm/udl/udl_main.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/udl/udl_main.c b/drivers/gpu/drm/udl/udl_main.c index f5ae57406f34..e1038a945f40 100644 --- a/drivers/gpu/drm/udl/udl_main.c +++ b/drivers/gpu/drm/udl/udl_main.c @@ -294,6 +294,7 @@ int udl_driver_load(struct drm_device *dev, unsigned long flags) dev->dev_private = udl; if (!udl_parse_vendor_descriptor(dev, dev->usbdev)) { + ret = -ENODEV; DRM_ERROR("firmware not recognized. Assume incompatible device\n"); goto err; } |