From df9b6a9c3333a99d4483e92ca6b225b335567313 Mon Sep 17 00:00:00 2001 From: Seung-Woo Kim Date: Tue, 2 Jul 2013 09:53:28 +0900 Subject: [PATCH] drm: fix error routines in drm_open_helper There are missing parts to handle error in drm_open_helper(). The priv->minor, assigned by idr_find() which can return NULL, should be checked whether it is NULL or not before referencing it. put_pid(), drm_gem_release(), and drm_prime_destory_file_private() should be called when error happens after their pair functions are called. If an error occurs after executing dev->driver->open() which allocates driver specific per-file private data, then the private data should be released. Signed-off-by: YoungJun Cho Signed-off-by: Seung-Woo Kim Signed-off-by: Kyungmin Park Reviewed-by: Chris Wilson Signed-off-by: Dave Airlie --- Reading git-format-patch failed