Jelajahi Sumber

drm: fix regression in drm locking since BKL removal.

This locking path needs proper auditing but probably too late for changes at this point for 2.6.36, so lets go with the quick fix, which is to drop the lock around schedule.

Reported-by: Andreas Schwab <schwab@linux-m68k.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Arnd Bergmann 15 tahun lalu
induk
melakukan
08f2e669a8
1 mengubah file dengan 2 tambahan dan 0 penghapusan
  1. 2 0
      drivers/gpu/drm/drm_lock.c

+ 2 - 0
drivers/gpu/drm/drm_lock.c

@@ -92,7 +92,9 @@ int drm_lock(struct drm_device *dev, void *data, struct drm_file *file_priv)
 		}
 		}
 
 
 		/* Contention */
 		/* Contention */
+		mutex_unlock(&drm_global_mutex);
 		schedule();
 		schedule();
+		mutex_lock(&drm_global_mutex);
 		if (signal_pending(current)) {
 		if (signal_pending(current)) {
 			ret = -EINTR;
 			ret = -EINTR;
 			break;
 			break;