aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/sundance.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/sundance.c')
-rw-r--r--drivers/net/sundance.c175
1 files changed, 46 insertions, 129 deletions
diff --git a/drivers/net/sundance.c b/drivers/net/sundance.c
index f13b2a195c7..6b8f4baf87f 100644
--- a/drivers/net/sundance.c
+++ b/drivers/net/sundance.c
@@ -16,91 +16,15 @@
16 16
17 Support and updates available at 17 Support and updates available at
18 http://www.scyld.com/network/sundance.html 18 http://www.scyld.com/network/sundance.html
19 [link no longer provides useful info -jgarzik]
20 Archives of the mailing list are still available at
21 http://www.beowulf.org/pipermail/netdrivers/
19 22
20
21 Version LK1.01a (jgarzik):
22 - Replace some MII-related magic numbers with constants
23
24 Version LK1.02 (D-Link):
25 - Add new board to PCI ID list
26 - Fix multicast bug
27
28 Version LK1.03 (D-Link):
29 - New Rx scheme, reduce Rx congestion
30 - Option to disable flow control
31
32 Version LK1.04 (D-Link):
33 - Tx timeout recovery
34 - More support for ethtool.
35
36 Version LK1.04a:
37 - Remove unused/constant members from struct pci_id_info
38 (which then allows removal of 'drv_flags' from private struct)
39 (jgarzik)
40 - If no phy is found, fail to load that board (jgarzik)
41 - Always start phy id scan at id 1 to avoid problems (Donald Becker)
42 - Autodetect where mii_preable_required is needed,
43 default to not needed. (Donald Becker)
44
45 Version LK1.04b:
46 - Remove mii_preamble_required module parameter (Donald Becker)
47 - Add per-interface mii_preamble_required (setting is autodetected)
48 (Donald Becker)
49 - Remove unnecessary cast from void pointer (jgarzik)
50 - Re-align comments in private struct (jgarzik)
51
52 Version LK1.04c (jgarzik):
53 - Support bitmapped message levels (NETIF_MSG_xxx), and the
54 two ethtool ioctls that get/set them
55 - Don't hand-code MII ethtool support, use standard API/lib
56
57 Version LK1.04d:
58 - Merge from Donald Becker's sundance.c: (Jason Lunz)
59 * proper support for variably-sized MTUs
60 * default to PIO, to fix chip bugs
61 - Add missing unregister_netdev (Jason Lunz)
62 - Add CONFIG_SUNDANCE_MMIO config option (jgarzik)
63 - Better rx buf size calculation (Donald Becker)
64
65 Version LK1.05 (D-Link):
66 - Fix DFE-580TX packet drop issue (for DL10050C)
67 - Fix reset_tx logic
68
69 Version LK1.06 (D-Link):
70 - Fix crash while unloading driver
71
72 Versin LK1.06b (D-Link):
73 - New tx scheme, adaptive tx_coalesce
74
75 Version LK1.07 (D-Link):
76 - Fix tx bugs in big-endian machines
77 - Remove unused max_interrupt_work module parameter, the new
78 NAPI-like rx scheme doesn't need it.
79 - Remove redundancy get_stats() in intr_handler(), those
80 I/O access could affect performance in ARM-based system
81 - Add Linux software VLAN support
82
83 Version LK1.08 (Philippe De Muyter phdm@macqel.be):
84 - Fix bug of custom mac address
85 (StationAddr register only accept word write)
86
87 Version LK1.09 (D-Link):
88 - Fix the flowctrl bug.
89 - Set Pause bit in MII ANAR if flow control enabled.
90
91 Version LK1.09a (ICPlus):
92 - Add the delay time in reading the contents of EEPROM
93
94 Version LK1.10 (Philippe De Muyter phdm@macqel.be):
95 - Make 'unblock interface after Tx underrun' work
96
97 Version LK1.11 (Pedro Alejandro Lopez-Valencia palopezv at gmail.com):
98 - Add support for IC Plus Corporation IP100A chipset
99*/ 23*/
100 24
101#define DRV_NAME "sundance" 25#define DRV_NAME "sundance"
102#define DRV_VERSION "1.01+LK1.11" 26#define DRV_VERSION "1.2"
103#define DRV_RELDATE "14-Jun-2006" 27#define DRV_RELDATE "11-Sep-2006"
104 28
105 29
106/* The user-configurable values. 30/* The user-configurable values.
@@ -185,7 +109,7 @@ static char *media[MAX_UNITS];
185#endif 109#endif
186 110
187/* These identify the driver base version and may not be removed. */ 111/* These identify the driver base version and may not be removed. */
188static char version[] __devinitdata = 112static char version[] =
189KERN_INFO DRV_NAME ".c:v" DRV_VERSION " " DRV_RELDATE " Written by Donald Becker\n" 113KERN_INFO DRV_NAME ".c:v" DRV_VERSION " " DRV_RELDATE " Written by Donald Becker\n"
190KERN_INFO " http://www.scyld.com/network/sundance.html\n"; 114KERN_INFO " http://www.scyld.com/network/sundance.html\n";
191 115
@@ -282,15 +206,15 @@ IVc. Errata
282#define USE_IO_OPS 1 206#define USE_IO_OPS 1
283#endif 207#endif
284 208
285static struct pci_device_id sundance_pci_tbl[] = { 209static const struct pci_device_id sundance_pci_tbl[] = {
286 {0x1186, 0x1002, 0x1186, 0x1002, 0, 0, 0}, 210 { 0x1186, 0x1002, 0x1186, 0x1002, 0, 0, 0 },
287 {0x1186, 0x1002, 0x1186, 0x1003, 0, 0, 1}, 211 { 0x1186, 0x1002, 0x1186, 0x1003, 0, 0, 1 },
288 {0x1186, 0x1002, 0x1186, 0x1012, 0, 0, 2}, 212 { 0x1186, 0x1002, 0x1186, 0x1012, 0, 0, 2 },
289 {0x1186, 0x1002, 0x1186, 0x1040, 0, 0, 3}, 213 { 0x1186, 0x1002, 0x1186, 0x1040, 0, 0, 3 },
290 {0x1186, 0x1002, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 4}, 214 { 0x1186, 0x1002, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 4 },
291 {0x13F0, 0x0201, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 5}, 215 { 0x13F0, 0x0201, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 5 },
292 {0x13F0, 0x0200, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 6}, 216 { 0x13F0, 0x0200, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 6 },
293 {0,} 217 { }
294}; 218};
295MODULE_DEVICE_TABLE(pci, sundance_pci_tbl); 219MODULE_DEVICE_TABLE(pci, sundance_pci_tbl);
296 220
@@ -301,7 +225,7 @@ enum {
301struct pci_id_info { 225struct pci_id_info {
302 const char *name; 226 const char *name;
303}; 227};
304static const struct pci_id_info pci_id_tbl[] = { 228static const struct pci_id_info pci_id_tbl[] __devinitdata = {
305 {"D-Link DFE-550TX FAST Ethernet Adapter"}, 229 {"D-Link DFE-550TX FAST Ethernet Adapter"},
306 {"D-Link DFE-550FX 100Mbps Fiber-optics Adapter"}, 230 {"D-Link DFE-550FX 100Mbps Fiber-optics Adapter"},
307 {"D-Link DFE-580TX 4 port Server Adapter"}, 231 {"D-Link DFE-580TX 4 port Server Adapter"},
@@ -309,7 +233,7 @@ static const struct pci_id_info pci_id_tbl[] = {
309 {"D-Link DL10050-based FAST Ethernet Adapter"}, 233 {"D-Link DL10050-based FAST Ethernet Adapter"},
310 {"Sundance Technology Alta"}, 234 {"Sundance Technology Alta"},
311 {"IC Plus Corporation IP100A FAST Ethernet Adapter"}, 235 {"IC Plus Corporation IP100A FAST Ethernet Adapter"},
312 {NULL,}, /* 0 terminated list. */ 236 { } /* terminate list. */
313}; 237};
314 238
315/* This driver was written to use PCI memory space, however x86-oriented 239/* This driver was written to use PCI memory space, however x86-oriented
@@ -507,7 +431,7 @@ static int __set_mac_addr(struct net_device *dev);
507static struct net_device_stats *get_stats(struct net_device *dev); 431static struct net_device_stats *get_stats(struct net_device *dev);
508static int netdev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd); 432static int netdev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd);
509static int netdev_close(struct net_device *dev); 433static int netdev_close(struct net_device *dev);
510static struct ethtool_ops ethtool_ops; 434static const struct ethtool_ops ethtool_ops;
511 435
512static void sundance_reset(struct net_device *dev, unsigned long reset_cmd) 436static void sundance_reset(struct net_device *dev, unsigned long reset_cmd)
513{ 437{
@@ -724,7 +648,7 @@ static int __devinit sundance_probe1 (struct pci_dev *pdev,
724 /* Reset the chip to erase previous misconfiguration. */ 648 /* Reset the chip to erase previous misconfiguration. */
725 if (netif_msg_hw(np)) 649 if (netif_msg_hw(np))
726 printk("ASIC Control is %x.\n", ioread32(ioaddr + ASICCtrl)); 650 printk("ASIC Control is %x.\n", ioread32(ioaddr + ASICCtrl));
727 iowrite16(0x00ff, ioaddr + ASICCtrl + 2); 651 sundance_reset(dev, 0x00ff << 16);
728 if (netif_msg_hw(np)) 652 if (netif_msg_hw(np))
729 printk("ASIC Control is now %x.\n", ioread32(ioaddr + ASICCtrl)); 653 printk("ASIC Control is now %x.\n", ioread32(ioaddr + ASICCtrl));
730 654
@@ -870,7 +794,7 @@ static int netdev_open(struct net_device *dev)
870 794
871 /* Do we need to reset the chip??? */ 795 /* Do we need to reset the chip??? */
872 796
873 i = request_irq(dev->irq, &intr_handler, SA_SHIRQ, dev->name, dev); 797 i = request_irq(dev->irq, &intr_handler, IRQF_SHARED, dev->name, dev);
874 if (i) 798 if (i)
875 return i; 799 return i;
876 800
@@ -983,7 +907,7 @@ static void tx_timeout(struct net_device *dev)
983 struct netdev_private *np = netdev_priv(dev); 907 struct netdev_private *np = netdev_priv(dev);
984 void __iomem *ioaddr = np->base; 908 void __iomem *ioaddr = np->base;
985 unsigned long flag; 909 unsigned long flag;
986 910
987 netif_stop_queue(dev); 911 netif_stop_queue(dev);
988 tasklet_disable(&np->tx_tasklet); 912 tasklet_disable(&np->tx_tasklet);
989 iowrite16(0, ioaddr + IntrEnable); 913 iowrite16(0, ioaddr + IntrEnable);
@@ -1000,13 +924,13 @@ static void tx_timeout(struct net_device *dev)
1000 le32_to_cpu(np->tx_ring[i].next_desc), 924 le32_to_cpu(np->tx_ring[i].next_desc),
1001 le32_to_cpu(np->tx_ring[i].status), 925 le32_to_cpu(np->tx_ring[i].status),
1002 (le32_to_cpu(np->tx_ring[i].status) >> 2) & 0xff, 926 (le32_to_cpu(np->tx_ring[i].status) >> 2) & 0xff,
1003 le32_to_cpu(np->tx_ring[i].frag[0].addr), 927 le32_to_cpu(np->tx_ring[i].frag[0].addr),
1004 le32_to_cpu(np->tx_ring[i].frag[0].length)); 928 le32_to_cpu(np->tx_ring[i].frag[0].length));
1005 } 929 }
1006 printk(KERN_DEBUG "TxListPtr=%08x netif_queue_stopped=%d\n", 930 printk(KERN_DEBUG "TxListPtr=%08x netif_queue_stopped=%d\n",
1007 ioread32(np->base + TxListPtr), 931 ioread32(np->base + TxListPtr),
1008 netif_queue_stopped(dev)); 932 netif_queue_stopped(dev));
1009 printk(KERN_DEBUG "cur_tx=%d(%02x) dirty_tx=%d(%02x)\n", 933 printk(KERN_DEBUG "cur_tx=%d(%02x) dirty_tx=%d(%02x)\n",
1010 np->cur_tx, np->cur_tx % TX_RING_SIZE, 934 np->cur_tx, np->cur_tx % TX_RING_SIZE,
1011 np->dirty_tx, np->dirty_tx % TX_RING_SIZE); 935 np->dirty_tx, np->dirty_tx % TX_RING_SIZE);
1012 printk(KERN_DEBUG "cur_rx=%d dirty_rx=%d\n", np->cur_rx, np->dirty_rx); 936 printk(KERN_DEBUG "cur_rx=%d dirty_rx=%d\n", np->cur_rx, np->dirty_rx);
@@ -1078,9 +1002,9 @@ static void tx_poll (unsigned long data)
1078 struct net_device *dev = (struct net_device *)data; 1002 struct net_device *dev = (struct net_device *)data;
1079 struct netdev_private *np = netdev_priv(dev); 1003 struct netdev_private *np = netdev_priv(dev);
1080 unsigned head = np->cur_task % TX_RING_SIZE; 1004 unsigned head = np->cur_task % TX_RING_SIZE;
1081 struct netdev_desc *txdesc = 1005 struct netdev_desc *txdesc =
1082 &np->tx_ring[(np->cur_tx - 1) % TX_RING_SIZE]; 1006 &np->tx_ring[(np->cur_tx - 1) % TX_RING_SIZE];
1083 1007
1084 /* Chain the next pointer */ 1008 /* Chain the next pointer */
1085 for (; np->cur_tx - np->cur_task > 0; np->cur_task++) { 1009 for (; np->cur_tx - np->cur_task > 0; np->cur_task++) {
1086 int entry = np->cur_task % TX_RING_SIZE; 1010 int entry = np->cur_task % TX_RING_SIZE;
@@ -1150,21 +1074,16 @@ reset_tx (struct net_device *dev)
1150 struct sk_buff *skb; 1074 struct sk_buff *skb;
1151 int i; 1075 int i;
1152 int irq = in_interrupt(); 1076 int irq = in_interrupt();
1153 1077
1154 /* Reset tx logic, TxListPtr will be cleaned */ 1078 /* Reset tx logic, TxListPtr will be cleaned */
1155 iowrite16 (TxDisable, ioaddr + MACCtrl1); 1079 iowrite16 (TxDisable, ioaddr + MACCtrl1);
1156 iowrite16 (TxReset | DMAReset | FIFOReset | NetworkReset, 1080 sundance_reset(dev, (NetworkReset|FIFOReset|DMAReset|TxReset) << 16);
1157 ioaddr + ASICCtrl + 2); 1081
1158 for (i=50; i > 0; i--) {
1159 if ((ioread16(ioaddr + ASICCtrl + 2) & ResetBusy) == 0)
1160 break;
1161 mdelay(1);
1162 }
1163 /* free all tx skbuff */ 1082 /* free all tx skbuff */
1164 for (i = 0; i < TX_RING_SIZE; i++) { 1083 for (i = 0; i < TX_RING_SIZE; i++) {
1165 skb = np->tx_skbuff[i]; 1084 skb = np->tx_skbuff[i];
1166 if (skb) { 1085 if (skb) {
1167 pci_unmap_single(np->pci_dev, 1086 pci_unmap_single(np->pci_dev,
1168 np->tx_ring[i].frag[0].addr, skb->len, 1087 np->tx_ring[i].frag[0].addr, skb->len,
1169 PCI_DMA_TODEVICE); 1088 PCI_DMA_TODEVICE);
1170 if (irq) 1089 if (irq)
@@ -1181,7 +1100,7 @@ reset_tx (struct net_device *dev)
1181 return 0; 1100 return 0;
1182} 1101}
1183 1102
1184/* The interrupt handler cleans up after the Tx thread, 1103/* The interrupt handler cleans up after the Tx thread,
1185 and schedule a Rx thread work */ 1104 and schedule a Rx thread work */
1186static irqreturn_t intr_handler(int irq, void *dev_instance, struct pt_regs *rgs) 1105static irqreturn_t intr_handler(int irq, void *dev_instance, struct pt_regs *rgs)
1187{ 1106{
@@ -1262,8 +1181,8 @@ static irqreturn_t intr_handler(int irq, void *dev_instance, struct pt_regs *rgs
1262 } else { 1181 } else {
1263 hw_frame_id = ioread8(ioaddr + TxFrameId); 1182 hw_frame_id = ioread8(ioaddr + TxFrameId);
1264 } 1183 }
1265 1184
1266 if (np->pci_rev_id >= 0x14) { 1185 if (np->pci_rev_id >= 0x14) {
1267 spin_lock(&np->lock); 1186 spin_lock(&np->lock);
1268 for (; np->cur_tx - np->dirty_tx > 0; np->dirty_tx++) { 1187 for (; np->cur_tx - np->dirty_tx > 0; np->dirty_tx++) {
1269 int entry = np->dirty_tx % TX_RING_SIZE; 1188 int entry = np->dirty_tx % TX_RING_SIZE;
@@ -1275,7 +1194,7 @@ static irqreturn_t intr_handler(int irq, void *dev_instance, struct pt_regs *rgs
1275 !(le32_to_cpu(np->tx_ring[entry].status) 1194 !(le32_to_cpu(np->tx_ring[entry].status)
1276 & 0x00010000)) 1195 & 0x00010000))
1277 break; 1196 break;
1278 if (sw_frame_id == (hw_frame_id + 1) % 1197 if (sw_frame_id == (hw_frame_id + 1) %
1279 TX_RING_SIZE) 1198 TX_RING_SIZE)
1280 break; 1199 break;
1281 skb = np->tx_skbuff[entry]; 1200 skb = np->tx_skbuff[entry];
@@ -1294,7 +1213,7 @@ static irqreturn_t intr_handler(int irq, void *dev_instance, struct pt_regs *rgs
1294 for (; np->cur_tx - np->dirty_tx > 0; np->dirty_tx++) { 1213 for (; np->cur_tx - np->dirty_tx > 0; np->dirty_tx++) {
1295 int entry = np->dirty_tx % TX_RING_SIZE; 1214 int entry = np->dirty_tx % TX_RING_SIZE;
1296 struct sk_buff *skb; 1215 struct sk_buff *skb;
1297 if (!(le32_to_cpu(np->tx_ring[entry].status) 1216 if (!(le32_to_cpu(np->tx_ring[entry].status)
1298 & 0x00010000)) 1217 & 0x00010000))
1299 break; 1218 break;
1300 skb = np->tx_skbuff[entry]; 1219 skb = np->tx_skbuff[entry];
@@ -1309,7 +1228,7 @@ static irqreturn_t intr_handler(int irq, void *dev_instance, struct pt_regs *rgs
1309 } 1228 }
1310 spin_unlock(&np->lock); 1229 spin_unlock(&np->lock);
1311 } 1230 }
1312 1231
1313 if (netif_queue_stopped(dev) && 1232 if (netif_queue_stopped(dev) &&
1314 np->cur_tx - np->dirty_tx < TX_QUEUE_LEN - 4) { 1233 np->cur_tx - np->dirty_tx < TX_QUEUE_LEN - 4) {
1315 /* The ring is no longer full, clear busy flag. */ 1234 /* The ring is no longer full, clear busy flag. */
@@ -1545,8 +1464,6 @@ static void set_rx_mode(struct net_device *dev)
1545 int i; 1464 int i;
1546 1465
1547 if (dev->flags & IFF_PROMISC) { /* Set promiscuous. */ 1466 if (dev->flags & IFF_PROMISC) { /* Set promiscuous. */
1548 /* Unconditionally log net taps. */
1549 printk(KERN_NOTICE "%s: Promiscuous mode enabled.\n", dev->name);
1550 memset(mc_filter, 0xff, sizeof(mc_filter)); 1467 memset(mc_filter, 0xff, sizeof(mc_filter));
1551 rx_mode = AcceptBroadcast | AcceptMulticast | AcceptAll | AcceptMyPhys; 1468 rx_mode = AcceptBroadcast | AcceptMulticast | AcceptAll | AcceptMyPhys;
1552 } else if ((dev->mc_count > multicast_filter_limit) 1469 } else if ((dev->mc_count > multicast_filter_limit)
@@ -1652,7 +1569,7 @@ static void set_msglevel(struct net_device *dev, u32 val)
1652 np->msg_enable = val; 1569 np->msg_enable = val;
1653} 1570}
1654 1571
1655static struct ethtool_ops ethtool_ops = { 1572static const struct ethtool_ops ethtool_ops = {
1656 .begin = check_if_running, 1573 .begin = check_if_running,
1657 .get_drvinfo = get_drvinfo, 1574 .get_drvinfo = get_drvinfo,
1658 .get_settings = get_settings, 1575 .get_settings = get_settings,
@@ -1681,18 +1598,18 @@ static int netdev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
1681 case SIOCDEVPRIVATE: 1598 case SIOCDEVPRIVATE:
1682 for (i=0; i<TX_RING_SIZE; i++) { 1599 for (i=0; i<TX_RING_SIZE; i++) {
1683 printk(KERN_DEBUG "%02x %08llx %08x %08x(%02x) %08x %08x\n", i, 1600 printk(KERN_DEBUG "%02x %08llx %08x %08x(%02x) %08x %08x\n", i,
1684 (unsigned long long)(np->tx_ring_dma + i*sizeof(*np->tx_ring)), 1601 (unsigned long long)(np->tx_ring_dma + i*sizeof(*np->tx_ring)),
1685 le32_to_cpu(np->tx_ring[i].next_desc), 1602 le32_to_cpu(np->tx_ring[i].next_desc),
1686 le32_to_cpu(np->tx_ring[i].status), 1603 le32_to_cpu(np->tx_ring[i].status),
1687 (le32_to_cpu(np->tx_ring[i].status) >> 2) 1604 (le32_to_cpu(np->tx_ring[i].status) >> 2)
1688 & 0xff, 1605 & 0xff,
1689 le32_to_cpu(np->tx_ring[i].frag[0].addr), 1606 le32_to_cpu(np->tx_ring[i].frag[0].addr),
1690 le32_to_cpu(np->tx_ring[i].frag[0].length)); 1607 le32_to_cpu(np->tx_ring[i].frag[0].length));
1691 } 1608 }
1692 printk(KERN_DEBUG "TxListPtr=%08x netif_queue_stopped=%d\n", 1609 printk(KERN_DEBUG "TxListPtr=%08x netif_queue_stopped=%d\n",
1693 ioread32(np->base + TxListPtr), 1610 ioread32(np->base + TxListPtr),
1694 netif_queue_stopped(dev)); 1611 netif_queue_stopped(dev));
1695 printk(KERN_DEBUG "cur_tx=%d(%02x) dirty_tx=%d(%02x)\n", 1612 printk(KERN_DEBUG "cur_tx=%d(%02x) dirty_tx=%d(%02x)\n",
1696 np->cur_tx, np->cur_tx % TX_RING_SIZE, 1613 np->cur_tx, np->cur_tx % TX_RING_SIZE,
1697 np->dirty_tx, np->dirty_tx % TX_RING_SIZE); 1614 np->dirty_tx, np->dirty_tx % TX_RING_SIZE);
1698 printk(KERN_DEBUG "cur_rx=%d dirty_rx=%d\n", np->cur_rx, np->dirty_rx); 1615 printk(KERN_DEBUG "cur_rx=%d dirty_rx=%d\n", np->cur_rx, np->dirty_rx);
@@ -1700,7 +1617,7 @@ static int netdev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
1700 printk(KERN_DEBUG "TxStatus=%04x\n", ioread16(ioaddr + TxStatus)); 1617 printk(KERN_DEBUG "TxStatus=%04x\n", ioread16(ioaddr + TxStatus));
1701 return 0; 1618 return 0;
1702 } 1619 }
1703 1620
1704 1621
1705 return rc; 1622 return rc;
1706} 1623}
@@ -1814,7 +1731,7 @@ static int __init sundance_init(void)
1814#ifdef MODULE 1731#ifdef MODULE
1815 printk(version); 1732 printk(version);
1816#endif 1733#endif
1817 return pci_module_init(&sundance_driver); 1734 return pci_register_driver(&sundance_driver);
1818} 1735}
1819 1736
1820static void __exit sundance_exit(void) 1737static void __exit sundance_exit(void)