linux_wlan_device_power(0);
}
-int wilc_netdev_init(void)
+int wilc_netdev_init(struct wilc **wilc)
{
-
int i;
perInterface_wlan_t *nic;
struct net_device *ndev;
if (!g_linux_wlan)
return -ENOMEM;
+ *wilc = g_linux_wlan;
+
register_inetaddr_notifier(&g_dev_notifier);
for (i = 0; i < NUM_CONCURRENT_IFC; i++) {
};
struct sdio_func *local_sdio_func;
-extern int wilc_netdev_init(void);
extern void wilc_handle_isr(void);
static unsigned int sdio_default_speed;
static int linux_sdio_probe(struct sdio_func *func, const struct sdio_device_id *id)
{
struct wilc_sdio *wl_sdio;
+ struct wilc *wilc;
PRINT_D(INIT_DBG, "probe function\n");
wl_sdio = kzalloc(sizeof(struct wilc_sdio), GFP_KERNEL);
PRINT_D(INIT_DBG, "Initializing netdev\n");
local_sdio_func = func;
- if (wilc_netdev_init()) {
+ if (wilc_netdev_init(&wilc)) {
PRINT_ER("Couldn't initialize netdev\n");
kfree(wl_sdio);
return -1;
}
wl_sdio->func = func;
+ wl_sdio->wilc = wilc;
sdio_set_drvdata(func, wl_sdio);
printk("Driver Initializing success\n");
void linux_wlan_dbg(u8 *buff);
int linux_wlan_lock_timeout(void *vp, u32 timeout);
void wl_wlan_cleanup(void);
+int wilc_netdev_init(struct wilc **wilc);
#endif