diff options
author | Richard Braun <rbraun@sceen.net> | 2014-08-15 20:55:19 +0200 |
---|---|---|
committer | Richard Braun <rbraun@sceen.net> | 2014-08-15 20:55:19 +0200 |
commit | eefc813bc7424112708992dfbf24def73c92f5de (patch) | |
tree | 69d6719073958c49c62c57c8ce5e1635b45950bb | |
parent | 40502c5f7465300b2bc0cb44325db38b23449deb (diff) |
Remove static initializer macros
These initializers are unnecessary, unused, and cumbersome to maintain.
-rw-r--r-- | kern/condition.h | 3 | ||||
-rw-r--r-- | kern/list.h | 5 | ||||
-rw-r--r-- | kern/mutex.h | 3 | ||||
-rw-r--r-- | kern/rbtree.h | 5 | ||||
-rw-r--r-- | kern/spinlock.h | 2 |
5 files changed, 0 insertions, 18 deletions
diff --git a/kern/condition.h b/kern/condition.h index 9cd581a9..3de39be2 100644 --- a/kern/condition.h +++ b/kern/condition.h @@ -29,9 +29,6 @@ struct condition; -#define CONDITION_INITIALIZER(condition) \ - { SPINLOCK_INITIALIZER, NULL, LIST_INITIALIZER((condition).waiters) } - static inline void condition_init(struct condition *condition) { diff --git a/kern/list.h b/kern/list.h index 29ecfcb4..e64f5fd9 100644 --- a/kern/list.h +++ b/kern/list.h @@ -40,11 +40,6 @@ struct list { }; /* - * Static list initializer. - */ -#define LIST_INITIALIZER(list) { &(list), &(list) } - -/* * Initialize a list. */ static inline void diff --git a/kern/mutex.h b/kern/mutex.h index 011f7033..d3fe74b5 100644 --- a/kern/mutex.h +++ b/kern/mutex.h @@ -31,9 +31,6 @@ struct mutex; -#define MUTEX_INITIALIZER(mutex) \ - { MUTEX_UNLOCKED, SPINLOCK_INITIALIZER, LIST_INITIALIZER((mutex).waiters) } - static inline void mutex_init(struct mutex *mutex) { diff --git a/kern/rbtree.h b/kern/rbtree.h index 6de1871d..740c8194 100644 --- a/kern/rbtree.h +++ b/kern/rbtree.h @@ -41,11 +41,6 @@ struct rbtree_node; */ struct rbtree; -/* - * Static tree initializer. - */ -#define RBTREE_INITIALIZER { NULL } - #include <kern/rbtree_i.h> /* diff --git a/kern/spinlock.h b/kern/spinlock.h index 8e67df3f..1cc9b08f 100644 --- a/kern/spinlock.h +++ b/kern/spinlock.h @@ -32,8 +32,6 @@ struct spinlock; -#define SPINLOCK_INITIALIZER { 0 } - static inline void spinlock_init(struct spinlock *lock) { |