diff options
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/ath6kl/os/linux/ar6000_raw_if.c | 4 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmfmac/dhd_linux.c | 4 | ||||
-rw-r--r-- | drivers/staging/brcm80211/sys/wl_mac80211.c | 2 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/dt9812.c | 2 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/usbdux.c | 4 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/usbduxfast.c | 4 | ||||
-rw-r--r-- | drivers/staging/msm/msm_fb.c | 4 | ||||
-rw-r--r-- | drivers/staging/rtl8712/osdep_service.h | 2 | ||||
-rw-r--r-- | drivers/staging/smbfs/inode.c | 2 | ||||
-rw-r--r-- | drivers/staging/westbridge/astoria/block/cyasblkdev_block.c | 2 | ||||
-rw-r--r-- | drivers/staging/westbridge/astoria/block/cyasblkdev_queue.c | 2 |
11 files changed, 16 insertions, 16 deletions
diff --git a/drivers/staging/ath6kl/os/linux/ar6000_raw_if.c b/drivers/staging/ath6kl/os/linux/ar6000_raw_if.c index c196098f0859..6b8eeea475cf 100644 --- a/drivers/staging/ath6kl/os/linux/ar6000_raw_if.c +++ b/drivers/staging/ath6kl/os/linux/ar6000_raw_if.c @@ -198,8 +198,8 @@ int ar6000_htc_raw_open(AR_SOFTC_T *ar) for (streamID = HTC_RAW_STREAM_0; streamID < HTC_RAW_STREAM_NUM_MAX; streamID++) { /* Initialize the data structures */ - init_MUTEX(&arRaw->raw_htc_read_sem[streamID]); - init_MUTEX(&arRaw->raw_htc_write_sem[streamID]); + sema_init(&arRaw->raw_htc_read_sem[streamID], 1); + sema_init(&arRaw->raw_htc_write_sem[streamID], 1); init_waitqueue_head(&arRaw->raw_htc_read_queue[streamID]); init_waitqueue_head(&arRaw->raw_htc_write_queue[streamID]); diff --git a/drivers/staging/brcm80211/brcmfmac/dhd_linux.c b/drivers/staging/brcm80211/brcmfmac/dhd_linux.c index e5357875661f..bbbe7c5f7492 100644 --- a/drivers/staging/brcm80211/brcmfmac/dhd_linux.c +++ b/drivers/staging/brcm80211/brcmfmac/dhd_linux.c @@ -1929,7 +1929,7 @@ dhd_pub_t *dhd_attach(osl_t *osh, struct dhd_bus *bus, uint bus_hdrlen) goto fail; net->netdev_ops = NULL; - init_MUTEX(&dhd->proto_sem); + sema_init(&dhd->proto_sem, 1); /* Initialize other structure content */ init_waitqueue_head(&dhd->ioctl_resp_wait); init_waitqueue_head(&dhd->ctrl_wait); @@ -1977,7 +1977,7 @@ dhd_pub_t *dhd_attach(osl_t *osh, struct dhd_bus *bus, uint bus_hdrlen) dhd->timer.function = dhd_watchdog; /* Initialize thread based operation and lock */ - init_MUTEX(&dhd->sdsem); + sema_init(&dhd->sdsem, 1); if ((dhd_watchdog_prio >= 0) && (dhd_dpc_prio >= 0)) dhd->threads_only = true; else diff --git a/drivers/staging/brcm80211/sys/wl_mac80211.c b/drivers/staging/brcm80211/sys/wl_mac80211.c index ad635ee7758e..d060377629ac 100644 --- a/drivers/staging/brcm80211/sys/wl_mac80211.c +++ b/drivers/staging/brcm80211/sys/wl_mac80211.c @@ -866,7 +866,7 @@ static wl_info_t *wl_attach(u16 vendor, u16 device, unsigned long regs, spin_lock_init(&wl->rpcq_lock); spin_lock_init(&wl->txq_lock); - init_MUTEX(&wl->sem); + sema_init(&wl->sem, 1); #else spin_lock_init(&wl->lock); spin_lock_init(&wl->isr_lock); diff --git a/drivers/staging/comedi/drivers/dt9812.c b/drivers/staging/comedi/drivers/dt9812.c index 0560a7451512..06059850dae2 100644 --- a/drivers/staging/comedi/drivers/dt9812.c +++ b/drivers/staging/comedi/drivers/dt9812.c @@ -262,7 +262,7 @@ struct dt9812_usb_cmd { #define DT9812_NUM_SLOTS 16 -static DECLARE_MUTEX(dt9812_mutex); +static DEFINE_SEMAPHORE(dt9812_mutex); static const struct usb_device_id dt9812_table[] = { {USB_DEVICE(0x0867, 0x9812)}, diff --git a/drivers/staging/comedi/drivers/usbdux.c b/drivers/staging/comedi/drivers/usbdux.c index 6131e2dd0591..1f177a67ff11 100644 --- a/drivers/staging/comedi/drivers/usbdux.c +++ b/drivers/staging/comedi/drivers/usbdux.c @@ -315,7 +315,7 @@ struct usbduxsub { */ static struct usbduxsub usbduxsub[NUMUSBDUX]; -static DECLARE_MUTEX(start_stop_sem); +static DEFINE_SEMAPHORE(start_stop_sem); /* * Stops the data acquision @@ -2367,7 +2367,7 @@ static int usbduxsub_probe(struct usb_interface *uinterf, dev_dbg(dev, "comedi_: usbdux: " "usbduxsub[%d] is ready to connect to comedi.\n", index); - init_MUTEX(&(usbduxsub[index].sem)); + sema_init(&(usbduxsub[index].sem), 1); /* save a pointer to the usb device */ usbduxsub[index].usbdev = udev; diff --git a/drivers/staging/comedi/drivers/usbduxfast.c b/drivers/staging/comedi/drivers/usbduxfast.c index 0a164a9a66c3..5b15e6df54e6 100644 --- a/drivers/staging/comedi/drivers/usbduxfast.c +++ b/drivers/staging/comedi/drivers/usbduxfast.c @@ -199,7 +199,7 @@ struct usbduxfastsub_s { */ static struct usbduxfastsub_s usbduxfastsub[NUMUSBDUXFAST]; -static DECLARE_MUTEX(start_stop_sem); +static DEFINE_SEMAPHORE(start_stop_sem); /* * bulk transfers to usbduxfast @@ -1504,7 +1504,7 @@ static int usbduxfastsub_probe(struct usb_interface *uinterf, "connect to comedi.\n", index); #endif - init_MUTEX(&(usbduxfastsub[index].sem)); + sema_init(&(usbduxfastsub[index].sem), 1); /* save a pointer to the usb device */ usbduxfastsub[index].usbdev = udev; diff --git a/drivers/staging/msm/msm_fb.c b/drivers/staging/msm/msm_fb.c index ea268edbf43b..23fa049b51f2 100644 --- a/drivers/staging/msm/msm_fb.c +++ b/drivers/staging/msm/msm_fb.c @@ -1158,7 +1158,7 @@ static int msm_fb_release(struct fb_info *info, int user) return ret; } -DECLARE_MUTEX(msm_fb_pan_sem); +DEFINE_SEMAPHORE(msm_fb_pan_sem); static int msm_fb_pan_display(struct fb_var_screeninfo *var, struct fb_info *info) @@ -1962,7 +1962,7 @@ static int msmfb_overlay_play(struct fb_info *info, unsigned long *argp) #endif -DECLARE_MUTEX(msm_fb_ioctl_ppp_sem); +DEFINE_SEMAPHORE(msm_fb_ioctl_ppp_sem); DEFINE_MUTEX(msm_fb_ioctl_lut_sem); DEFINE_MUTEX(msm_fb_ioctl_hist_sem); diff --git a/drivers/staging/rtl8712/osdep_service.h b/drivers/staging/rtl8712/osdep_service.h index 7fca42c7c0d4..d1674cd282dc 100644 --- a/drivers/staging/rtl8712/osdep_service.h +++ b/drivers/staging/rtl8712/osdep_service.h @@ -161,7 +161,7 @@ static inline u32 _down_sema(struct semaphore *sema) static inline void _rtl_rwlock_init(struct semaphore *prwlock) { - init_MUTEX(prwlock); + sema_init(prwlock, 1); } static inline void _init_listhead(struct list_head *list) diff --git a/drivers/staging/smbfs/inode.c b/drivers/staging/smbfs/inode.c index f9c493591ce7..540a984bb516 100644 --- a/drivers/staging/smbfs/inode.c +++ b/drivers/staging/smbfs/inode.c @@ -537,7 +537,7 @@ static int smb_fill_super(struct super_block *sb, void *raw_data, int silent) server->mnt = NULL; server->sock_file = NULL; init_waitqueue_head(&server->conn_wq); - init_MUTEX(&server->sem); + sema_init(&server->sem, 1); INIT_LIST_HEAD(&server->entry); INIT_LIST_HEAD(&server->xmitq); INIT_LIST_HEAD(&server->recvq); diff --git a/drivers/staging/westbridge/astoria/block/cyasblkdev_block.c b/drivers/staging/westbridge/astoria/block/cyasblkdev_block.c index f428a7af357a..e1851f00be56 100644 --- a/drivers/staging/westbridge/astoria/block/cyasblkdev_block.c +++ b/drivers/staging/westbridge/astoria/block/cyasblkdev_block.c @@ -157,7 +157,7 @@ struct cyasblkdev_blk_data { /* pointer to west bridge block data device superstructure */ static struct cyasblkdev_blk_data *gl_bd; -static DECLARE_MUTEX(open_lock); +static DEFINE_SEMAPHORE(open_lock); /* local forwardd declarationss */ static cy_as_device_handle *cyas_dev_handle; diff --git a/drivers/staging/westbridge/astoria/block/cyasblkdev_queue.c b/drivers/staging/westbridge/astoria/block/cyasblkdev_queue.c index 24e959eca412..0bbb8a3e191d 100644 --- a/drivers/staging/westbridge/astoria/block/cyasblkdev_queue.c +++ b/drivers/staging/westbridge/astoria/block/cyasblkdev_queue.c @@ -334,7 +334,7 @@ int cyasblkdev_init_queue(struct cyasblkdev_queue *bq, spinlock_t *lock) init_completion(&bq->thread_complete); init_waitqueue_head(&bq->thread_wq); - init_MUTEX(&bq->thread_sem); + sema_init(&bq->thread_sem, 1); ret = kernel_thread(cyasblkdev_queue_thread, bq, CLONE_KERNEL); if (ret >= 0) { |