[yocto] [PATCH 1/1][3.2 KERNEL] bsp/emenlow: give up drm_global_mutex on contention in drm_lock()

tom.zanussi at intel.com tom.zanussi at intel.com
Wed Apr 25 07:11:27 PDT 2012


From: Tom Zanussi <tom.zanussi at intel.com>

If drm_lock_take() fails, give up the global ioctl mutex and allow
other locked ioctls in the meantime.

Signed-off-by: Tom Zanussi <tom.zanussi at intel.com>
---
 drivers/gpu/drm-psb/drm_lock.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/gpu/drm-psb/drm_lock.c b/drivers/gpu/drm-psb/drm_lock.c
index b8e4a5d..ba6630e 100644
--- a/drivers/gpu/drm-psb/drm_lock.c
+++ b/drivers/gpu/drm-psb/drm_lock.c
@@ -89,7 +89,9 @@ int drm_lock(struct drm_device *dev, void *data, struct drm_file *file_priv)
 		}
 
 		/* Contention */
+		mutex_unlock(&drm_global_mutex);
 		schedule();
+		mutex_lock(&drm_global_mutex);
 		if (signal_pending(current)) {
 			ret = -ERESTARTSYS;
 			break;
-- 
1.7.0.4




More information about the yocto mailing list