diff options
author | jhb <jhb@FreeBSD.org> | 2007-03-09 16:04:44 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2007-03-09 16:04:44 +0000 |
commit | 8e9f4f8a3953fdcea4f2de5a6005a9162ea334d7 (patch) | |
tree | 86f2a7e7abe75c0b251616c227cdca31d02d66dc /sys | |
parent | 7894c3ad2075da8bd7baf7a8a8e07142b2924575 (diff) | |
download | FreeBSD-src-8e9f4f8a3953fdcea4f2de5a6005a9162ea334d7.zip FreeBSD-src-8e9f4f8a3953fdcea4f2de5a6005a9162ea334d7.tar.gz |
Use C99-style struct member initialization for lock classes.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/kern/kern_mutex.c | 12 | ||||
-rw-r--r-- | sys/kern/kern_rwlock.c | 6 | ||||
-rw-r--r-- | sys/kern/kern_sx.c | 6 |
3 files changed, 12 insertions, 12 deletions
diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c index dc58adb..0fd5d7e 100644 --- a/sys/kern/kern_mutex.c +++ b/sys/kern/kern_mutex.c @@ -96,17 +96,17 @@ static void db_show_mtx(struct lock_object *lock); * Lock classes for sleep and spin mutexes. */ struct lock_class lock_class_mtx_sleep = { - "sleep mutex", - LC_SLEEPLOCK | LC_RECURSABLE, + .lc_name = "sleep mutex", + .lc_flags = LC_SLEEPLOCK | LC_RECURSABLE, #ifdef DDB - db_show_mtx + .lc_ddb_show = db_show_mtx, #endif }; struct lock_class lock_class_mtx_spin = { - "spin mutex", - LC_SPINLOCK | LC_RECURSABLE, + .lc_name = "spin mutex", + .lc_flags = LC_SPINLOCK | LC_RECURSABLE, #ifdef DDB - db_show_mtx + .lc_ddb_show = db_show_mtx, #endif }; diff --git a/sys/kern/kern_rwlock.c b/sys/kern/kern_rwlock.c index 274a448..59d6d83 100644 --- a/sys/kern/kern_rwlock.c +++ b/sys/kern/kern_rwlock.c @@ -54,10 +54,10 @@ static void db_show_rwlock(struct lock_object *lock); #endif struct lock_class lock_class_rw = { - "rw", - LC_SLEEPLOCK | LC_RECURSABLE | LC_UPGRADABLE, + .lc_name = "rw", + .lc_flags = LC_SLEEPLOCK | LC_RECURSABLE | LC_UPGRADABLE, #ifdef DDB - db_show_rwlock + .lc_ddb_show = db_show_rwlock, #endif }; diff --git a/sys/kern/kern_sx.c b/sys/kern/kern_sx.c index 2109c62..d41f94e 100644 --- a/sys/kern/kern_sx.c +++ b/sys/kern/kern_sx.c @@ -56,10 +56,10 @@ static void db_show_sx(struct lock_object *lock); #endif struct lock_class lock_class_sx = { - "sx", - LC_SLEEPLOCK | LC_SLEEPABLE | LC_RECURSABLE | LC_UPGRADABLE, + .lc_name = "sx", + .lc_flags = LC_SLEEPLOCK | LC_SLEEPABLE | LC_RECURSABLE | LC_UPGRADABLE, #ifdef DDB - db_show_sx + .lc_ddb_show = db_show_sx, #endif }; |