staging: drm/omap: fix locking issue
authorRob Clark <rob@ti.com>
Thu, 19 Jan 2012 00:33:02 +0000 (18:33 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 8 Feb 2012 22:14:12 +0000 (14:14 -0800)
commitc5b1247bd1c3ab6722acfa95213be9a16bfb664c
tree3ef9b02ee38d547cf00a7400186deee87e117214
parenta9e8d70c1ac6c9ccf6852c91e082e28249564e6e
staging: drm/omap: fix locking issue

The create/free mmap offset code must be synchronized.  Yet only some
callers of omap_gem_mmap_offset() held struct_mutex.  Leading to various
crashes around drm_mm_insert_helper_range().  (In the free-object path,
which is currently the only place we drm_gem_free_mmap_offset(),
struct_mutex is already held.)

Signed-off-by: Rob Clark <rob@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/omapdrm/omap_gem.c