staging: wilc1000: remove mutex_init/destroy() wrappers
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 4 Sep 2015 02:43:44 +0000 (19:43 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 13 Sep 2015 01:24:40 +0000 (18:24 -0700)
Just call the real functions.

Cc: Johnny Kim <johnny.kim@atmel.com>
Cc: Rachel Kim <rachel.kim@atmel.com>
Cc: Dean Lee <dean.lee@atmel.com>
Cc: Chris Park <chris.park@atmel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wilc1000/linux_wlan.c

index dace77e046b2ad3b0598856defe6d6b4c5640487..7b68d123d270219618e304ba90afad39b2c36bfe 100644 (file)
@@ -589,18 +589,6 @@ void linux_wlan_unlock(void *vp)
                PRINT_ER("Failed, mutex is NULL\n");
 }
 
-static void linux_wlan_init_mutex(char *lockName, void *plock, int count)
-{
-       mutex_init((struct mutex *)plock);
-       PRINT_D(LOCK_DBG, "Initializing mutex [%s][%p]\n", lockName, plock);
-
-}
-
-static void linux_wlan_deinit_mutex(void *plock)
-{
-       mutex_destroy((struct mutex *)plock);
-}
-
 static void linux_wlan_spin_lock(void *vp, unsigned long *flags)
 {
        unsigned long lflags;
@@ -1317,10 +1305,9 @@ int wlan_init_locks(linux_wlan_t *p_nic)
 
        PRINT_D(INIT_DBG, "Initializing Locks ...\n");
 
-       /*initialize mutexes*/
-       linux_wlan_init_mutex("hif_lock/hif_cs", &g_linux_wlan->hif_cs, 1);
-       linux_wlan_init_mutex("rxq_lock/rxq_cs", &g_linux_wlan->rxq_cs, 1);
-       linux_wlan_init_mutex("txq_lock/txq_cs", &g_linux_wlan->txq_cs, 1);
+       mutex_init(&g_linux_wlan->hif_cs);
+       mutex_init(&g_linux_wlan->rxq_cs);
+       mutex_init(&g_linux_wlan->txq_cs);
 
        /*Added by Amr - BugID_4720*/
        spin_lock_init(&g_linux_wlan->txq_spinlock);
@@ -1349,13 +1336,13 @@ static int wlan_deinit_locks(linux_wlan_t *nic)
        PRINT_D(INIT_DBG, "De-Initializing Locks\n");
 
        if (&g_linux_wlan->hif_cs != NULL)
-               linux_wlan_deinit_mutex(&g_linux_wlan->hif_cs);
+               mutex_destroy(&g_linux_wlan->hif_cs);
 
        if (&g_linux_wlan->rxq_cs != NULL)
-               linux_wlan_deinit_mutex(&g_linux_wlan->rxq_cs);
+               mutex_destroy(&g_linux_wlan->rxq_cs);
 
        if (&g_linux_wlan->txq_cs != NULL)
-               linux_wlan_deinit_mutex(&g_linux_wlan->txq_cs);
+               mutex_destroy(&g_linux_wlan->txq_cs);
 
        if (&g_linux_wlan->rxq_event != NULL)
                linux_wlan_deinit_lock(&g_linux_wlan->rxq_event);