From: Maneet Singh Date: Thu, 8 Oct 2015 14:10:24 +0000 (-0400) Subject: drm: Correct arguments to list_tail_add in create blob ioctl X-Git-Tag: drm-fsl-dcu-for-next~2306^2 X-Git-Url: http://git.agner.ch/gitweb/?a=commitdiff_plain;h=8731b269f01e16193390c7276e70530366b8d626;p=linux-drm-fsl-dcu.git drm: Correct arguments to list_tail_add in create blob ioctl Arguments passed to list_add_tail were reversed resulting in deletion of old blob property everytime the new one is added. Fixes commit e2f5d2ea479b9b2619965d43db70939589afe43a Author: Daniel Stone Date: Fri May 22 13:34:51 2015 +0100 drm/mode: Add user blob-creation ioctl Signed-off-by: Maneet Singh [seanpaul tweaked commit subject a little] Signed-off-by: Sean Paul Cc: stable@kernel.org # v4.2 Reviewed-by: Daniel Stone Reviewed-by: Jani Nikula Signed-off-by: Dave Airlie --- diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c index c205f13f9388..8328e7059205 100644 --- a/drivers/gpu/drm/drm_crtc.c +++ b/drivers/gpu/drm/drm_crtc.c @@ -4454,7 +4454,7 @@ int drm_mode_createblob_ioctl(struct drm_device *dev, * not associated with any file_priv. */ mutex_lock(&dev->mode_config.blob_lock); out_resp->blob_id = blob->base.id; - list_add_tail(&file_priv->blobs, &blob->head_file); + list_add_tail(&blob->head_file, &file_priv->blobs); mutex_unlock(&dev->mode_config.blob_lock); return 0;