···22/*33 Written 1998-2000 by Donald Becker.4455- Current maintainer is Ion Badulescu <ionut@cs.columbia.edu>. Please55+ Current maintainer is Ion Badulescu <ionut ta badula tod org>. Please66 send all bug reports to me, and not to Donald Becker, as this code77 has been heavily modified from Donald's original version.88···129129 - put the chip to a D3 slumber on driver unload130130 - added config option to enable/disable NAPI131131132132-TODO: bugfixes (no bugs known as of right now)132132+ LK1.4.2 (Ion Badulescu)133133+ - finally added firmware (GPL'ed by Adaptec)134134+ - removed compatibility code for 2.2.x135135+136136+TODO: - fix forced speed/duplexing code (broken a long time ago, when137137+ somebody converted the driver to use the generic MII code)138138+ - fix VLAN support133139*/134140135141#define DRV_NAME "starfire"136136-#define DRV_VERSION "1.03+LK1.4.1"137137-#define DRV_RELDATE "February 10, 2002"142142+#define DRV_VERSION "1.03+LK1.4.2"143143+#define DRV_RELDATE "January 19, 2005"138144139145#include <linux/config.h>140146#include <linux/version.h>···151145#include <linux/etherdevice.h>152146#include <linux/init.h>153147#include <linux/delay.h>148148+#include <linux/crc32.h>149149+#include <linux/ethtool.h>150150+#include <linux/mii.h>151151+#include <linux/if_vlan.h>154152#include <asm/processor.h> /* Processor type for cache alignment. */155153#include <asm/uaccess.h>156154#include <asm/io.h>157155158158-/*159159- * Adaptec's license for their drivers (which is where I got the160160- * firmware files) does not allow one to redistribute them. Thus, we can't161161- * include the firmware with this driver.162162- *163163- * However, should a legal-to-distribute firmware become available,164164- * the driver developer would need only to obtain the firmware in the165165- * form of a C header file.166166- * Once that's done, the #undef below must be changed into a #define167167- * for this driver to really use the firmware. Note that Rx/Tx168168- * hardware TCP checksumming is not possible without the firmware.169169- *170170- * WANTED: legal firmware to include with this GPL'd driver.171171- */172172-#undef HAS_FIRMWARE156156+#include "starfire_firmware.h"173157/*174158 * The current frame processor firmware fails to checksum a fragment175159 * of length 1. If and when this is fixed, the #define below can be removed.···168172/*169173 * Define this if using the driver with the zero-copy patch170174 */171171-#if defined(HAS_FIRMWARE) && defined(MAX_SKB_FRAGS)172175#define ZEROCOPY173173-#endif174174-175175-#ifdef HAS_FIRMWARE176176-#include "starfire_firmware.h"177177-#endif /* HAS_FIRMWARE */178176179177#if defined(CONFIG_VLAN_8021Q) || defined(CONFIG_VLAN_8021Q_MODULE)180178#define VLAN_SUPPORT···192202 The Starfire has a 512 element hash table based on the Ethernet CRC. */193203static int multicast_filter_limit = 512;194204/* Whether to do TCP/UDP checksums in hardware */195195-#ifdef HAS_FIRMWARE196205static int enable_hw_cksum = 1;197197-#else198198-static int enable_hw_cksum = 0;199199-#endif200206201207#define PKT_BUF_SZ 1536 /* Size of each temporary Rx buffer.*/202208/*···277291#define RX_DESC_ADDR_SIZE RxDescAddr32bit278292#endif279293280280-#ifdef MAX_SKB_FRAGS281294#define skb_first_frag_len(skb) skb_headlen(skb)282295#define skb_num_frags(skb) (skb_shinfo(skb)->nr_frags + 1)283283-#else /* not MAX_SKB_FRAGS */284284-#define skb_first_frag_len(skb) (skb->len)285285-#define skb_num_frags(skb) 1286286-#endif /* not MAX_SKB_FRAGS */287287-288288-/* 2.2.x compatibility code */289289-#if LINUX_VERSION_CODE < 0x20300290290-291291-#include "starfire-kcomp22.h"292292-293293-#else /* LINUX_VERSION_CODE > 0x20300 */294294-295295-#include <linux/crc32.h>296296-#include <linux/ethtool.h>297297-#include <linux/mii.h>298298-299299-#include <linux/if_vlan.h>300300-301301-#define init_tx_timer(dev, func, timeout) \302302- dev->tx_timeout = func; \303303- dev->watchdog_timeo = timeout;304304-#define kick_tx_timer(dev, func, timeout)305305-306306-#define netif_start_if(dev)307307-#define netif_stop_if(dev)308308-309309-#define PCI_SLOT_NAME(pci_dev) pci_name(pci_dev)310310-311311-#endif /* LINUX_VERSION_CODE > 0x20300 */312296313297#ifdef HAVE_NETDEV_POLL314298#define init_poll(dev) \299299+do { \315300 dev->poll = &netdev_poll; \316316- dev->weight = max_interrupt_work;301301+ dev->weight = max_interrupt_work; \302302+} while (0)317303#define netdev_rx(dev, ioaddr) \318304do { \319305 u32 intr_enable; \···299341 /* Paranoia check */ \300342 intr_enable = readl(ioaddr + IntrEnable); \301343 if (intr_enable & (IntrRxDone | IntrRxEmpty)) { \302302- printk("%s: interrupt while in polling mode!\n", dev->name); \344344+ printk(KERN_INFO "%s: interrupt while in polling mode!\n", dev->name); \303345 intr_enable &= ~(IntrRxDone | IntrRxEmpty); \304346 writel(intr_enable, ioaddr + IntrEnable); \305347 } \···329371MODULE_AUTHOR("Donald Becker <becker@scyld.com>");330372MODULE_DESCRIPTION("Adaptec Starfire Ethernet driver");331373MODULE_LICENSE("GPL");374374+MODULE_VERSION(DRV_VERSION);332375333376module_param(max_interrupt_work, int, 0);334377module_param(mtu, int, 0);···384425minimum-length padding. It does not use the completion queue385426consumer index, but instead checks for non-zero status entries.386427387387-For receive this driver uses type 0/1/2/3 receive descriptors. The driver428428+For receive this driver uses type 2/3 receive descriptors. The driver388429allocates full frame size skbuffs for the Rx ring buffers, so all frames389430should fit in a single descriptor. The driver does not use the completion390431queue consumer index, but instead checks for non-zero status entries.···435476436477*/437478438438-479479+439480440481enum chip_capability_flags {CanHaveMII=1, };441482···629670 u32 timestamp;630671};631672/* XXX: this is ugly and I'm not sure it's worth the trouble -Ion */632632-#ifdef HAS_FIRMWARE633673#ifdef VLAN_SUPPORT634674typedef struct full_rx_done_desc rx_done_desc;635675#define RxComplType RxComplType3···636678typedef struct csum_rx_done_desc rx_done_desc;637679#define RxComplType RxComplType2638680#endif /* not VLAN_SUPPORT */639639-#else /* not HAS_FIRMWARE */640640-#ifdef VLAN_SUPPORT641641-typedef struct basic_rx_done_desc rx_done_desc;642642-#define RxComplType RxComplType1643643-#else /* not VLAN_SUPPORT */644644-typedef struct short_rx_done_desc rx_done_desc;645645-#define RxComplType RxComplType0646646-#endif /* not VLAN_SUPPORT */647647-#endif /* not HAS_FIRMWARE */648681649682enum rx_done_bits {650683 RxOK=0x20000000, RxFIFOErr=0x10000000, RxBufQ2=0x08000000,···847898 /* enable MWI -- it vastly improves Rx performance on sparc64 */848899 pci_set_mwi(pdev);849900850850-#ifdef MAX_SKB_FRAGS851851- dev->features |= NETIF_F_SG;852852-#endif /* MAX_SKB_FRAGS */853901#ifdef ZEROCOPY854902 /* Starfire can do TCP/UDP checksumming */855903 if (enable_hw_cksum)856856- dev->features |= NETIF_F_IP_CSUM;904904+ dev->features |= NETIF_F_IP_CSUM | NETIF_F_SG;857905#endif /* ZEROCOPY */858906#ifdef VLAN_SUPPORT859907 dev->features |= NETIF_F_HW_VLAN_RX | NETIF_F_HW_VLAN_FILTER;···9541008 /* The chip-specific entries in the device structure. */9551009 dev->open = &netdev_open;9561010 dev->hard_start_xmit = &start_tx;957957- init_tx_timer(dev, tx_timeout, TX_TIMEOUT);10111011+ dev->tx_timeout = tx_timeout;10121012+ dev->watchdog_timeo = TX_TIMEOUT;9581013 init_poll(dev);9591014 dev->stop = &netdev_close;9601015 dev->get_stats = &get_stats;···9861039 if ((mdio_read(dev, phy, MII_BMCR) & BMCR_RESET) == 0)9871040 break;9881041 if (boguscnt == 0) {989989- printk("%s: PHY reset never completed!\n", dev->name);10421042+ printk("%s: PHY#%d reset never completed!\n", dev->name, phy);9901043 continue;9911044 }9921045 mii_status = mdio_read(dev, phy, MII_BMSR);···10571110 size_t tx_done_q_size, rx_done_q_size, tx_ring_size, rx_ring_size;1058111110591112 /* Do we ever need to reset the chip??? */11131113+10601114 retval = request_irq(dev->irq, &intr_handler, SA_SHIRQ, dev->name, dev);10611115 if (retval)10621116 return retval;···1159121111601212 writel(np->intr_timer_ctrl, ioaddr + IntrTimerCtrl);1161121311621162- netif_start_if(dev);11631214 netif_start_queue(dev);1164121511651216 if (debug > 1)···11851238 writel(ETH_P_8021Q, ioaddr + VlanType);11861239#endif /* VLAN_SUPPORT */1187124011881188-#ifdef HAS_FIRMWARE11891241 /* Load Rx/Tx firmware into the frame processors */11901242 for (i = 0; i < FIRMWARE_RX_SIZE * 2; i++)11911243 writel(firmware_rx[i], ioaddr + RxGfpMem + i * 4);11921244 for (i = 0; i < FIRMWARE_TX_SIZE * 2; i++)11931245 writel(firmware_tx[i], ioaddr + TxGfpMem + i * 4);11941194-#endif /* HAS_FIRMWARE */11951246 if (enable_hw_cksum)11961247 /* Enable the Rx and Tx units, and the Rx/Tx frame processors. */11971248 writel(TxEnable|TxGFPEnable|RxEnable|RxGFPEnable, ioaddr + GenCtrl);···13231378 u32 status;13241379 int i;1325138013261326- kick_tx_timer(dev, tx_timeout, TX_TIMEOUT);13271327-13281381 /*13291382 * be cautious here, wrapping the queue has weird semantics13301383 * and we may not have enough slots even when it seems we do.···13471404 }1348140513491406 if (has_bad_length)13501350- skb_checksum_help(skb);14071407+ skb_checksum_help(skb, 0);13511408 }13521409#endif /* ZEROCOPY && HAS_BROKEN_FIRMWARE */13531410···13761433 np->tx_info[entry].mapping =13771434 pci_map_single(np->pci_dev, skb->data, skb_first_frag_len(skb), PCI_DMA_TODEVICE);13781435 } else {13791379-#ifdef MAX_SKB_FRAGS13801436 skb_frag_t *this_frag = &skb_shinfo(skb)->frags[i - 1];13811437 status |= this_frag->size;13821438 np->tx_info[entry].mapping =13831439 pci_map_single(np->pci_dev, page_address(this_frag->page) + this_frag->page_offset, this_frag->size, PCI_DMA_TODEVICE);13841384-#endif /* MAX_SKB_FRAGS */13851440 }1386144113871442 np->tx_ring[entry].addr = cpu_to_dma(np->tx_info[entry].mapping);···14721531 np->tx_info[entry].mapping = 0;14731532 np->dirty_tx += np->tx_info[entry].used_slots;14741533 entry = (entry + np->tx_info[entry].used_slots) % TX_RING_SIZE;14751475-#ifdef MAX_SKB_FRAGS14761534 {14771535 int i;14781536 for (i = 0; i < skb_shinfo(skb)->nr_frags; i++) {···14831543 entry++;14841544 }14851545 }14861486-#endif /* MAX_SKB_FRAGS */15461546+14871547 dev_kfree_skb_irq(skb);14881548 }14891549 np->tx_done_q[np->tx_done].status = 0;···15431603 if (debug > 4)15441604 printk(KERN_DEBUG " netdev_rx() status of %d was %#8.8x.\n", np->rx_done, desc_status);15451605 if (!(desc_status & RxOK)) {15461546- /* There was a error. */16061606+ /* There was an error. */15471607 if (debug > 2)15481608 printk(KERN_DEBUG " netdev_rx() Rx error was %#8.8x.\n", desc_status);15491609 np->stats.rx_errors++;···15961656#endif1597165715981658 skb->protocol = eth_type_trans(skb, dev);15991599-#if defined(HAS_FIRMWARE) || defined(VLAN_SUPPORT)16591659+#ifdef VLAN_SUPPORT16001660 if (debug > 4)16011661 printk(KERN_DEBUG " netdev_rx() status2 of %d was %#4.4x.\n", np->rx_done, le16_to_cpu(desc->status2));16021662#endif16031603-#ifdef HAS_FIRMWARE16041663 if (le16_to_cpu(desc->status2) & 0x0100) {16051664 skb->ip_summed = CHECKSUM_UNNECESSARY;16061665 np->stats.rx_compressed++;···16181679 skb->csum = le16_to_cpu(desc->csum);16191680 printk(KERN_DEBUG "%s: checksum_hw, status2 = %#x\n", dev->name, le16_to_cpu(desc->status2));16201681 }16211621-#endif /* HAS_FIRMWARE */16221682#ifdef VLAN_SUPPORT16231683 if (np->vlgrp && le16_to_cpu(desc->status2) & 0x0200) {16241684 if (debug > 4)···18381900}183919011840190218411841-/* Chips may use the upper or lower CRC bits, and may reverse and/or invert18421842- them. Select the endian-ness that results in minimal calculations.18431843-*/18441903static void set_rx_mode(struct net_device *dev)18451904{18461905 struct netdev_private *np = netdev_priv(dev);···19041969 memset(mc_filter, 0, sizeof(mc_filter));19051970 for (i = 0, mclist = dev->mc_list; mclist && i < dev->mc_count;19061971 i++, mclist = mclist->next) {19721972+ /* The chip uses the upper 9 CRC bits19731973+ as index into the hash table */19071974 int bit_nr = ether_crc_le(ETH_ALEN, mclist->dmi_addr) >> 23;19081975 __u32 *fptr = (__u32 *) &mc_filter[(bit_nr >> 4) & ~1];19091976···19382001 struct netdev_private *np = netdev_priv(dev);19392002 strcpy(info->driver, DRV_NAME);19402003 strcpy(info->version, DRV_VERSION);19411941- strcpy(info->bus_info, PCI_SLOT_NAME(np->pci_dev));20042004+ strcpy(info->bus_info, pci_name(np->pci_dev));19422005}1943200619442007static int get_settings(struct net_device *dev, struct ethtool_cmd *ecmd)···20202083 int i;2021208420222085 netif_stop_queue(dev);20232023- netif_stop_if(dev);2024208620252087 if (debug > 1) {20262088 printk(KERN_DEBUG "%s: Shutting down ethercard, Intr status %#8.8x.\n",···21202184/* when a module, this is printed whether or not devices are found in probe */21212185#ifdef MODULE21222186 printk(version);21872187+#ifdef HAVE_NETDEV_POLL21882188+ printk(KERN_INFO DRV_NAME ": polling (NAPI) enabled\n");21892189+#else21902190+ printk(KERN_INFO DRV_NAME ": polling (NAPI) disabled\n");21232191#endif21922192+#endif21932193+21242194#ifndef ADDR_64BITS21252195 /* we can do this test only at run-time... sigh */21262196 if (sizeof(dma_addr_t) == sizeof(u64)) {···21342192 return -ENODEV;21352193 }21362194#endif /* not ADDR_64BITS */21372137-#ifndef HAS_FIRMWARE21382138- /* unconditionally disable hw cksums if firmware is not present */21392139- enable_hw_cksum = 0;21402140-#endif /* not HAS_FIRMWARE */21412195 return pci_module_init (&starfire_driver);21422196}21432197
+346
drivers/net/starfire_firmware.h
···11+/*22+ * Copyright 2003 Adaptec, Inc.33+ *44+ * Please read the following license before using the Adaptec Software55+ * ("Program"). If you do not agree to the license terms, do not use the66+ * Program:77+ *88+ * You agree to be bound by version 2 of the General Public License ("GPL")99+ * dated June 1991, which can be found at http://www.fsf.org/licenses/gpl.html.1010+ * If the link is broken, write to Free Software Foundation, 59 Temple Place,1111+ * Boston, Massachusetts 02111-1307.1212+ *1313+ * BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE IT IS LICENSED "AS IS" AND1414+ * THERE IS NO WARRANTY FOR THE PROGRAM, INCLUDING BUT NOT LIMITED TO THE1515+ * IMPLIED WARRANTIES OF MERCHANTIBILITY OR FITNESS FOR A PARTICULAR PURPOSE1616+ * (TO THE EXTENT PERMITTED BY APPLICABLE LAW). USE OF THE PROGRAM IS AT YOUR1717+ * OWN RISK. IN NO EVENT WILL ADAPTEC OR ITS LICENSORS BE LIABLE TO YOU FOR1818+ * DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES1919+ * ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM.2020+ *2121+ */2222+2323+static const u32 firmware_rx[] = {2424+ 0x010003dc, 0x00000000,2525+ 0x04000421, 0x00000086,2626+ 0x80000015, 0x0000180e,2727+ 0x81000015, 0x00006664,2828+ 0x1a0040ab, 0x00000b06,2929+ 0x14200011, 0x00000000,3030+ 0x14204022, 0x0000aaaa,3131+ 0x14204022, 0x00000300,3232+ 0x14204022, 0x00000000,3333+ 0x1a0040ab, 0x00000b14,3434+ 0x14200011, 0x00000000,3535+ 0x83000015, 0x00000002,3636+ 0x04000021, 0x00000000,3737+ 0x00000010, 0x00000000,3838+ 0x04000421, 0x00000087,3939+ 0x00000010, 0x00000000,4040+ 0x00000010, 0x00000000,4141+ 0x00008015, 0x00000000,4242+ 0x0000003e, 0x00000000,4343+ 0x00000010, 0x00000000,4444+ 0x82000015, 0x00004000,4545+ 0x009e8050, 0x00000000,4646+ 0x03008015, 0x00000000,4747+ 0x86008015, 0x00000000,4848+ 0x82000015, 0x00008000,4949+ 0x0100001c, 0x00000000,5050+ 0x000050a0, 0x0000010c,5151+ 0x4e20d011, 0x00006008,5252+ 0x1420d012, 0x00004008,5353+ 0x0000f090, 0x00007000,5454+ 0x0000c8b0, 0x00003000,5555+ 0x00004040, 0x00000000,5656+ 0x00108015, 0x00000000,5757+ 0x00a2c150, 0x00004000,5858+ 0x00a400b0, 0x00000014,5959+ 0x00000020, 0x00000000,6060+ 0x2500400d, 0x00002525,6161+ 0x00047220, 0x00003100,6262+ 0x00934070, 0x00000000,6363+ 0x00000020, 0x00000000,6464+ 0x00924460, 0x00000184,6565+ 0x2b20c011, 0x00000000,6666+ 0x0000c420, 0x00000540,6767+ 0x36014018, 0x0000422d,6868+ 0x14200011, 0x00000000,6969+ 0x00924460, 0x00000183,7070+ 0x3200001f, 0x00000034,7171+ 0x02ac0015, 0x00000002,7272+ 0x00a60110, 0x00000008,7373+ 0x42200011, 0x00000000,7474+ 0x00924060, 0x00000103,7575+ 0x0000001e, 0x00000000,7676+ 0x00000020, 0x00000100,7777+ 0x0000001e, 0x00000000,7878+ 0x00924460, 0x00000086,7979+ 0x00004080, 0x00000000,8080+ 0x0092c070, 0x00000000,8181+ 0x00924060, 0x00000100,8282+ 0x0000c890, 0x00005000,8383+ 0x00a6c110, 0x00000000,8484+ 0x00b0c090, 0x00000012,8585+ 0x021c0015, 0x00000000,8686+ 0x3200001f, 0x00000034,8787+ 0x00924460, 0x00000510,8888+ 0x44210011, 0x00000000,8989+ 0x42000011, 0x00000000,9090+ 0x83000015, 0x00000040,9191+ 0x00924460, 0x00000508,9292+ 0x45014018, 0x00004545,9393+ 0x00808050, 0x00000000,9494+ 0x62208012, 0x00000000,9595+ 0x82000015, 0x00000800,9696+ 0x15200011, 0x00000000,9797+ 0x00000010, 0x00000000,9898+ 0x00000010, 0x00000000,9999+ 0x00000010, 0x00000000,100100+ 0x00000010, 0x00000000,101101+ 0x00000010, 0x00000000,102102+ 0x80000015, 0x0000eea4,103103+ 0x81000015, 0x0000005f,104104+ 0x00000060, 0x00000000,105105+ 0x00004120, 0x00000000,106106+ 0x00004a00, 0x00004000,107107+ 0x00924460, 0x00000190,108108+ 0x5601401a, 0x00005956,109109+ 0x14000011, 0x00000000,110110+ 0x00934050, 0x00000018,111111+ 0x00930050, 0x00000018,112112+ 0x3601403a, 0x0000002d,113113+ 0x000643a9, 0x00000000,114114+ 0x0000c420, 0x00000140,115115+ 0x5601401a, 0x00005956,116116+ 0x14000011, 0x00000000,117117+ 0x00000010, 0x00000000,118118+ 0x00000010, 0x00000000,119119+ 0x000642a9, 0x00000000,120120+ 0x00024420, 0x00000183,121121+ 0x5601401a, 0x00005956,122122+ 0x82000015, 0x00002000,123123+ 0x15200011, 0x00000000,124124+ 0x82000015, 0x00000010,125125+ 0x15200011, 0x00000000,126126+ 0x82000015, 0x00000010,127127+ 0x15200011, 0x00000000,128128+}; /* 104 Rx instructions */129129+#define FIRMWARE_RX_SIZE 104130130+131131+static const u32 firmware_tx[] = {132132+ 0x010003dc, 0x00000000,133133+ 0x04000421, 0x00000086,134134+ 0x80000015, 0x0000180e,135135+ 0x81000015, 0x00006664,136136+ 0x1a0040ab, 0x00000b06,137137+ 0x14200011, 0x00000000,138138+ 0x14204022, 0x0000aaaa,139139+ 0x14204022, 0x00000300,140140+ 0x14204022, 0x00000000,141141+ 0x1a0040ab, 0x00000b14,142142+ 0x14200011, 0x00000000,143143+ 0x83000015, 0x00000002,144144+ 0x04000021, 0x00000000,145145+ 0x00000010, 0x00000000,146146+ 0x04000421, 0x00000087,147147+ 0x00000010, 0x00000000,148148+ 0x00000010, 0x00000000,149149+ 0x00008015, 0x00000000,150150+ 0x0000003e, 0x00000000,151151+ 0x00000010, 0x00000000,152152+ 0x82000015, 0x00004000,153153+ 0x009e8050, 0x00000000,154154+ 0x03008015, 0x00000000,155155+ 0x86008015, 0x00000000,156156+ 0x82000015, 0x00008000,157157+ 0x0100001c, 0x00000000,158158+ 0x000050a0, 0x0000010c,159159+ 0x4e20d011, 0x00006008,160160+ 0x1420d012, 0x00004008,161161+ 0x0000f090, 0x00007000,162162+ 0x0000c8b0, 0x00003000,163163+ 0x00004040, 0x00000000,164164+ 0x00108015, 0x00000000,165165+ 0x00a2c150, 0x00004000,166166+ 0x00a400b0, 0x00000014,167167+ 0x00000020, 0x00000000,168168+ 0x2500400d, 0x00002525,169169+ 0x00047220, 0x00003100,170170+ 0x00934070, 0x00000000,171171+ 0x00000020, 0x00000000,172172+ 0x00924460, 0x00000184,173173+ 0x2b20c011, 0x00000000,174174+ 0x0000c420, 0x00000540,175175+ 0x36014018, 0x0000422d,176176+ 0x14200011, 0x00000000,177177+ 0x00924460, 0x00000183,178178+ 0x3200001f, 0x00000034,179179+ 0x02ac0015, 0x00000002,180180+ 0x00a60110, 0x00000008,181181+ 0x42200011, 0x00000000,182182+ 0x00924060, 0x00000103,183183+ 0x0000001e, 0x00000000,184184+ 0x00000020, 0x00000100,185185+ 0x0000001e, 0x00000000,186186+ 0x00924460, 0x00000086,187187+ 0x00004080, 0x00000000,188188+ 0x0092c070, 0x00000000,189189+ 0x00924060, 0x00000100,190190+ 0x0000c890, 0x00005000,191191+ 0x00a6c110, 0x00000000,192192+ 0x00b0c090, 0x00000012,193193+ 0x021c0015, 0x00000000,194194+ 0x3200001f, 0x00000034,195195+ 0x00924460, 0x00000510,196196+ 0x44210011, 0x00000000,197197+ 0x42000011, 0x00000000,198198+ 0x83000015, 0x00000040,199199+ 0x00924460, 0x00000508,200200+ 0x45014018, 0x00004545,201201+ 0x00808050, 0x00000000,202202+ 0x62208012, 0x00000000,203203+ 0x82000015, 0x00000800,204204+ 0x15200011, 0x00000000,205205+ 0x00000010, 0x00000000,206206+ 0x00000010, 0x00000000,207207+ 0x00000010, 0x00000000,208208+ 0x00000010, 0x00000000,209209+ 0x00000010, 0x00000000,210210+ 0x80000015, 0x0000eea4,211211+ 0x81000015, 0x0000005f,212212+ 0x00000060, 0x00000000,213213+ 0x00004120, 0x00000000,214214+ 0x00004a00, 0x00004000,215215+ 0x00924460, 0x00000190,216216+ 0x5601401a, 0x00005956,217217+ 0x14000011, 0x00000000,218218+ 0x00934050, 0x00000018,219219+ 0x00930050, 0x00000018,220220+ 0x3601403a, 0x0000002d,221221+ 0x000643a9, 0x00000000,222222+ 0x0000c420, 0x00000140,223223+ 0x5601401a, 0x00005956,224224+ 0x14000011, 0x00000000,225225+ 0x00000010, 0x00000000,226226+ 0x00000010, 0x00000000,227227+ 0x000642a9, 0x00000000,228228+ 0x00024420, 0x00000183,229229+ 0x5601401a, 0x00005956,230230+ 0x82000015, 0x00002000,231231+ 0x15200011, 0x00000000,232232+ 0x82000015, 0x00000010,233233+ 0x15200011, 0x00000000,234234+ 0x82000015, 0x00000010,235235+ 0x15200011, 0x00000000,236236+}; /* 104 Tx instructions */237237+#define FIRMWARE_TX_SIZE 104238238+#if 0239239+static const u32 firmware_wol[] = {240240+ 0x010003dc, 0x00000000,241241+ 0x19000421, 0x00000087,242242+ 0x80000015, 0x00001a1a,243243+ 0x81000015, 0x00001a1a,244244+ 0x1a0040ab, 0x00000b06,245245+ 0x15200011, 0x00000000,246246+ 0x15204022, 0x0000aaaa,247247+ 0x15204022, 0x00000300,248248+ 0x15204022, 0x00000000,249249+ 0x1a0040ab, 0x00000b15,250250+ 0x15200011, 0x00000000,251251+ 0x83000015, 0x00000002,252252+ 0x04000021, 0x00000000,253253+ 0x00000010, 0x00000000,254254+ 0x04000421, 0x00000087,255255+ 0x00000010, 0x00000000,256256+ 0x00000010, 0x00000000,257257+ 0x00008015, 0x00000000,258258+ 0x0000003e, 0x00000000,259259+ 0x00000010, 0x00000000,260260+ 0x00000010, 0x00000000,261261+ 0x82000015, 0x00004000,262262+ 0x82000015, 0x00008000,263263+ 0x0000000c, 0x00000000,264264+ 0x00000010, 0x00000000,265265+ 0x00004080, 0x00000100,266266+ 0x1f20c011, 0x00001122,267267+ 0x2720f011, 0x00003011,268268+ 0x19200071, 0x00000000,269269+ 0x1a200051, 0x00000000,270270+ 0x00000010, 0x00000000,271271+ 0x00000010, 0x00000000,272272+ 0x1d2040a4, 0x00003344,273273+ 0x1d2040a2, 0x00005566,274274+ 0x000040a0, 0x00000100,275275+ 0x00108050, 0x00000001,276276+ 0x1a208012, 0x00000006,277277+ 0x82000015, 0x00008080,278278+ 0x010003dc, 0x00000000,279279+ 0x1d2040a4, 0x00002233,280280+ 0x1d2040a4, 0x00004455,281281+ 0x2d208011, 0x00000005,282282+ 0x1d2040a4, 0x00006611,283283+ 0x00108050, 0x00000001,284284+ 0x27200011, 0x00000000,285285+ 0x1d2050a4, 0x00006600,286286+ 0x82000015, 0x00008080,287287+ 0x010003dc, 0x00000000,288288+ 0x00000050, 0x00000000,289289+ 0x1b200031, 0x00000000,290290+ 0x0000001e, 0x00000000,291291+ 0x0000001e, 0x00000000,292292+ 0x0000001e, 0x00000000,293293+ 0x0000001e, 0x00000000,294294+ 0x00924460, 0x00000086,295295+ 0x00004080, 0x00000000,296296+ 0x0092c070, 0x00000000,297297+ 0x00924060, 0x00000100,298298+ 0x0000c890, 0x00005000,299299+ 0x00a6c110, 0x00000000,300300+ 0x00b0c090, 0x00000012,301301+ 0x021c0015, 0x00000000,302302+ 0x3200001f, 0x00000034,303303+ 0x00924460, 0x00000510,304304+ 0x44210011, 0x00000000,305305+ 0x42000011, 0x00000000,306306+ 0x83000015, 0x00000040,307307+ 0x00924460, 0x00000508,308308+ 0x476a0012, 0x00000100,309309+ 0x83000015, 0x00000008,310310+ 0x16200011, 0x00000000,311311+ 0x001e8050, 0x00000000,312312+ 0x001e8050, 0x00000000,313313+ 0x00808050, 0x00000000,314314+ 0x03008015, 0x00000000,315315+ 0x62208012, 0x00000000,316316+ 0x82000015, 0x00000800,317317+ 0x16200011, 0x00000000,318318+ 0x80000015, 0x0000eea4,319319+ 0x81000015, 0x0000005f,320320+ 0x00000020, 0x00000000,321321+ 0x00004120, 0x00000000,322322+ 0x00004a00, 0x00004000,323323+ 0x00924460, 0x00000190,324324+ 0x5c01401a, 0x0000595c,325325+ 0x15000011, 0x00000000,326326+ 0x00934050, 0x00000018,327327+ 0x00930050, 0x00000018,328328+ 0x3601403a, 0x0000002d,329329+ 0x00064029, 0x00000000,330330+ 0x0000c420, 0x00000140,331331+ 0x5c01401a, 0x0000595c,332332+ 0x15000011, 0x00000000,333333+ 0x00000010, 0x00000000,334334+ 0x00000010, 0x00000000,335335+ 0x00064029, 0x00000000,336336+ 0x00024420, 0x00000183,337337+ 0x5c01401a, 0x0000595c,338338+ 0x82000015, 0x00002000,339339+ 0x16200011, 0x00000000,340340+ 0x82000015, 0x00000010,341341+ 0x16200011, 0x00000000,342342+ 0x82000015, 0x00000010,343343+ 0x16200011, 0x00000000,344344+}; /* 104 WoL instructions */345345+#define FIRMWARE_WOL_SIZE 104346346+#endif