@@ -609,6 +609,7 @@ static void verify_rw_destroy(const struct lock_context *where, struct rwlock *l
609
609
print_invalid_call ("RWDESTROY" , where );
610
610
611
611
check_magic (& l -> info , "destroy" , where , SYNCH_TYPE_RW );
612
+ check_unheld_for_destroy (& l -> info , where );
612
613
613
614
l -> info .magic = DESTROYED_MAGIC ;
614
615
/* keep the synch type set to aid debugging */
@@ -621,6 +622,7 @@ static void verify_rw_lock(const struct lock_context *where, struct rwlock *l,
621
622
print_invalid_call ("RWLOCK" , where );
622
623
623
624
check_magic (& l -> info , "acquire" , where , SYNCH_TYPE_RW );
625
+ check_unheld_for_lock (& l -> info , where );
624
626
}
625
627
626
628
static void verify_rw_unlock (const struct lock_context * where , struct rwlock * l )
@@ -629,6 +631,7 @@ static void verify_rw_unlock(const struct lock_context *where, struct rwlock *l)
629
631
print_invalid_call ("RWUNLOCK" , where );
630
632
631
633
check_magic (& l -> info , "release" , where , SYNCH_TYPE_RW );
634
+ check_held_for_unlock (& l -> info , where );
632
635
}
633
636
634
637
static void verify_cond_init (const struct lock_context * where , struct cond * c )
0 commit comments