Commit 4af78fd2 authored by Thomas Gleixner's avatar Thomas Gleixner

scsi: aacraid semaphore cleanup

The usage of these "mutex"es is non obvious and probably completions
in some places. Make it them semaphores.
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
parent 4d0318d2
...@@ -190,7 +190,7 @@ static int open_getadapter_fib(struct aac_dev * dev, void __user *arg) ...@@ -190,7 +190,7 @@ static int open_getadapter_fib(struct aac_dev * dev, void __user *arg)
/* /*
* Initialize the mutex used to wait for the next AIF. * Initialize the mutex used to wait for the next AIF.
*/ */
init_MUTEX_LOCKED(&fibctx->wait_sem); semaphore_init_locked(&fibctx->wait_sem);
fibctx->wait = 0; fibctx->wait = 0;
/* /*
* Initialize the fibs and set the count of fibs on * Initialize the fibs and set the count of fibs on
......
...@@ -124,7 +124,7 @@ int aac_fib_setup(struct aac_dev * dev) ...@@ -124,7 +124,7 @@ int aac_fib_setup(struct aac_dev * dev)
fibptr->hw_fib_va = hw_fib; fibptr->hw_fib_va = hw_fib;
fibptr->data = (void *) fibptr->hw_fib_va->data; fibptr->data = (void *) fibptr->hw_fib_va->data;
fibptr->next = fibptr+1; /* Forward chain the fibs */ fibptr->next = fibptr+1; /* Forward chain the fibs */
init_MUTEX_LOCKED(&fibptr->event_wait); semaphore_init_locked(&fibptr->event_wait);
spin_lock_init(&fibptr->event_lock); spin_lock_init(&fibptr->event_lock);
hw_fib->header.XferState = cpu_to_le32(0xffffffff); hw_fib->header.XferState = cpu_to_le32(0xffffffff);
hw_fib->header.SenderSize = cpu_to_le16(dev->max_fib_size); hw_fib->header.SenderSize = cpu_to_le16(dev->max_fib_size);
......
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