Commit cb542157 authored by Thomas Gleixner's avatar Thomas Gleixner Committed by Linus Torvalds

[PATCH] Lock initializer cleanup: ISDN

Use the new lock initializers DEFINE_SPIN_LOCK and DEFINE_RW_LOCK
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent c4d95edd
......@@ -143,11 +143,11 @@ struct capidev {
/* -------- global variables ---------------------------------------- */
static rwlock_t capidev_list_lock = RW_LOCK_UNLOCKED;
static DEFINE_RWLOCK(capidev_list_lock);
static LIST_HEAD(capidev_list);
#ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
static rwlock_t capiminor_list_lock = RW_LOCK_UNLOCKED;
static DEFINE_RWLOCK(capiminor_list_lock);
static LIST_HEAD(capiminor_list);
#endif /* CONFIG_ISDN_CAPI_MIDDLEWARE */
......
......@@ -140,7 +140,7 @@ typedef struct capidrv_bchan capidrv_bchan;
/* -------- data definitions ----------------------------------------- */
static capidrv_data global;
static spinlock_t global_lock = SPIN_LOCK_UNLOCKED;
static DEFINE_SPINLOCK(global_lock);
static void handle_dtrace_data(capidrv_contr *card,
int send, int level2, u8 *data, u16 len);
......
......@@ -63,9 +63,9 @@ static char capi_manufakturer[64] = "AVM Berlin";
#define NCCI2CTRL(ncci) (((ncci) >> 24) & 0x7f)
LIST_HEAD(capi_drivers);
rwlock_t capi_drivers_list_lock = RW_LOCK_UNLOCKED;
DEFINE_RWLOCK(capi_drivers_list_lock);
static rwlock_t application_lock = RW_LOCK_UNLOCKED;
static DEFINE_RWLOCK(application_lock);
static DECLARE_MUTEX(controller_sem);
struct capi20_appl *capi_applications[CAPI_MAXAPPL];
......
......@@ -29,7 +29,7 @@
ulong if_used = 0; /* number of interface users */
static struct divert_info *divert_info_head = NULL; /* head of queue */
static struct divert_info *divert_info_tail = NULL; /* pointer to last entry */
static spinlock_t divert_info_lock = SPIN_LOCK_UNLOCKED;/* lock for queue */
static DEFINE_SPINLOCK(divert_info_lock);/* lock for queue */
static wait_queue_head_t rd_queue;
/*********************************/
......
......@@ -48,7 +48,7 @@ static struct deflect_struc *table_head = NULL;
static struct deflect_struc *table_tail = NULL;
static unsigned char extern_wait_max = 4; /* maximum wait in s for external process */
spinlock_t divert_lock = SPIN_LOCK_UNLOCKED;
DEFINE_SPINLOCK(divert_lock);
/***************************/
/* timer callback function */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment