diff options
author | Thomas White <taw@bitwiz.org.uk> | 2009-08-16 18:01:52 +0100 |
---|---|---|
committer | Thomas White <taw@bitwiz.org.uk> | 2009-08-16 18:01:52 +0100 |
commit | e756ff971fe4ca31ea320f8602bfe827e502c670 (patch) | |
tree | da9dc626b59946c3563906aee5d9cd365a2adb27 /drivers | |
parent | 044e1f3c5a6f4b3e9cafc1a356c1c084b9e6993b (diff) |
Unlock mutex on unsuccessful mmap
Signed-off-by: Thomas White <taw@bitwiz.org.uk>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mfd/glamo/glamo-buffer.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mfd/glamo/glamo-buffer.c b/drivers/mfd/glamo/glamo-buffer.c index 815495e1d7f..abf867530aa 100644 --- a/drivers/mfd/glamo/glamo-buffer.c +++ b/drivers/mfd/glamo/glamo-buffer.c @@ -230,8 +230,10 @@ int glamo_ioctl_gem_mmap(struct drm_device *dev, void *data, gobj = obj->driver_private; if (!gobj->mmap_offset) { ret = glamo_gem_create_mmap_offset(obj); - if (ret) + if (ret) { + mutex_unlock(&dev->struct_mutex); return ret; + } } args->offset = gobj->mmap_offset; |