tg3: tg3.h cleanups
[safe/jmp/linux-2.6] / drivers / net / sunlance.c
index 292feb2..2813732 100644 (file)
@@ -555,7 +555,6 @@ static void lance_rx_dvma(struct net_device *dev)
                                         len);
                        skb->protocol = eth_type_trans(skb, dev);
                        netif_rx(skb);
-                       dev->last_rx = jiffies;
                        dev->stats.rx_packets++;
                }
 
@@ -726,7 +725,6 @@ static void lance_rx_pio(struct net_device *dev)
                        lance_piocopy_to_skb(skb, &(ib->rx_buf[entry][0]), len);
                        skb->protocol = eth_type_trans(skb, dev);
                        netif_rx(skb);
-                       dev->last_rx = jiffies;
                        dev->stats.rx_packets++;
                }
 
@@ -1321,7 +1319,6 @@ static int __devinit sparc_lance_probe_one(struct of_device *op,
        static unsigned version_printed;
        struct lance_private *lp;
        struct net_device *dev;
-       DECLARE_MAC_BUF(mac);
        int    i;
 
        dev = alloc_etherdev(sizeof(struct lance_private) + 8);
@@ -1491,8 +1488,8 @@ no_link_test:
 
        dev_set_drvdata(&op->dev, lp);
 
-       printk(KERN_INFO "%s: LANCE %s\n",
-              dev->name, print_mac(mac, dev->dev_addr));
+       printk(KERN_INFO "%s: LANCE %pM\n",
+              dev->name, dev->dev_addr);
 
        return 0;
 
@@ -1502,43 +1499,6 @@ fail:
        return -ENODEV;
 }
 
-#ifdef CONFIG_SUN4
-
-#include <asm/sun4paddr.h>
-#include <asm/machines.h>
-
-/* Find all the lance cards on the system and initialize them */
-static struct sbus_dev sun4_sdev;
-static int __devinit sparc_lance_init(void)
-{
-       if ((idprom->id_machtype == (SM_SUN4|SM_4_330)) ||
-           (idprom->id_machtype == (SM_SUN4|SM_4_470))) {
-               memset(&sun4_sdev, 0, sizeof(struct sbus_dev));
-               sun4_sdev.reg_addrs[0].phys_addr = sun4_eth_physaddr;
-               sun4_sdev.irqs[0] = 6;
-               return sparc_lance_probe_one(&sun4_sdev, NULL, NULL);
-       }
-       return -ENODEV;
-}
-
-static int __exit sunlance_sun4_remove(void)
-{
-       struct lance_private *lp = dev_get_drvdata(&sun4_sdev.ofdev.dev);
-       struct net_device *net_dev = lp->dev;
-
-       unregister_netdev(net_dev);
-
-       lance_free_hwresources(lp);
-
-       free_netdev(net_dev);
-
-       dev_set_drvdata(&sun4_sdev.ofdev.dev, NULL);
-
-       return 0;
-}
-
-#else /* !CONFIG_SUN4 */
-
 static int __devinit sunlance_sbus_probe(struct of_device *op, const struct of_device_id *match)
 {
        struct of_device *parent = to_of_device(op->dev.parent);
@@ -1571,7 +1531,7 @@ static int __devexit sunlance_sbus_remove(struct of_device *op)
        return 0;
 }
 
-static struct of_device_id sunlance_sbus_match[] = {
+static const struct of_device_id sunlance_sbus_match[] = {
        {
                .name = "le",
        },
@@ -1593,15 +1553,10 @@ static int __init sparc_lance_init(void)
 {
        return of_register_driver(&sunlance_sbus_driver, &of_bus_type);
 }
-#endif /* !CONFIG_SUN4 */
 
 static void __exit sparc_lance_exit(void)
 {
-#ifdef CONFIG_SUN4
-       sunlance_sun4_remove();
-#else
        of_unregister_driver(&sunlance_sbus_driver);
-#endif
 }
 
 module_init(sparc_lance_init);