This patch removes wilc_dbg function because it's not any more.
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/linux_wlan.c | 4 ----
drivers/staging/wilc1000/wilc_wfi_netdevice.h | 2 --
drivers/staging/wilc1000/wilc_wlan.c | 2 --
3 files changed, 8 deletions(-)
diff --git a/drivers/staging/wilc1000/linux_wlan.c b/drivers/staging/wilc1000/linux_wlan.c
index 749dfc74..912e8ec 100644
--- a/drivers/staging/wilc1000/linux_wlan.c
+++ b/drivers/staging/wilc1000/linux_wlan.c
@@ -224,10 +224,6 @@ static void deinit_irq(struct net_device *dev)
}
}
-void wilc_dbg(u8 *buff)
-{
-}
-
int wilc_lock_timeout(struct wilc *nic, void *vp, u32 timeout)
{
/* FIXME: replace with mutex_lock or wait_for_completion */
diff --git a/drivers/staging/wilc1000/wilc_wfi_netdevice.h b/drivers/staging/wilc1000/wilc_wfi_netdevice.h
index 3077f5d4..786f5fd 100644
--- a/drivers/staging/wilc1000/wilc_wfi_netdevice.h
+++ b/drivers/staging/wilc1000/wilc_wfi_netdevice.h
@@ -228,8 +228,6 @@ int wilc1000_wlan_init(struct net_device *dev, struct wilc_vif *vif);
void wilc_frmw_to_linux(struct wilc *wilc, u8 *buff, u32 size, u32 pkt_offset);
void wilc_mac_indicate(struct wilc *wilc, int flag);
-void wilc_dbg(u8 *buff);
-
int wilc_lock_timeout(struct wilc *wilc, void *, u32 timeout);
void wilc_netdev_cleanup(struct wilc *wilc);
int wilc_netdev_init(struct wilc **wilc, struct device *, int io_type, int gpio,
diff --git a/drivers/staging/wilc1000/wilc_wlan.c b/drivers/staging/wilc1000/wilc_wlan.c
index e7ae359..90b6528 100644
--- a/drivers/staging/wilc1000/wilc_wlan.c
+++ b/drivers/staging/wilc1000/wilc_wlan.c
@@ -15,8 +15,6 @@ static void wilc_debug(u32 flag, char *fmt, ...)
va_start(args, fmt);
vsprintf(buf, fmt, args);
va_end(args);
-
- wilc_dbg(buf);
}
}
--
1.9.1
This patch removes unnecessary wilc_debug print log and the check routine.
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/wilc_wlan.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/staging/wilc1000/wilc_wlan.c b/drivers/staging/wilc1000/wilc_wlan.c
index 0843ccf..f0ac47f 100644
--- a/drivers/staging/wilc1000/wilc_wlan.c
+++ b/drivers/staging/wilc1000/wilc_wlan.c
@@ -523,9 +523,6 @@ void chip_wakeup(struct wilc *wilc)
wilc->hif_func->hif_read_reg(wilc, 0xf1,
&clk_status_reg);
-
- if ((clk_status_reg & 0x1) == 0)
- wilc_debug(N_ERR, "clocks still OFF. Wake up failed\n");
}
if ((clk_status_reg & 0x1) == 0) {
wilc->hif_func->hif_write_reg(wilc, 0xf0,
--
1.9.1
On Mon, Feb 22, 2016 at 11:42:42AM +0000, Kim, Leo wrote:
> Dear Dan,
>
> This patch is subject "removes unnecessary wilc_debug print log".
I'm fine with you fixing it up in a later patch, but you should not be defending
this patch as valid way to do things.
The rule is "do one thing at a time", not "do half a thing at a time."
In the original code the if statement was required because it was
determining when to print, but now it is a confusing unneeded line of
code. I'm not asking for an additional unrelated cleanup for something that was
already there in the original code. It was this patch which introduced
the problem (the stray unneeded line of code).
Also I had already asked you to redo this on Feb 19.
Part of the reason that we like people to "do one thing per patch" is that
people promise they will clean things up in the future but they get distracted
and forget.
regards,
dan carpenter
Dear Dan,
This patch is subject "removes unnecessary wilc_debug print log".
Your advice are correct but in this patch is not applied.
I'll be applied to next patch about the your good advice.
Would be okay?
Always appreciate your positive advice & great information.
?Thanks, BR
?Leo
-----Original Message-----
From: Dan Carpenter [mailto:[email protected]]
Sent: Monday, February 22, 2016 7:45 PM
To: Kim, Leo <[email protected]>
Cc: [email protected]; [email protected]; Park, Chris <[email protected]>; Shin, Austin <[email protected]>; [email protected]; Ferre, Nicolas <[email protected]>; Cho, Tony <[email protected]>; Abozaeid, Adham <[email protected]>
Subject: Re: [PATCH RESEND 04/10] staging: wilc1000: removes unnecessary wilc_debug print log
On Mon, Feb 22, 2016 at 01:41:13PM +0900, Leo Kim wrote:
> This patch removes unnecessary wilc_debug print log.
> The print log was written when if condition fail.
> The condition is chip-id check function.
> Also, replaces this condition with normal function.
>
> Signed-off-by: Leo Kim <[email protected]>
> ---
> drivers/staging/wilc1000/wilc_wlan.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/staging/wilc1000/wilc_wlan.c
> b/drivers/staging/wilc1000/wilc_wlan.c
> index f0ac47f..34018a1 100644
> --- a/drivers/staging/wilc1000/wilc_wlan.c
> +++ b/drivers/staging/wilc1000/wilc_wlan.c
> @@ -502,9 +502,7 @@ void chip_wakeup(struct wilc *wilc)
>
> do {
> usleep_range(2 * 1000, 2 * 1000);
> - if ((wilc_get_chipid(wilc, true) == 0))
> - wilc_debug(N_ERR, "Couldn't read chip id. Wake up failed\n");
> -
> + wilc_get_chipid(wilc, true);
Remove this as well. Don't leave random no-op function calls lying around.
> } while ((wilc_get_chipid(wilc, true) == 0) && ((++trials % 3) ==
> 0));
^^^^^^^^^^^^
This doesn't work as intended either.
regards,
dan carpenter
Dear Dan,
Thank you your great comments.
I will be not forget your advice.
Please understand that if you have a misunderstanding.
Thank you & Best Regards.
Leo
-----Original Message-----
From: Dan Carpenter [mailto:[email protected]]
Sent: Monday, February 22, 2016 11:44 PM
To: Kim, Leo <[email protected]>
Cc: [email protected]; [email protected]; Park, Chris <[email protected]>; Shin, Austin <[email protected]>; [email protected]; Ferre, Nicolas <[email protected]>; Cho, Tony <[email protected]>; Abozaeid, Adham <[email protected]>
Subject: Re: [PATCH RESEND 04/10] staging: wilc1000: removes unnecessary wilc_debug print log
On Mon, Feb 22, 2016 at 11:42:42AM +0000, Kim, Leo wrote:
> Dear Dan,
>
> This patch is subject "removes unnecessary wilc_debug print log".
I'm fine with you fixing it up in a later patch, but you should not be defending this patch as valid way to do things.
The rule is "do one thing at a time", not "do half a thing at a time."
In the original code the if statement was required because it was determining when to print, but now it is a confusing unneeded line of code. I'm not asking for an additional unrelated cleanup for something that was already there in the original code. It was this patch which introduced the problem (the stray unneeded line of code).
Also I had already asked you to redo this on Feb 19.
Part of the reason that we like people to "do one thing per patch" is that people promise they will clean things up in the future but they get distracted and forget.
regards,
dan carpenter
This patches replaces wilc_debug with netdev_err.
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/wilc_wlan.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/wilc1000/wilc_wlan.c b/drivers/staging/wilc1000/wilc_wlan.c
index 90b6528..0843ccf 100644
--- a/drivers/staging/wilc1000/wilc_wlan.c
+++ b/drivers/staging/wilc1000/wilc_wlan.c
@@ -1389,18 +1389,18 @@ static u32 init_chip(struct net_device *dev)
if ((chipid & 0xfff) != 0xa0) {
ret = wilc->hif_func->hif_read_reg(wilc, 0x1118, ®);
if (!ret) {
- wilc_debug(N_ERR, "[wilc start]: fail read reg 0x1118 ...\n");
+ netdev_err(dev, "fail read reg 0x1118\n");
return ret;
}
reg |= BIT(0);
ret = wilc->hif_func->hif_write_reg(wilc, 0x1118, reg);
if (!ret) {
- wilc_debug(N_ERR, "[wilc start]: fail write reg 0x1118 ...\n");
+ netdev_err(dev, "fail write reg 0x1118\n");
return ret;
}
ret = wilc->hif_func->hif_write_reg(wilc, 0xc0000, 0x71);
if (!ret) {
- wilc_debug(N_ERR, "[wilc start]: fail write reg 0xc0000 ...\n");
+ netdev_err(dev, "fail write reg 0xc0000\n");
return ret;
}
}
--
1.9.1
From: Chris Park <[email protected]>
This patch moves MODALIS and GPIO_NUM define to wilc_wlan.h file.
MODALIS and GPIO_NUM define are used to two files (wilc_sdio.c,
wilc_spi.c), these files already include wilc_wlan.h file in common.
Signed-off-by: Chris Park <[email protected]>
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/linux_wlan_common.h | 2 --
drivers/staging/wilc1000/wilc_wlan.h | 2 ++
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/wilc1000/linux_wlan_common.h b/drivers/staging/wilc1000/linux_wlan_common.h
index 5a53512..37848c0 100644
--- a/drivers/staging/wilc1000/linux_wlan_common.h
+++ b/drivers/staging/wilc1000/linux_wlan_common.h
@@ -31,7 +31,5 @@
#else
/* base on SAMA5D3_Xplained Board */
- #define MODALIAS "WILC_SPI"
- #define GPIO_NUM 0x44
#endif
#endif
diff --git a/drivers/staging/wilc1000/wilc_wlan.h b/drivers/staging/wilc1000/wilc_wlan.h
index 792d338..bcd4bfa 100644
--- a/drivers/staging/wilc1000/wilc_wlan.h
+++ b/drivers/staging/wilc1000/wilc_wlan.h
@@ -131,6 +131,8 @@
#define LINUX_RX_SIZE (96 * 1024)
#define LINUX_TX_SIZE (64 * 1024)
+#define MODALIAS "WILC_SPI"
+#define GPIO_NUM 0x44
/*******************************************/
/* E0 and later Interrupt flags. */
/*******************************************/
--
1.9.1
From: Chris Park <[email protected]>
This patch removes useless define in linux_wlan_common.h file
Signed-off-by: Chris Park <[email protected]>
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/linux_wlan_common.h | 32 ----------------------------
1 file changed, 32 deletions(-)
diff --git a/drivers/staging/wilc1000/linux_wlan_common.h b/drivers/staging/wilc1000/linux_wlan_common.h
index 37848c0..18d902b 100644
--- a/drivers/staging/wilc1000/linux_wlan_common.h
+++ b/drivers/staging/wilc1000/linux_wlan_common.h
@@ -1,35 +1,3 @@
#ifndef LINUX_WLAN_COMMON_H
#define LINUX_WLAN_COMMON_H
-
-#if defined(BEAGLE_BOARD)
- #define SPI_CHANNEL 4
-
- #if SPI_CHANNEL == 4
- #define MODALIAS "wilc_spi4"
- #define GPIO_NUM 162
- #else
- #define MODALIAS "wilc_spi3"
- #define GPIO_NUM 133
- #endif
-#elif defined(PLAT_WMS8304) /* rachel */
- #define MODALIAS "wilc_spi"
- #define GPIO_NUM 139
-#elif defined(PLAT_RKXXXX)
- #define MODALIAS "WILC_IRQ"
- #define GPIO_NUM RK30_PIN3_PD2 /* RK30_PIN3_PA1 */
-/* RK30_PIN3_PD2 */
-/* RK2928_PIN1_PA7 */
-
-#elif defined(CUSTOMER_PLATFORM)
-/*
- TODO : specify MODALIAS name and GPIO number. This is certainly necessary for SPI interface.
- *
- * ex)
- * #define MODALIAS "WILC_SPI"
- * #define GPIO_NUM 139
- */
-
-#else
-/* base on SAMA5D3_Xplained Board */
-#endif
#endif
--
1.9.1
On Mon, Feb 22, 2016 at 01:41:13PM +0900, Leo Kim wrote:
> This patch removes unnecessary wilc_debug print log.
> The print log was written when if condition fail.
> The condition is chip-id check function.
> Also, replaces this condition with normal function.
>
> Signed-off-by: Leo Kim <[email protected]>
> ---
> drivers/staging/wilc1000/wilc_wlan.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/staging/wilc1000/wilc_wlan.c b/drivers/staging/wilc1000/wilc_wlan.c
> index f0ac47f..34018a1 100644
> --- a/drivers/staging/wilc1000/wilc_wlan.c
> +++ b/drivers/staging/wilc1000/wilc_wlan.c
> @@ -502,9 +502,7 @@ void chip_wakeup(struct wilc *wilc)
>
> do {
> usleep_range(2 * 1000, 2 * 1000);
> - if ((wilc_get_chipid(wilc, true) == 0))
> - wilc_debug(N_ERR, "Couldn't read chip id. Wake up failed\n");
> -
> + wilc_get_chipid(wilc, true);
Remove this as well. Don't leave random no-op function calls lying
around.
> } while ((wilc_get_chipid(wilc, true) == 0) && ((++trials % 3) == 0));
^^^^^^^^^^^^
This doesn't work as intended either.
regards,
dan carpenter
This patch removes unnecessary wilc_debug print log.
The print log was written when if condition fail.
The condition is chip-id check function.
Also, replaces this condition with normal function.
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/wilc_wlan.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/staging/wilc1000/wilc_wlan.c b/drivers/staging/wilc1000/wilc_wlan.c
index f0ac47f..34018a1 100644
--- a/drivers/staging/wilc1000/wilc_wlan.c
+++ b/drivers/staging/wilc1000/wilc_wlan.c
@@ -502,9 +502,7 @@ void chip_wakeup(struct wilc *wilc)
do {
usleep_range(2 * 1000, 2 * 1000);
- if ((wilc_get_chipid(wilc, true) == 0))
- wilc_debug(N_ERR, "Couldn't read chip id. Wake up failed\n");
-
+ wilc_get_chipid(wilc, true);
} while ((wilc_get_chipid(wilc, true) == 0) && ((++trials % 3) == 0));
} while (wilc_get_chipid(wilc, true) == 0);
--
1.9.1
From: Chris Park <[email protected]>
This patch moves WILC_MULTICAST_TABLE_SIZE define to wilc_wlan_if.h file.
This define is used to three files(host_interface.c,host_interface.h,
linux_wlan.c) these files already include wilc_wlan_if.h file in common.
Signed-off-by: Chris Park <[email protected]>
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/linux_wlan_common.h | 2 --
drivers/staging/wilc1000/wilc_wlan_if.h | 2 +-
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/staging/wilc1000/linux_wlan_common.h b/drivers/staging/wilc1000/linux_wlan_common.h
index aa2c026..5a53512 100644
--- a/drivers/staging/wilc1000/linux_wlan_common.h
+++ b/drivers/staging/wilc1000/linux_wlan_common.h
@@ -1,8 +1,6 @@
#ifndef LINUX_WLAN_COMMON_H
#define LINUX_WLAN_COMMON_H
-#define WILC_MULTICAST_TABLE_SIZE 8
-
#if defined(BEAGLE_BOARD)
#define SPI_CHANNEL 4
diff --git a/drivers/staging/wilc1000/wilc_wlan_if.h b/drivers/staging/wilc1000/wilc_wlan_if.h
index 269c56e..c33f7a6 100644
--- a/drivers/staging/wilc1000/wilc_wlan_if.h
+++ b/drivers/staging/wilc1000/wilc_wlan_if.h
@@ -95,7 +95,7 @@ typedef void (*wilc_tx_complete_func_t)(void *, int);
* Wlan Configuration ID
*
********************************************/
-
+#define WILC_MULTICAST_TABLE_SIZE 8
#define MAX_SSID_LEN 33
#define MAX_RATES_SUPPORTED 12
--
1.9.1
From: Chris Park <[email protected]>
This patch removes linux_wlan_common.h file and also removes the following
preprocessor at files that include it:
- #include 'linux_wlan_common.h'
Signed-off-by: Chris Park <[email protected]>
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/linux_mon.c | 1 -
drivers/staging/wilc1000/linux_wlan.c | 1 -
drivers/staging/wilc1000/linux_wlan_common.h | 3 ---
drivers/staging/wilc1000/wilc_msgqueue.c | 1 -
drivers/staging/wilc1000/wilc_spi.c | 1 -
drivers/staging/wilc1000/wilc_wlan_if.h | 1 -
6 files changed, 8 deletions(-)
delete mode 100644 drivers/staging/wilc1000/linux_wlan_common.h
diff --git a/drivers/staging/wilc1000/linux_mon.c b/drivers/staging/wilc1000/linux_mon.c
index 6347471..7d9e5de 100644
--- a/drivers/staging/wilc1000/linux_mon.c
+++ b/drivers/staging/wilc1000/linux_mon.c
@@ -7,7 +7,6 @@
* @version 1.0
*/
#include "wilc_wfi_cfgoperations.h"
-#include "linux_wlan_common.h"
#include "wilc_wlan_if.h"
#include "wilc_wlan.h"
diff --git a/drivers/staging/wilc1000/linux_wlan.c b/drivers/staging/wilc1000/linux_wlan.c
index 912e8ec..eafde6f 100644
--- a/drivers/staging/wilc1000/linux_wlan.c
+++ b/drivers/staging/wilc1000/linux_wlan.c
@@ -1,5 +1,4 @@
#include "wilc_wfi_cfgoperations.h"
-#include "linux_wlan_common.h"
#include "wilc_wlan_if.h"
#include "wilc_wlan.h"
diff --git a/drivers/staging/wilc1000/linux_wlan_common.h b/drivers/staging/wilc1000/linux_wlan_common.h
deleted file mode 100644
index 18d902b..0000000
--- a/drivers/staging/wilc1000/linux_wlan_common.h
+++ /dev/null
@@ -1,3 +0,0 @@
-#ifndef LINUX_WLAN_COMMON_H
-#define LINUX_WLAN_COMMON_H
-#endif
diff --git a/drivers/staging/wilc1000/wilc_msgqueue.c b/drivers/staging/wilc1000/wilc_msgqueue.c
index 780ddd3..6cb894e 100644
--- a/drivers/staging/wilc1000/wilc_msgqueue.c
+++ b/drivers/staging/wilc1000/wilc_msgqueue.c
@@ -1,7 +1,6 @@
#include "wilc_msgqueue.h"
#include <linux/spinlock.h>
-#include "linux_wlan_common.h"
#include <linux/errno.h>
#include <linux/slab.h>
diff --git a/drivers/staging/wilc1000/wilc_spi.c b/drivers/staging/wilc1000/wilc_spi.c
index b55a0c3f..eb1e76d 100644
--- a/drivers/staging/wilc1000/wilc_spi.c
+++ b/drivers/staging/wilc1000/wilc_spi.c
@@ -18,7 +18,6 @@
#include <linux/spi/spi.h>
#include <linux/of_gpio.h>
-#include "linux_wlan_common.h"
#include <linux/string.h>
#include "wilc_wlan_if.h"
#include "wilc_wlan.h"
diff --git a/drivers/staging/wilc1000/wilc_wlan_if.h b/drivers/staging/wilc1000/wilc_wlan_if.h
index c33f7a6..fbe34eb 100644
--- a/drivers/staging/wilc1000/wilc_wlan_if.h
+++ b/drivers/staging/wilc1000/wilc_wlan_if.h
@@ -11,7 +11,6 @@
#define WILC_WLAN_IF_H
#include <linux/semaphore.h>
-#include "linux_wlan_common.h"
#include <linux/netdevice.h>
/********************************************
--
1.9.1
This patch removes unnecessary variable of wilc_mac_cfg_t structure.
The variable is debug print function pointer.
Removes all what used this variable.
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/wilc_wlan_cfg.c | 7 -------
1 file changed, 7 deletions(-)
diff --git a/drivers/staging/wilc1000/wilc_wlan_cfg.c b/drivers/staging/wilc1000/wilc_wlan_cfg.c
index 56455f4..deff886 100644
--- a/drivers/staging/wilc1000/wilc_wlan_cfg.c
+++ b/drivers/staging/wilc1000/wilc_wlan_cfg.c
@@ -20,8 +20,6 @@
********************************************/
struct wilc_mac_cfg {
- wilc_debug_func dPrint;
-
int mac_status;
u8 mac_address[7];
u8 ip_address[5];
@@ -389,8 +387,6 @@ int wilc_wlan_cfg_set_wid(u8 *frame, u32 offset, u16 id, u8 *buf, int size)
ret = wilc_wlan_cfg_set_str(frame, offset, id, buf, size);
} else if (type == 4) { /* binary command */
ret = wilc_wlan_cfg_set_bin(frame, offset, id, buf, size);
- } else {
- g_mac.dPrint(N_ERR, "illegal id\n");
}
return ret;
@@ -481,8 +477,6 @@ int wilc_wlan_cfg_get_wid_value(u16 wid, u8 *buffer, u32 buffer_size)
}
i++;
} while (1);
- } else {
- g_mac.dPrint(N_ERR, "[CFG]: illegal type (%08x)\n", wid);
}
return ret;
@@ -540,6 +534,5 @@ int wilc_wlan_cfg_indicate_rx(struct wilc *wilc, u8 *frame, int size,
int wilc_wlan_cfg_init(wilc_debug_func func)
{
memset((void *)&g_mac, 0, sizeof(struct wilc_mac_cfg));
- g_mac.dPrint = func;
return 1;
}
--
1.9.1
This patch changes the argument of the wilc_wlan_cfg_init function,
wilc_debug to void type because wilc_debug function is not used any more.
In addition, finally removes wilc_debug and related variables.
Signed-off-by: Leo Kim <[email protected]>
---
drivers/staging/wilc1000/wilc_wlan.c | 17 +----------------
drivers/staging/wilc1000/wilc_wlan_cfg.c | 2 +-
drivers/staging/wilc1000/wilc_wlan_cfg.h | 2 +-
3 files changed, 3 insertions(+), 18 deletions(-)
diff --git a/drivers/staging/wilc1000/wilc_wlan.c b/drivers/staging/wilc1000/wilc_wlan.c
index 34018a1..d50ddc6 100644
--- a/drivers/staging/wilc1000/wilc_wlan.c
+++ b/drivers/staging/wilc1000/wilc_wlan.c
@@ -3,21 +3,6 @@
#include "wilc_wfi_netdevice.h"
#include "wilc_wlan_cfg.h"
-static u32 dbgflag = N_INIT | N_ERR | N_INTR | N_TXQ | N_RXQ;
-
-/* FIXME: replace with dev_debug() */
-static void wilc_debug(u32 flag, char *fmt, ...)
-{
- char buf[256];
- va_list args;
-
- if (flag & dbgflag) {
- va_start(args, fmt);
- vsprintf(buf, fmt, args);
- va_end(args);
- }
-}
-
static CHIP_PS_STATE_T chip_ps_state = CHIP_WAKEDUP;
static inline void acquire_bus(struct wilc *wilc, BUS_ACQUIRE_T acquire)
@@ -1448,7 +1433,7 @@ int wilc_wlan_init(struct net_device *dev)
goto _fail_;
}
- if (!wilc_wlan_cfg_init(wilc_debug)) {
+ if (!wilc_wlan_cfg_init()) {
ret = -ENOBUFS;
goto _fail_;
}
diff --git a/drivers/staging/wilc1000/wilc_wlan_cfg.c b/drivers/staging/wilc1000/wilc_wlan_cfg.c
index deff886..b992243 100644
--- a/drivers/staging/wilc1000/wilc_wlan_cfg.c
+++ b/drivers/staging/wilc1000/wilc_wlan_cfg.c
@@ -531,7 +531,7 @@ int wilc_wlan_cfg_indicate_rx(struct wilc *wilc, u8 *frame, int size,
return ret;
}
-int wilc_wlan_cfg_init(wilc_debug_func func)
+int wilc_wlan_cfg_init(void)
{
memset((void *)&g_mac, 0, sizeof(struct wilc_mac_cfg));
return 1;
diff --git a/drivers/staging/wilc1000/wilc_wlan_cfg.h b/drivers/staging/wilc1000/wilc_wlan_cfg.h
index 9b74cc3..b8641a2 100644
--- a/drivers/staging/wilc1000/wilc_wlan_cfg.h
+++ b/drivers/staging/wilc1000/wilc_wlan_cfg.h
@@ -36,6 +36,6 @@ int wilc_wlan_cfg_get_wid(u8 *frame, u32 offset, u16 id);
int wilc_wlan_cfg_get_wid_value(u16 wid, u8 *buffer, u32 buffer_size);
int wilc_wlan_cfg_indicate_rx(struct wilc *wilc, u8 *frame, int size,
struct wilc_cfg_rsp *rsp);
-int wilc_wlan_cfg_init(wilc_debug_func func);
+int wilc_wlan_cfg_init(void);
#endif
--
1.9.1