1 // SPDX-License-Identifier: GPL-2.0-or-later
4 Driver for the Marvell 8385 based compact flash WLAN cards.
6 (C) 2007 by Holger Schurig <hs4233@mail.mn-solutions.de>
11 #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
13 #include <linux/module.h>
14 #include <linux/slab.h>
15 #include <linux/delay.h>
16 #include <linux/moduleparam.h>
17 #include <linux/firmware.h>
18 #include <linux/netdevice.h>
20 #include <pcmcia/cistpl.h>
21 #include <pcmcia/ds.h>
25 #define DRV_NAME "libertas_cs"
32 /********************************************************************/
34 /********************************************************************/
36 MODULE_AUTHOR("Holger Schurig <hs4233@mail.mn-solutions.de>");
37 MODULE_DESCRIPTION("Driver for Marvell 83xx compact flash WLAN cards");
38 MODULE_LICENSE("GPL");
42 /********************************************************************/
44 /********************************************************************/
47 struct pcmcia_device *p_dev;
48 struct lbs_private *priv;
62 static const struct lbs_fw_table fw_table[] = {
63 { MODEL_8305, "/*(DEBLOBBED)*/", NULL },
64 { MODEL_8305, "/*(DEBLOBBED)*/", NULL },
65 { MODEL_8381, "/*(DEBLOBBED)*/", "/*(DEBLOBBED)*/" },
66 { MODEL_8381, "/*(DEBLOBBED)*/", "/*(DEBLOBBED)*/" },
67 { MODEL_8385, "/*(DEBLOBBED)*/", "/*(DEBLOBBED)*/" },
68 { MODEL_8385, "/*(DEBLOBBED)*/", "/*(DEBLOBBED)*/" },
74 /********************************************************************/
76 /********************************************************************/
78 /* This define enables wrapper functions which allow you
79 to dump all register accesses. You normally won't this,
80 except for development */
81 /* #define DEBUG_IO */
84 static int debug_output = 0;
86 /* This way the compiler optimizes the printk's away */
87 #define debug_output 0
90 static inline unsigned int if_cs_read8(struct if_cs_card *card, uint reg)
92 unsigned int val = ioread8(card->iobase + reg);
94 printk(KERN_INFO "inb %08x<%02x\n", reg, val);
97 static inline unsigned int if_cs_read16(struct if_cs_card *card, uint reg)
99 unsigned int val = ioread16(card->iobase + reg);
101 printk(KERN_INFO "inw %08x<%04x\n", reg, val);
104 static inline void if_cs_read16_rep(
105 struct if_cs_card *card,
111 printk(KERN_INFO "insw %08x<(0x%lx words)\n",
113 ioread16_rep(card->iobase + reg, buf, count);
116 static inline void if_cs_write8(struct if_cs_card *card, uint reg, u8 val)
119 printk(KERN_INFO "outb %08x>%02x\n", reg, val);
120 iowrite8(val, card->iobase + reg);
123 static inline void if_cs_write16(struct if_cs_card *card, uint reg, u16 val)
126 printk(KERN_INFO "outw %08x>%04x\n", reg, val);
127 iowrite16(val, card->iobase + reg);
130 static inline void if_cs_write16_rep(
131 struct if_cs_card *card,
137 printk(KERN_INFO "outsw %08x>(0x%lx words)\n",
139 iowrite16_rep(card->iobase + reg, buf, count);
144 * I know that polling/delaying is frowned upon. However, this procedure
145 * with polling is needed while downloading the firmware. At this stage,
146 * the hardware does unfortunately not create any interrupts.
148 * Fortunately, this function is never used once the firmware is in
151 * As a reference, see the "Firmware Specification v5.1", page 18
152 * and 19. I did not follow their suggested timing to the word,
153 * but this works nice & fast anyway.
155 static int if_cs_poll_while_fw_download(struct if_cs_card *card, uint addr, u8 reg)
159 for (i = 0; i < 100000; i++) {
160 u8 val = if_cs_read8(card, addr);
171 * First the bitmasks for the host/card interrupt/status registers:
173 #define IF_CS_BIT_TX 0x0001
174 #define IF_CS_BIT_RX 0x0002
175 #define IF_CS_BIT_COMMAND 0x0004
176 #define IF_CS_BIT_RESP 0x0008
177 #define IF_CS_BIT_EVENT 0x0010
178 #define IF_CS_BIT_MASK 0x001f
183 * It's not really clear to me what the host status register is for. It
184 * needs to be set almost in union with "host int cause". The following
185 * bits from above are used:
187 * IF_CS_BIT_TX driver downloaded a data packet
188 * IF_CS_BIT_RX driver got a data packet
189 * IF_CS_BIT_COMMAND driver downloaded a command
190 * IF_CS_BIT_RESP not used (has some meaning with powerdown)
191 * IF_CS_BIT_EVENT driver read a host event
193 #define IF_CS_HOST_STATUS 0x00000000
196 * With the host int cause register can the host (that is, Linux) cause
197 * an interrupt in the firmware, to tell the firmware about those events:
199 * IF_CS_BIT_TX a data packet has been downloaded
200 * IF_CS_BIT_RX a received data packet has retrieved
201 * IF_CS_BIT_COMMAND a firmware block or a command has been downloaded
202 * IF_CS_BIT_RESP not used (has some meaning with powerdown)
203 * IF_CS_BIT_EVENT a host event (link lost etc) has been retrieved
205 #define IF_CS_HOST_INT_CAUSE 0x00000002
208 * The host int mask register is used to enable/disable interrupt. However,
209 * I have the suspicion that disabled interrupts are lost.
211 #define IF_CS_HOST_INT_MASK 0x00000004
214 * Used to send or receive data packets:
216 #define IF_CS_WRITE 0x00000016
217 #define IF_CS_WRITE_LEN 0x00000014
218 #define IF_CS_READ 0x00000010
219 #define IF_CS_READ_LEN 0x00000024
222 * Used to send commands (and to send firmware block) and to
223 * receive command responses:
225 #define IF_CS_CMD 0x0000001A
226 #define IF_CS_CMD_LEN 0x00000018
227 #define IF_CS_RESP 0x00000012
228 #define IF_CS_RESP_LEN 0x00000030
231 * The card status registers shows what the card/firmware actually
234 * IF_CS_BIT_TX you may send a data packet
235 * IF_CS_BIT_RX you may retrieve a data packet
236 * IF_CS_BIT_COMMAND you may send a command
237 * IF_CS_BIT_RESP you may retrieve a command response
238 * IF_CS_BIT_EVENT the card has a event for use (link lost, snr low etc)
240 * When reading this register several times, you will get back the same
241 * results --- with one exception: the IF_CS_BIT_EVENT clear itself
244 * Not that we don't rely on BIT_RX,_BIT_RESP or BIT_EVENT because
245 * we handle this via the card int cause register.
247 #define IF_CS_CARD_STATUS 0x00000020
248 #define IF_CS_CARD_STATUS_MASK 0x7f00
251 * The card int cause register is used by the card/firmware to notify us
252 * about the following events:
254 * IF_CS_BIT_TX a data packet has successfully been sentx
255 * IF_CS_BIT_RX a data packet has been received and can be retrieved
256 * IF_CS_BIT_COMMAND not used
257 * IF_CS_BIT_RESP the firmware has a command response for us
258 * IF_CS_BIT_EVENT the card has a event for use (link lost, snr low etc)
260 #define IF_CS_CARD_INT_CAUSE 0x00000022
263 * This is used to for handshaking with the card's bootloader/helper image
264 * to synchronize downloading of firmware blocks.
266 #define IF_CS_SQ_READ_LOW 0x00000028
267 #define IF_CS_SQ_HELPER_OK 0x10
270 * The scratch register tells us ...
272 * IF_CS_SCRATCH_BOOT_OK the bootloader runs
273 * IF_CS_SCRATCH_HELPER_OK the helper firmware already runs
275 #define IF_CS_SCRATCH 0x0000003F
276 #define IF_CS_SCRATCH_BOOT_OK 0x00
277 #define IF_CS_SCRATCH_HELPER_OK 0x5a
280 * Used to detect ancient chips:
282 #define IF_CS_PRODUCT_ID 0x0000001C
283 #define IF_CS_CF8385_B1_REV 0x12
284 #define IF_CS_CF8381_B3_REV 0x04
285 #define IF_CS_CF8305_B1_REV 0x03
288 * Used to detect other cards than CF8385 since their revisions of silicon
289 * doesn't match those from CF8385, eg. CF8381 B3 works with this driver.
291 #define CF8305_MANFID 0x02db
292 #define CF8305_CARDID 0x8103
293 #define CF8381_MANFID 0x02db
294 #define CF8381_CARDID 0x6064
295 #define CF8385_MANFID 0x02df
296 #define CF8385_CARDID 0x8103
299 * FIXME: just use the 'driver_info' field of 'struct pcmcia_device_id' when
300 * that gets fixed. Currently there's no way to access it from the probe hook.
302 static inline u32 get_model(u16 manf_id, u16 card_id)
304 /* NOTE: keep in sync with if_cs_ids */
305 if (manf_id == CF8305_MANFID && card_id == CF8305_CARDID)
307 else if (manf_id == CF8381_MANFID && card_id == CF8381_CARDID)
309 else if (manf_id == CF8385_MANFID && card_id == CF8385_CARDID)
311 return MODEL_UNKNOWN;
314 /********************************************************************/
315 /* I/O and interrupt handling */
316 /********************************************************************/
318 static inline void if_cs_enable_ints(struct if_cs_card *card)
320 if_cs_write16(card, IF_CS_HOST_INT_MASK, 0);
323 static inline void if_cs_disable_ints(struct if_cs_card *card)
325 if_cs_write16(card, IF_CS_HOST_INT_MASK, IF_CS_BIT_MASK);
329 * Called from if_cs_host_to_card to send a command to the hardware
331 static int if_cs_send_cmd(struct lbs_private *priv, u8 *buf, u16 nb)
333 struct if_cs_card *card = (struct if_cs_card *)priv->card;
337 if_cs_disable_ints(card);
339 /* Is hardware ready? */
341 u16 status = if_cs_read16(card, IF_CS_CARD_STATUS);
342 if (status & IF_CS_BIT_COMMAND)
345 netdev_err(priv->dev, "card not ready for commands\n");
351 if_cs_write16(card, IF_CS_CMD_LEN, nb);
353 if_cs_write16_rep(card, IF_CS_CMD, buf, nb / 2);
354 /* Are we supposed to transfer an odd amount of bytes? */
356 if_cs_write8(card, IF_CS_CMD, buf[nb-1]);
358 /* "Assert the download over interrupt command in the Host
359 * status register" */
360 if_cs_write16(card, IF_CS_HOST_STATUS, IF_CS_BIT_COMMAND);
362 /* "Assert the download over interrupt command in the Card
363 * interrupt case register" */
364 if_cs_write16(card, IF_CS_HOST_INT_CAUSE, IF_CS_BIT_COMMAND);
368 if_cs_enable_ints(card);
373 * Called from if_cs_host_to_card to send a data to the hardware
375 static void if_cs_send_data(struct lbs_private *priv, u8 *buf, u16 nb)
377 struct if_cs_card *card = (struct if_cs_card *)priv->card;
380 if_cs_disable_ints(card);
382 status = if_cs_read16(card, IF_CS_CARD_STATUS);
383 BUG_ON((status & IF_CS_BIT_TX) == 0);
385 if_cs_write16(card, IF_CS_WRITE_LEN, nb);
387 /* write even number of bytes, then odd byte if necessary */
388 if_cs_write16_rep(card, IF_CS_WRITE, buf, nb / 2);
390 if_cs_write8(card, IF_CS_WRITE, buf[nb-1]);
392 if_cs_write16(card, IF_CS_HOST_STATUS, IF_CS_BIT_TX);
393 if_cs_write16(card, IF_CS_HOST_INT_CAUSE, IF_CS_BIT_TX);
394 if_cs_enable_ints(card);
398 * Get the command result out of the card.
400 static int if_cs_receive_cmdres(struct lbs_private *priv, u8 *data, u32 *len)
406 /* is hardware ready? */
407 status = if_cs_read16(priv->card, IF_CS_CARD_STATUS);
408 if ((status & IF_CS_BIT_RESP) == 0) {
409 netdev_err(priv->dev, "no cmd response in card\n");
414 *len = if_cs_read16(priv->card, IF_CS_RESP_LEN);
415 if ((*len == 0) || (*len > LBS_CMD_BUFFER_SIZE)) {
416 netdev_err(priv->dev,
417 "card cmd buffer has invalid # of bytes (%d)\n",
422 /* read even number of bytes, then odd byte if necessary */
423 if_cs_read16_rep(priv->card, IF_CS_RESP, data, *len/sizeof(u16));
425 data[*len-1] = if_cs_read8(priv->card, IF_CS_RESP);
427 /* This is a workaround for a firmware that reports too much
432 /* Clear this flag again */
433 spin_lock_irqsave(&priv->driver_lock, flags);
434 priv->dnld_sent = DNLD_RES_RECEIVED;
435 spin_unlock_irqrestore(&priv->driver_lock, flags);
441 static struct sk_buff *if_cs_receive_data(struct lbs_private *priv)
443 struct sk_buff *skb = NULL;
447 len = if_cs_read16(priv->card, IF_CS_READ_LEN);
448 if (len == 0 || len > MRVDRV_ETH_RX_PACKET_BUFFER_SIZE) {
449 netdev_err(priv->dev,
450 "card data buffer has invalid # of bytes (%d)\n",
452 priv->dev->stats.rx_dropped++;
456 skb = dev_alloc_skb(MRVDRV_ETH_RX_PACKET_BUFFER_SIZE + 2);
460 skb_reserve(skb, 2);/* 16 byte align */
463 /* read even number of bytes, then odd byte if necessary */
464 if_cs_read16_rep(priv->card, IF_CS_READ, data, len/sizeof(u16));
466 data[len-1] = if_cs_read8(priv->card, IF_CS_READ);
469 if_cs_write16(priv->card, IF_CS_HOST_STATUS, IF_CS_BIT_RX);
470 if_cs_write16(priv->card, IF_CS_HOST_INT_CAUSE, IF_CS_BIT_RX);
476 static irqreturn_t if_cs_interrupt(int irq, void *data)
478 struct if_cs_card *card = data;
479 struct lbs_private *priv = card->priv;
482 /* Ask card interrupt cause register if there is something for us */
483 cause = if_cs_read16(card, IF_CS_CARD_INT_CAUSE);
484 lbs_deb_cs("cause 0x%04x\n", cause);
491 if (cause == 0xffff) {
492 /* Read in junk, the card has probably been removed */
493 card->priv->surpriseremoved = 1;
497 if (cause & IF_CS_BIT_RX) {
499 lbs_deb_cs("rx packet\n");
500 skb = if_cs_receive_data(priv);
502 lbs_process_rxed_packet(priv, skb);
505 if (cause & IF_CS_BIT_TX) {
506 lbs_deb_cs("tx done\n");
507 lbs_host_to_card_done(priv);
510 if (cause & IF_CS_BIT_RESP) {
514 lbs_deb_cs("cmd resp\n");
515 spin_lock_irqsave(&priv->driver_lock, flags);
516 i = (priv->resp_idx == 0) ? 1 : 0;
517 spin_unlock_irqrestore(&priv->driver_lock, flags);
519 BUG_ON(priv->resp_len[i]);
520 if_cs_receive_cmdres(priv, priv->resp_buf[i],
523 spin_lock_irqsave(&priv->driver_lock, flags);
524 lbs_notify_command_response(priv, i);
525 spin_unlock_irqrestore(&priv->driver_lock, flags);
528 if (cause & IF_CS_BIT_EVENT) {
529 u16 status = if_cs_read16(priv->card, IF_CS_CARD_STATUS);
530 if_cs_write16(priv->card, IF_CS_HOST_INT_CAUSE,
532 lbs_queue_event(priv, (status & IF_CS_CARD_STATUS_MASK) >> 8);
535 /* Clear interrupt cause */
536 if_cs_write16(card, IF_CS_CARD_INT_CAUSE, cause & IF_CS_BIT_MASK);
544 /********************************************************************/
546 /********************************************************************/
549 * Tries to program the helper firmware.
551 * Return 0 on success
553 static int if_cs_prog_helper(struct if_cs_card *card, const struct firmware *fw)
560 * This is the only place where an unaligned register access happens on
561 * the CF8305 card, therefore for the sake of speed of the driver, we do
562 * the alignment correction here.
564 if (card->align_regs)
565 scratch = if_cs_read16(card, IF_CS_SCRATCH) >> 8;
567 scratch = if_cs_read8(card, IF_CS_SCRATCH);
569 /* "If the value is 0x5a, the firmware is already
570 * downloaded successfully"
572 if (scratch == IF_CS_SCRATCH_HELPER_OK)
575 /* "If the value is != 00, it is invalid value of register */
576 if (scratch != IF_CS_SCRATCH_BOOT_OK) {
581 lbs_deb_cs("helper size %td\n", fw->size);
583 /* "Set the 5 bytes of the helper image to 0" */
584 /* Not needed, this contains an ARM branch instruction */
587 /* "the number of bytes to send is 256" */
589 int remain = fw->size - sent;
595 * "write the number of bytes to be sent to the I/O Command
596 * write length register"
598 if_cs_write16(card, IF_CS_CMD_LEN, count);
600 /* "write this to I/O Command port register as 16 bit writes */
602 if_cs_write16_rep(card, IF_CS_CMD,
607 * "Assert the download over interrupt command in the Host
610 if_cs_write8(card, IF_CS_HOST_STATUS, IF_CS_BIT_COMMAND);
613 * "Assert the download over interrupt command in the Card
614 * interrupt case register"
616 if_cs_write16(card, IF_CS_HOST_INT_CAUSE, IF_CS_BIT_COMMAND);
619 * "The host polls the Card Status register ... for 50 ms before
620 * declaring a failure"
622 ret = if_cs_poll_while_fw_download(card, IF_CS_CARD_STATUS,
625 pr_err("can't download helper at 0x%x, ret %d\n",
641 static int if_cs_prog_real(struct if_cs_card *card, const struct firmware *fw)
648 lbs_deb_cs("fw size %td\n", fw->size);
650 ret = if_cs_poll_while_fw_download(card, IF_CS_SQ_READ_LOW,
653 pr_err("helper firmware doesn't answer\n");
657 for (sent = 0; sent < fw->size; sent += len) {
658 len = if_cs_read16(card, IF_CS_SQ_READ_LOW);
661 pr_info("odd, need to retry this firmware block\n");
667 pr_err("could not download firmware\n");
676 if_cs_write16(card, IF_CS_CMD_LEN, len);
678 if_cs_write16_rep(card, IF_CS_CMD,
681 if_cs_write8(card, IF_CS_HOST_STATUS, IF_CS_BIT_COMMAND);
682 if_cs_write16(card, IF_CS_HOST_INT_CAUSE, IF_CS_BIT_COMMAND);
684 ret = if_cs_poll_while_fw_download(card, IF_CS_CARD_STATUS,
687 pr_err("can't download firmware at 0x%x\n", sent);
692 ret = if_cs_poll_while_fw_download(card, IF_CS_SCRATCH, 0x5a);
694 pr_err("firmware download failed\n");
700 static void if_cs_prog_firmware(struct lbs_private *priv, int ret,
701 const struct firmware *helper,
702 const struct firmware *mainfw)
704 struct if_cs_card *card = priv->card;
707 pr_err("failed to find firmware (%d)\n", ret);
711 /* Load the firmware */
712 ret = if_cs_prog_helper(card, helper);
713 if (ret == 0 && (card->model != MODEL_8305))
714 ret = if_cs_prog_real(card, mainfw);
718 /* Now actually get the IRQ */
719 ret = request_irq(card->p_dev->irq, if_cs_interrupt,
720 IRQF_SHARED, DRV_NAME, card);
722 pr_err("error in request_irq\n");
727 * Clear any interrupt cause that happened while sending
728 * firmware/initializing card
730 if_cs_write16(card, IF_CS_CARD_INT_CAUSE, IF_CS_BIT_MASK);
731 if_cs_enable_ints(card);
733 /* And finally bring the card up */
735 if (lbs_start_card(priv) != 0) {
736 pr_err("could not activate card\n");
737 free_irq(card->p_dev->irq, card);
742 /********************************************************************/
743 /* Callback functions for libertas.ko */
744 /********************************************************************/
746 /* Send commands or data packets to the card */
747 static int if_cs_host_to_card(struct lbs_private *priv,
756 priv->dnld_sent = DNLD_DATA_SENT;
757 if_cs_send_data(priv, buf, nb);
761 priv->dnld_sent = DNLD_CMD_SENT;
762 ret = if_cs_send_cmd(priv, buf, nb);
765 netdev_err(priv->dev, "%s: unsupported type %d\n",
773 static void if_cs_release(struct pcmcia_device *p_dev)
775 struct if_cs_card *card = p_dev->priv;
777 free_irq(p_dev->irq, card);
778 pcmcia_disable_device(p_dev);
780 ioport_unmap(card->iobase);
784 static int if_cs_ioprobe(struct pcmcia_device *p_dev, void *priv_data)
786 p_dev->resource[0]->flags &= ~IO_DATA_PATH_WIDTH;
787 p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
789 if (p_dev->resource[1]->end) {
790 pr_err("wrong CIS (check number of IO windows)\n");
794 /* This reserves IO space but doesn't actually enable it */
795 return pcmcia_request_io(p_dev);
798 static int if_cs_probe(struct pcmcia_device *p_dev)
801 unsigned int prod_id;
802 struct lbs_private *priv;
803 struct if_cs_card *card;
805 card = kzalloc(sizeof(struct if_cs_card), GFP_KERNEL);
812 p_dev->config_flags |= CONF_ENABLE_IRQ | CONF_AUTO_SET_IO;
814 if (pcmcia_loop_config(p_dev, if_cs_ioprobe, NULL)) {
815 pr_err("error in pcmcia_loop_config\n");
820 * Allocate an interrupt line. Note that this does not assign
821 * a handler to the interrupt, unless the 'Handler' member of
822 * the irq structure is initialized.
827 /* Initialize io access */
828 card->iobase = ioport_map(p_dev->resource[0]->start,
829 resource_size(p_dev->resource[0]));
831 pr_err("error in ioport_map\n");
836 ret = pcmcia_enable_device(p_dev);
838 pr_err("error in pcmcia_enable_device\n");
842 /* Finally, report what we've done */
843 lbs_deb_cs("irq %d, io %pR", p_dev->irq, p_dev->resource[0]);
846 * Most of the libertas cards can do unaligned register access, but some
847 * weird ones cannot. That's especially true for the CF8305 card.
849 card->align_regs = false;
851 card->model = get_model(p_dev->manf_id, p_dev->card_id);
852 if (card->model == MODEL_UNKNOWN) {
853 pr_err("unsupported manf_id 0x%04x / card_id 0x%04x\n",
854 p_dev->manf_id, p_dev->card_id);
859 /* Check if we have a current silicon */
860 prod_id = if_cs_read8(card, IF_CS_PRODUCT_ID);
861 if (card->model == MODEL_8305) {
862 card->align_regs = true;
863 if (prod_id < IF_CS_CF8305_B1_REV) {
864 pr_err("8305 rev B0 and older are not supported\n");
870 if ((card->model == MODEL_8381) && prod_id < IF_CS_CF8381_B3_REV) {
871 pr_err("8381 rev B2 and older are not supported\n");
876 if ((card->model == MODEL_8385) && prod_id < IF_CS_CF8385_B1_REV) {
877 pr_err("8385 rev B0 and older are not supported\n");
882 /* Make this card known to the libertas driver */
883 priv = lbs_add_card(card, &p_dev->dev);
889 /* Set up fields in lbs_private */
892 priv->hw_host_to_card = if_cs_host_to_card;
893 priv->enter_deep_sleep = NULL;
894 priv->exit_deep_sleep = NULL;
895 priv->reset_deep_sleep_wakeup = NULL;
898 ret = lbs_get_firmware_async(priv, &p_dev->dev, card->model, fw_table,
899 if_cs_prog_firmware);
901 pr_err("failed to find firmware (%d)\n", ret);
908 lbs_remove_card(priv);
910 ioport_unmap(card->iobase);
912 pcmcia_disable_device(p_dev);
918 static void if_cs_detach(struct pcmcia_device *p_dev)
920 struct if_cs_card *card = p_dev->priv;
922 lbs_stop_card(card->priv);
923 lbs_remove_card(card->priv);
924 if_cs_disable_ints(card);
925 if_cs_release(p_dev);
931 /********************************************************************/
932 /* Module initialization */
933 /********************************************************************/
935 static const struct pcmcia_device_id if_cs_ids[] = {
936 PCMCIA_DEVICE_MANF_CARD(CF8305_MANFID, CF8305_CARDID),
937 PCMCIA_DEVICE_MANF_CARD(CF8381_MANFID, CF8381_CARDID),
938 PCMCIA_DEVICE_MANF_CARD(CF8385_MANFID, CF8385_CARDID),
939 /* NOTE: keep in sync with get_model() */
942 MODULE_DEVICE_TABLE(pcmcia, if_cs_ids);
944 static struct pcmcia_driver lbs_driver = {
945 .owner = THIS_MODULE,
947 .probe = if_cs_probe,
948 .remove = if_cs_detach,
949 .id_table = if_cs_ids,
951 module_pcmcia_driver(lbs_driver);