From b7c3c8a43d95e38d4bb942d9113aa9c9e24f0f23 Mon Sep 17 00:00:00 2001 From: Samy Al Bahra Date: Thu, 17 Apr 2014 13:13:06 -0400 Subject: [PATCH] ck_rwlock: Use sub for unlatch operation. --- include/ck_rwlock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/ck_rwlock.h b/include/ck_rwlock.h index 57d6aa7..a88ff10 100644 --- a/include/ck_rwlock.h +++ b/include/ck_rwlock.h @@ -128,7 +128,7 @@ CK_CC_INLINE static void ck_rwlock_write_unlatch(ck_rwlock_t *rw) { - ck_pr_add_32(&rw->n_readers, 1UL << CK_RWLOCK_LATCH_SHIFT); + ck_pr_sub_32(&rw->n_readers, 1UL << CK_RWLOCK_LATCH_SHIFT); return; }