Commit a7319c8f authored by Dan Carpenter's avatar Dan Carpenter Committed by Thomas Zimmermann

drm/udl: Fix missing error code in udl_handle_damage()

If udl_get_urb() fails then this should return a negative error code
but currently it returns success.

Fixes: 798ce3fe ("drm/udl: Begin/end access to imported buffers in damage-handler")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20201113101502.GD168908@mwanda
parent 2c686404
......@@ -305,8 +305,10 @@ static int udl_handle_damage(struct drm_framebuffer *fb, int x, int y,
vaddr = map.vaddr; /* TODO: Use mapping abstraction properly */
urb = udl_get_urb(dev);
if (!urb)
if (!urb) {
ret = -ENOMEM;
goto out_drm_gem_shmem_vunmap;
}
cmd = urb->transfer_buffer;
for (i = clip.y1; i < clip.y2; i++) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment