dect
/
linux-2.6
Archived
13
0
Fork 0

drm: drm_fops.c unlock missing on error path

drm_open_helper() from drm_fops.c had a missing mutex_unlock in a error
path.

This was caught by smatch (http://repo.or.cz/w/smatch.git/).  Compile
tested.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
Dan Carpenter 2009-03-27 13:34:28 +03:00 committed by Dave Airlie
parent c972d750e4
commit dba5ed0cd1
1 changed files with 1 additions and 0 deletions

View File

@ -274,6 +274,7 @@ static int drm_open_helper(struct inode *inode, struct file *filp,
/* create a new master */
priv->minor->master = drm_master_create(priv->minor);
if (!priv->minor->master) {
mutex_unlock(&dev->struct_mutex);
ret = -ENOMEM;
goto out_free;
}