kern_rwlock.c (164159) | kern_rwlock.c (164246) |
---|---|
1/*- 2 * Copyright (c) 2006 John Baldwin <jhb@FreeBSD.org> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 18 unchanged lines hidden (view full) --- 27 * SUCH DAMAGE. 28 */ 29 30/* 31 * Machine independent bits of reader/writer lock implementation. 32 */ 33 34#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2006 John Baldwin <jhb@FreeBSD.org> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 18 unchanged lines hidden (view full) --- 27 * SUCH DAMAGE. 28 */ 29 30/* 31 * Machine independent bits of reader/writer lock implementation. 32 */ 33 34#include <sys/cdefs.h> |
35__FBSDID("$FreeBSD: head/sys/kern/kern_rwlock.c 164159 2006-11-11 03:18:07Z kmacy $"); | 35__FBSDID("$FreeBSD: head/sys/kern/kern_rwlock.c 164246 2006-11-13 05:41:46Z kmacy $"); |
36 37#include "opt_ddb.h" 38 39#include <sys/param.h> 40#include <sys/ktr.h> 41#include <sys/lock.h> 42#include <sys/mutex.h> 43#include <sys/proc.h> --- 37 unchanged lines hidden (view full) --- 81#endif 82 83void 84rw_init(struct rwlock *rw, const char *name) 85{ 86 87 rw->rw_lock = RW_UNLOCKED; 88 | 36 37#include "opt_ddb.h" 38 39#include <sys/param.h> 40#include <sys/ktr.h> 41#include <sys/lock.h> 42#include <sys/mutex.h> 43#include <sys/proc.h> --- 37 unchanged lines hidden (view full) --- 81#endif 82 83void 84rw_init(struct rwlock *rw, const char *name) 85{ 86 87 rw->rw_lock = RW_UNLOCKED; 88 |
89 lock_profile_object_init(&rw->rw_object, name); | 89 lock_profile_object_init(&rw->rw_object, &lock_class_rw, name); |
90 lock_init(&rw->rw_object, &lock_class_rw, name, NULL, LO_WITNESS | 91 LO_RECURSABLE | LO_UPGRADABLE); 92} 93 94void 95rw_destroy(struct rwlock *rw) 96{ 97 --- 741 unchanged lines hidden --- | 90 lock_init(&rw->rw_object, &lock_class_rw, name, NULL, LO_WITNESS | 91 LO_RECURSABLE | LO_UPGRADABLE); 92} 93 94void 95rw_destroy(struct rwlock *rw) 96{ 97 --- 741 unchanged lines hidden --- |