From 35eb12d8bf91e7a3b0702385fa47b648194803c4 Mon Sep 17 00:00:00 2001 From: Thomas Hellstrom Date: Wed, 14 Feb 2007 15:32:08 +0100 Subject: Fix multiple spinlock unlocking --- linux-core/drm_lock.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'linux-core') diff --git a/linux-core/drm_lock.c b/linux-core/drm_lock.c index a4b1a63f..f02df36b 100644 --- a/linux-core/drm_lock.c +++ b/linux-core/drm_lock.c @@ -224,7 +224,6 @@ int drm_lock_take(drm_lock_data_t *lock_data, if (_DRM_LOCKING_CONTEXT(old) == context) { if (old & _DRM_LOCK_HELD) { - spin_unlock(&lock_data->spinlock); if (context != DRM_KERNEL_CONTEXT) { DRM_ERROR("%d holds heavyweight lock\n", context); @@ -236,10 +235,8 @@ int drm_lock_take(drm_lock_data_t *lock_data, if ((_DRM_LOCKING_CONTEXT(new)) == context && (new & _DRM_LOCK_HELD)) { /* Have lock */ - spin_unlock(&lock_data->spinlock); return 1; } - spin_unlock(&lock_data->spinlock); return 0; } -- cgit v1.2.3