2 * Intel Wireless WiMAX Connection 2400m
3 * Generic probe/disconnect, reset and message passing
6 * Copyright (C) 2007-2008 Intel Corporation <linux-wimax@intel.com>
7 * Inaky Perez-Gonzalez <inaky.perez-gonzalez@intel.com>
9 * This program is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License version
11 * 2 as published by the Free Software Foundation.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
24 * See i2400m.h for driver documentation. This contains helpers for
25 * the driver model glue [_setup()/_release()], handling device resets
26 * [_dev_reset_handle()], and the backends for the WiMAX stack ops
27 * reset [_op_reset()] and message from user [_op_msg_from_user()].
31 * i2400m_op_msg_from_user()
33 * wimax_msg_to_user_send()
38 * i2400m_dev_reset_handle()
39 * __i2400m_dev_reset_handle()
41 * __i2400m_dev_start()
44 * i2400m_bootrom_init()
47 * __i2400m_dev_start()
48 * i2400m_dev_bootstrap()
50 * i2400m->bus_dev_start()
51 * i2400m_firmware_check()
52 * i2400m_check_mac_addr()
59 * i2400m_dev_shutdown()
60 * i2400m->bus_dev_stop()
65 #include <linux/etherdevice.h>
66 #include <linux/wimax/i2400m.h>
67 #include <linux/module.h>
68 #include <linux/moduleparam.h>
70 #define D_SUBMODULE driver
71 #include "debug-levels.h"
74 int i2400m_idle_mode_disabled; /* 0 (idle mode enabled) by default */
75 module_param_named(idle_mode_disabled, i2400m_idle_mode_disabled, int, 0644);
76 MODULE_PARM_DESC(idle_mode_disabled,
77 "If true, the device will not enable idle mode negotiation "
78 "with the base station (when connected) to save power.");
80 int i2400m_rx_reorder_disabled; /* 0 (rx reorder enabled) by default */
81 module_param_named(rx_reorder_disabled, i2400m_rx_reorder_disabled, int, 0644);
82 MODULE_PARM_DESC(rx_reorder_disabled,
83 "If true, RX reordering will be disabled.");
86 * i2400m_queue_work - schedule work on a i2400m's queue
88 * @i2400m: device descriptor
90 * @fn: function to run to execute work. It gets passed a 'struct
91 * work_struct' that is wrapped in a 'struct i2400m_work'. Once
92 * done, you have to (1) i2400m_put(i2400m_work->i2400m) and then
93 * (2) kfree(i2400m_work).
95 * @gfp_flags: GFP flags for memory allocation.
97 * @pl: pointer to a payload buffer that you want to pass to the _work
98 * function. Use this to pack (for example) a struct with extra
101 * @pl_size: size of the payload buffer.
103 * We do this quite often, so this just saves typing; allocate a
104 * wrapper for a i2400m, get a ref to it, pack arguments and launch
107 * A usual workflow is:
109 * struct my_work_args {
115 * struct my_work_args my_args = {
119 * i2400m_queue_work(i2400m, 1, my_work_function, GFP_KERNEL,
120 * &args, sizeof(args))
122 * And now the work function can unpack the arguments and call the
123 * real function (or do the job itself):
126 * void my_work_fn((struct work_struct *ws)
128 * struct i2400m_work *iw =
129 * container_of(ws, struct i2400m_work, ws);
130 * struct my_work_args *my_args = (void *) iw->pl;
132 * my_work(iw->i2400m, my_args->something, my_args->whatevert);
135 int i2400m_queue_work(struct i2400m *i2400m,
136 void (*fn)(struct work_struct *), gfp_t gfp_flags,
137 const void *pl, size_t pl_size)
140 struct i2400m_work *iw;
142 BUG_ON(i2400m->work_queue == NULL);
144 iw = kzalloc(sizeof(*iw) + pl_size, gfp_flags);
147 iw->i2400m = i2400m_get(i2400m);
148 memcpy(iw->pl, pl, pl_size);
149 INIT_WORK(&iw->ws, fn);
150 result = queue_work(i2400m->work_queue, &iw->ws);
154 EXPORT_SYMBOL_GPL(i2400m_queue_work);
158 * Schedule i2400m's specific work on the system's queue.
160 * Used for a few cases where we really need it; otherwise, identical
161 * to i2400m_queue_work().
163 * Returns < 0 errno code on error, 1 if ok.
165 * If it returns zero, something really bad happened, as it means the
166 * works struct was already queued, but we have just allocated it, so
167 * it should not happen.
169 int i2400m_schedule_work(struct i2400m *i2400m,
170 void (*fn)(struct work_struct *), gfp_t gfp_flags)
173 struct i2400m_work *iw;
175 BUG_ON(i2400m->work_queue == NULL);
177 iw = kzalloc(sizeof(*iw), gfp_flags);
180 iw->i2400m = i2400m_get(i2400m);
181 INIT_WORK(&iw->ws, fn);
182 result = schedule_work(&iw->ws);
191 * WiMAX stack operation: relay a message from user space
193 * @wimax_dev: device descriptor
194 * @pipe_name: named pipe the message is for
195 * @msg_buf: pointer to the message bytes
196 * @msg_len: length of the buffer
197 * @genl_info: passed by the generic netlink layer
199 * The WiMAX stack will call this function when a message was received
202 * For the i2400m, this is an L3L4 message, as specified in
203 * include/linux/wimax/i2400m.h, and thus prefixed with a 'struct
204 * i2400m_l3l4_hdr'. Driver (and device) expect the messages to be
205 * coded in Little Endian.
207 * This function just verifies that the header declaration and the
208 * payload are consistent and then deals with it, either forwarding it
209 * to the device or procesing it locally.
211 * In the i2400m, messages are basically commands that will carry an
212 * ack, so we use i2400m_msg_to_dev() and then deliver the ack back to
213 * user space. The rx.c code might intercept the response and use it
214 * to update the driver's state, but then it will pass it on so it can
215 * be relayed back to user space.
217 * Note that asynchronous events from the device are processed and
218 * sent to user space in rx.c.
221 int i2400m_op_msg_from_user(struct wimax_dev *wimax_dev,
222 const char *pipe_name,
223 const void *msg_buf, size_t msg_len,
224 const struct genl_info *genl_info)
227 struct i2400m *i2400m = wimax_dev_to_i2400m(wimax_dev);
228 struct device *dev = i2400m_dev(i2400m);
229 struct sk_buff *ack_skb;
231 d_fnstart(4, dev, "(wimax_dev %p [i2400m %p] msg_buf %p "
232 "msg_len %zu genl_info %p)\n", wimax_dev, i2400m,
233 msg_buf, msg_len, genl_info);
234 ack_skb = i2400m_msg_to_dev(i2400m, msg_buf, msg_len);
235 result = PTR_ERR(ack_skb);
237 goto error_msg_to_dev;
238 result = wimax_msg_send(&i2400m->wimax_dev, ack_skb);
240 d_fnend(4, dev, "(wimax_dev %p [i2400m %p] msg_buf %p msg_len %zu "
241 "genl_info %p) = %d\n", wimax_dev, i2400m, msg_buf, msg_len,
248 * Context to wait for a reset to finalize
250 struct i2400m_reset_ctx {
251 struct completion completion;
257 * WiMAX stack operation: reset a device
259 * @wimax_dev: device descriptor
261 * See the documentation for wimax_reset() and wimax_dev->op_reset for
262 * the requirements of this function. The WiMAX stack guarantees
263 * serialization on calls to this function.
265 * Do a warm reset on the device; if it fails, resort to a cold reset
266 * and return -ENODEV. On successful warm reset, we need to block
267 * until it is complete.
269 * The bus-driver implementation of reset takes care of falling back
270 * to cold reset if warm fails.
273 int i2400m_op_reset(struct wimax_dev *wimax_dev)
276 struct i2400m *i2400m = wimax_dev_to_i2400m(wimax_dev);
277 struct device *dev = i2400m_dev(i2400m);
278 struct i2400m_reset_ctx ctx = {
279 .completion = COMPLETION_INITIALIZER_ONSTACK(ctx.completion),
283 d_fnstart(4, dev, "(wimax_dev %p)\n", wimax_dev);
284 mutex_lock(&i2400m->init_mutex);
285 i2400m->reset_ctx = &ctx;
286 mutex_unlock(&i2400m->init_mutex);
287 result = i2400m->bus_reset(i2400m, I2400M_RT_WARM);
290 result = wait_for_completion_timeout(&ctx.completion, 4*HZ);
295 /* if result < 0, pass it on */
296 mutex_lock(&i2400m->init_mutex);
297 i2400m->reset_ctx = NULL;
298 mutex_unlock(&i2400m->init_mutex);
300 d_fnend(4, dev, "(wimax_dev %p) = %d\n", wimax_dev, result);
306 * Check the MAC address we got from boot mode is ok
308 * @i2400m: device descriptor
310 * Returns: 0 if ok, < 0 errno code on error.
313 int i2400m_check_mac_addr(struct i2400m *i2400m)
316 struct device *dev = i2400m_dev(i2400m);
318 const struct i2400m_tlv_detailed_device_info *ddi;
319 struct net_device *net_dev = i2400m->wimax_dev.net_dev;
320 const unsigned char zeromac[ETH_ALEN] = { 0 };
322 d_fnstart(3, dev, "(i2400m %p)\n", i2400m);
323 skb = i2400m_get_device_info(i2400m);
325 result = PTR_ERR(skb);
326 dev_err(dev, "Cannot verify MAC address, error reading: %d\n",
330 /* Extract MAC addresss */
331 ddi = (void *) skb->data;
332 BUILD_BUG_ON(ETH_ALEN != sizeof(ddi->mac_address));
333 d_printf(2, dev, "GET DEVICE INFO: mac addr "
334 "%02x:%02x:%02x:%02x:%02x:%02x\n",
335 ddi->mac_address[0], ddi->mac_address[1],
336 ddi->mac_address[2], ddi->mac_address[3],
337 ddi->mac_address[4], ddi->mac_address[5]);
338 if (!memcmp(net_dev->perm_addr, ddi->mac_address,
339 sizeof(ddi->mac_address)))
341 dev_warn(dev, "warning: device reports a different MAC address "
342 "to that of boot mode's\n");
343 dev_warn(dev, "device reports %02x:%02x:%02x:%02x:%02x:%02x\n",
344 ddi->mac_address[0], ddi->mac_address[1],
345 ddi->mac_address[2], ddi->mac_address[3],
346 ddi->mac_address[4], ddi->mac_address[5]);
347 dev_warn(dev, "boot mode reported %02x:%02x:%02x:%02x:%02x:%02x\n",
348 net_dev->perm_addr[0], net_dev->perm_addr[1],
349 net_dev->perm_addr[2], net_dev->perm_addr[3],
350 net_dev->perm_addr[4], net_dev->perm_addr[5]);
351 if (!memcmp(zeromac, ddi->mac_address, sizeof(zeromac)))
352 dev_err(dev, "device reports an invalid MAC address, "
355 dev_warn(dev, "updating MAC address\n");
356 net_dev->addr_len = ETH_ALEN;
357 memcpy(net_dev->perm_addr, ddi->mac_address, ETH_ALEN);
358 memcpy(net_dev->dev_addr, ddi->mac_address, ETH_ALEN);
364 d_fnend(3, dev, "(i2400m %p) = %d\n", i2400m, result);
370 * __i2400m_dev_start - Bring up driver communication with the device
372 * @i2400m: device descriptor
373 * @flags: boot mode flags
375 * Returns: 0 if ok, < 0 errno code on error.
377 * Uploads firmware and brings up all the resources needed to be able
378 * to communicate with the device.
380 * TX needs to be setup before the bus-specific code (otherwise on
381 * shutdown, the bus-tx code could try to access it).
384 int __i2400m_dev_start(struct i2400m *i2400m, enum i2400m_bri flags)
387 struct wimax_dev *wimax_dev = &i2400m->wimax_dev;
388 struct net_device *net_dev = wimax_dev->net_dev;
389 struct device *dev = i2400m_dev(i2400m);
392 d_fnstart(3, dev, "(i2400m %p)\n", i2400m);
394 result = i2400m_dev_bootstrap(i2400m, flags);
396 dev_err(dev, "cannot bootstrap device: %d\n", result);
397 goto error_bootstrap;
399 result = i2400m_tx_setup(i2400m);
402 result = i2400m_rx_setup(i2400m);
405 result = i2400m->bus_dev_start(i2400m);
407 goto error_bus_dev_start;
408 i2400m->work_queue = create_singlethread_workqueue(wimax_dev->name);
409 if (i2400m->work_queue == NULL) {
411 dev_err(dev, "cannot create workqueue\n");
412 goto error_create_workqueue;
414 result = i2400m_firmware_check(i2400m); /* fw versions ok? */
417 /* At this point is ok to send commands to the device */
418 result = i2400m_check_mac_addr(i2400m);
420 goto error_check_mac_addr;
422 wimax_state_change(wimax_dev, WIMAX_ST_UNINITIALIZED);
423 result = i2400m_dev_initialize(i2400m);
425 goto error_dev_initialize;
426 /* At this point, reports will come for the device and set it
427 * to the right state if it is different than UNINITIALIZED */
428 d_fnend(3, dev, "(net_dev %p [i2400m %p]) = %d\n",
429 net_dev, i2400m, result);
432 error_dev_initialize:
433 error_check_mac_addr:
435 destroy_workqueue(i2400m->work_queue);
436 error_create_workqueue:
437 i2400m->bus_dev_stop(i2400m);
439 i2400m_rx_release(i2400m);
441 i2400m_tx_release(i2400m);
444 if (result == -ERESTARTSYS && times-- > 0) {
445 flags = I2400M_BRI_SOFT;
448 d_fnend(3, dev, "(net_dev %p [i2400m %p]) = %d\n",
449 net_dev, i2400m, result);
455 int i2400m_dev_start(struct i2400m *i2400m, enum i2400m_bri bm_flags)
458 mutex_lock(&i2400m->init_mutex); /* Well, start the device */
459 result = __i2400m_dev_start(i2400m, bm_flags);
462 mutex_unlock(&i2400m->init_mutex);
468 * i2400m_dev_stop - Tear down driver communication with the device
470 * @i2400m: device descriptor
472 * Returns: 0 if ok, < 0 errno code on error.
474 * Releases all the resources allocated to communicate with the device.
477 void __i2400m_dev_stop(struct i2400m *i2400m)
479 struct wimax_dev *wimax_dev = &i2400m->wimax_dev;
480 struct device *dev = i2400m_dev(i2400m);
482 d_fnstart(3, dev, "(i2400m %p)\n", i2400m);
483 wimax_state_change(wimax_dev, __WIMAX_ST_QUIESCING);
484 i2400m_dev_shutdown(i2400m);
486 destroy_workqueue(i2400m->work_queue);
487 i2400m->bus_dev_stop(i2400m);
488 i2400m_rx_release(i2400m);
489 i2400m_tx_release(i2400m);
490 wimax_state_change(wimax_dev, WIMAX_ST_DOWN);
491 d_fnend(3, dev, "(i2400m %p) = 0\n", i2400m);
496 * Watch out -- we only need to stop if there is a need for it. The
497 * device could have reset itself and failed to come up again (see
498 * _i2400m_dev_reset_handle()).
501 void i2400m_dev_stop(struct i2400m *i2400m)
503 mutex_lock(&i2400m->init_mutex);
504 if (i2400m->updown) {
505 __i2400m_dev_stop(i2400m);
508 mutex_unlock(&i2400m->init_mutex);
513 * The device has rebooted; fix up the device and the driver
515 * Tear down the driver communication with the device, reload the
516 * firmware and reinitialize the communication with the device.
518 * If someone calls a reset when the device's firmware is down, in
519 * theory we won't see it because we are not listening. However, just
520 * in case, leave the code to handle it.
522 * If there is a reset context, use it; this means someone is waiting
523 * for us to tell him when the reset operation is complete and the
524 * device is ready to rock again.
526 * NOTE: if we are in the process of bringing up or down the
527 * communication with the device [running i2400m_dev_start() or
528 * _stop()], don't do anything, let it fail and handle it.
530 * This function is ran always in a thread context
533 void __i2400m_dev_reset_handle(struct work_struct *ws)
536 struct i2400m_work *iw = container_of(ws, struct i2400m_work, ws);
537 struct i2400m *i2400m = iw->i2400m;
538 struct device *dev = i2400m_dev(i2400m);
539 enum wimax_st wimax_state;
540 struct i2400m_reset_ctx *ctx = i2400m->reset_ctx;
542 d_fnstart(3, dev, "(ws %p i2400m %p)\n", ws, i2400m);
544 if (mutex_trylock(&i2400m->init_mutex) == 0) {
545 /* We are still in i2400m_dev_start() [let it fail] or
546 * i2400m_dev_stop() [we are shutting down anyway, so
547 * ignore it] or we are resetting somewhere else. */
548 dev_err(dev, "device rebooted\n");
549 i2400m_msg_to_dev_cancel_wait(i2400m, -ERESTARTSYS);
550 complete(&i2400m->msg_completion);
553 wimax_state = wimax_state_get(&i2400m->wimax_dev);
554 if (wimax_state < WIMAX_ST_UNINITIALIZED) {
555 dev_info(dev, "device rebooted: it is down, ignoring\n");
556 goto out_unlock; /* ifconfig up/down wasn't called */
558 dev_err(dev, "device rebooted: reinitializing driver\n");
559 __i2400m_dev_stop(i2400m);
561 result = __i2400m_dev_start(i2400m,
562 I2400M_BRI_SOFT | I2400M_BRI_MAC_REINIT);
564 dev_err(dev, "device reboot: cannot start the device: %d\n",
566 result = i2400m->bus_reset(i2400m, I2400M_RT_BUS);
572 if (i2400m->reset_ctx) {
573 ctx->result = result;
574 complete(&ctx->completion);
576 mutex_unlock(&i2400m->init_mutex);
580 d_fnend(3, dev, "(ws %p i2400m %p) = void\n", ws, i2400m);
586 * i2400m_dev_reset_handle - Handle a device's reset in a thread context
588 * Schedule a device reset handling out on a thread context, so it
589 * is safe to call from atomic context. We can't use the i2400m's
590 * queue as we are going to destroy it and reinitialize it as part of
591 * the driver bringup/bringup process.
593 * See __i2400m_dev_reset_handle() for details; that takes care of
594 * reinitializing the driver to handle the reset, calling into the
595 * bus-specific functions ops as needed.
597 int i2400m_dev_reset_handle(struct i2400m *i2400m)
599 return i2400m_schedule_work(i2400m, __i2400m_dev_reset_handle,
602 EXPORT_SYMBOL_GPL(i2400m_dev_reset_handle);
606 * i2400m_setup - bus-generic setup function for the i2400m device
608 * @i2400m: device descriptor (bus-specific parts have been initialized)
610 * Returns: 0 if ok, < 0 errno code on error.
612 * Initializes the bus-generic parts of the i2400m driver; the
613 * bus-specific parts have been initialized, function pointers filled
614 * out by the bus-specific probe function.
616 * As well, this registers the WiMAX and net device nodes. Once this
617 * function returns, the device is operative and has to be ready to
618 * receive and send network traffic and WiMAX control operations.
620 int i2400m_setup(struct i2400m *i2400m, enum i2400m_bri bm_flags)
622 int result = -ENODEV;
623 struct device *dev = i2400m_dev(i2400m);
624 struct wimax_dev *wimax_dev = &i2400m->wimax_dev;
625 struct net_device *net_dev = i2400m->wimax_dev.net_dev;
627 d_fnstart(3, dev, "(i2400m %p)\n", i2400m);
629 snprintf(wimax_dev->name, sizeof(wimax_dev->name),
630 "i2400m-%s:%s", dev->bus->name, dev_name(dev));
632 i2400m->bm_cmd_buf = kzalloc(I2400M_BM_CMD_BUF_SIZE, GFP_KERNEL);
633 if (i2400m->bm_cmd_buf == NULL) {
634 dev_err(dev, "cannot allocate USB command buffer\n");
635 goto error_bm_cmd_kzalloc;
637 i2400m->bm_ack_buf = kzalloc(I2400M_BM_ACK_BUF_SIZE, GFP_KERNEL);
638 if (i2400m->bm_ack_buf == NULL) {
639 dev_err(dev, "cannot allocate USB ack buffer\n");
640 goto error_bm_ack_buf_kzalloc;
642 result = i2400m_bootrom_init(i2400m, bm_flags);
644 dev_err(dev, "read mac addr: bootrom init "
645 "failed: %d\n", result);
646 goto error_bootrom_init;
648 result = i2400m_read_mac_addr(i2400m);
650 goto error_read_mac_addr;
651 random_ether_addr(i2400m->src_mac_addr);
653 result = register_netdev(net_dev); /* Okey dokey, bring it up */
655 dev_err(dev, "cannot register i2400m network device: %d\n",
657 goto error_register_netdev;
659 netif_carrier_off(net_dev);
661 result = i2400m_dev_start(i2400m, bm_flags);
663 goto error_dev_start;
665 i2400m->wimax_dev.op_msg_from_user = i2400m_op_msg_from_user;
666 i2400m->wimax_dev.op_rfkill_sw_toggle = i2400m_op_rfkill_sw_toggle;
667 i2400m->wimax_dev.op_reset = i2400m_op_reset;
668 result = wimax_dev_add(&i2400m->wimax_dev, net_dev);
670 goto error_wimax_dev_add;
671 /* User space needs to do some init stuff */
672 wimax_state_change(wimax_dev, WIMAX_ST_UNINITIALIZED);
674 /* Now setup all that requires a registered net and wimax device. */
675 result = sysfs_create_group(&net_dev->dev.kobj, &i2400m_dev_attr_group);
677 dev_err(dev, "cannot setup i2400m's sysfs: %d\n", result);
678 goto error_sysfs_setup;
680 result = i2400m_debugfs_add(i2400m);
682 dev_err(dev, "cannot setup i2400m's debugfs: %d\n", result);
683 goto error_debugfs_setup;
685 d_fnend(3, dev, "(i2400m %p) = %d\n", i2400m, result);
689 sysfs_remove_group(&i2400m->wimax_dev.net_dev->dev.kobj,
690 &i2400m_dev_attr_group);
692 wimax_dev_rm(&i2400m->wimax_dev);
694 i2400m_dev_stop(i2400m);
696 unregister_netdev(net_dev);
697 error_register_netdev:
700 kfree(i2400m->bm_ack_buf);
701 error_bm_ack_buf_kzalloc:
702 kfree(i2400m->bm_cmd_buf);
703 error_bm_cmd_kzalloc:
704 d_fnend(3, dev, "(i2400m %p) = %d\n", i2400m, result);
707 EXPORT_SYMBOL_GPL(i2400m_setup);
711 * i2400m_release - release the bus-generic driver resources
713 * Sends a disconnect message and undoes any setup done by i2400m_setup()
715 void i2400m_release(struct i2400m *i2400m)
717 struct device *dev = i2400m_dev(i2400m);
719 d_fnstart(3, dev, "(i2400m %p)\n", i2400m);
720 netif_stop_queue(i2400m->wimax_dev.net_dev);
722 i2400m_debugfs_rm(i2400m);
723 sysfs_remove_group(&i2400m->wimax_dev.net_dev->dev.kobj,
724 &i2400m_dev_attr_group);
725 wimax_dev_rm(&i2400m->wimax_dev);
726 i2400m_dev_stop(i2400m);
727 unregister_netdev(i2400m->wimax_dev.net_dev);
728 kfree(i2400m->bm_ack_buf);
729 kfree(i2400m->bm_cmd_buf);
730 d_fnend(3, dev, "(i2400m %p) = void\n", i2400m);
732 EXPORT_SYMBOL_GPL(i2400m_release);
736 * Debug levels control; see debug.h
738 struct d_level D_LEVEL[] = {
739 D_SUBMODULE_DEFINE(control),
740 D_SUBMODULE_DEFINE(driver),
741 D_SUBMODULE_DEFINE(debugfs),
742 D_SUBMODULE_DEFINE(fw),
743 D_SUBMODULE_DEFINE(netdev),
744 D_SUBMODULE_DEFINE(rfkill),
745 D_SUBMODULE_DEFINE(rx),
746 D_SUBMODULE_DEFINE(tx),
748 size_t D_LEVEL_SIZE = ARRAY_SIZE(D_LEVEL);
752 int __init i2400m_driver_init(void)
756 module_init(i2400m_driver_init);
759 void __exit i2400m_driver_exit(void)
761 /* for scheds i2400m_dev_reset_handle() */
762 flush_scheduled_work();
765 module_exit(i2400m_driver_exit);
767 MODULE_AUTHOR("Intel Corporation <linux-wimax@intel.com>");
768 MODULE_DESCRIPTION("Intel 2400M WiMAX networking bus-generic driver");
769 MODULE_LICENSE("GPL");