Module Name:    src
Committed By:   riastradh
Date:           Sat Jul 26 21:35:06 UTC 2014

Modified Files:
        src/sys/external/bsd/drm2/include/linux: ww_mutex.h

Log Message:
Don't forget to decrement the acquired count too.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/external/bsd/drm2/include/linux/ww_mutex.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/external/bsd/drm2/include/linux/ww_mutex.h
diff -u src/sys/external/bsd/drm2/include/linux/ww_mutex.h:1.2 src/sys/external/bsd/drm2/include/linux/ww_mutex.h:1.3
--- src/sys/external/bsd/drm2/include/linux/ww_mutex.h:1.2	Tue Jul 22 02:38:31 2014
+++ src/sys/external/bsd/drm2/include/linux/ww_mutex.h	Sat Jul 26 21:35:06 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: ww_mutex.h,v 1.2 2014/07/22 02:38:31 riastradh Exp $	*/
+/*	$NetBSD: ww_mutex.h,v 1.3 2014/07/26 21:35:06 riastradh Exp $	*/
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -622,6 +622,8 @@ ww_mutex_unlock(struct ww_mutex *mutex)
 		mutex->wwm_state = WW_UNLOCKED;
 		break;
 	case WW_CTX:
+		KASSERT(mutex->wwm_u.ctx != NULL);
+		mutex->wwm_u.ctx->wwx_acquired--;
 		mutex->wwm_u.ctx = NULL;
 		/*
 		 * If there are any waiters with contexts, grant the

Reply via email to