[Bluetooth] Attach host adapters to the Bluetooth bus
[powerpc.git] / net / ethernet / eth.c
index 4bd78c8..0ac2524 100644 (file)
  *             Mark Evans, <evansmp@uhura.aston.ac.uk>
  *             Florian  La Roche, <rzsfl@rz.uni-sb.de>
  *             Alan Cox, <gw4pts@gw4pts.ampr.org>
- * 
+ *
  * Fixes:
  *             Mr Linux        : Arp problems
  *             Alan Cox        : Generic queue tidyup (very tiny here)
  *             Alan Cox        : eth_header ntohs should be htons
  *             Alan Cox        : eth_rebuild_header missing an htons and
  *                               minor other things.
- *             Tegge           : Arp bug fixes. 
+ *             Tegge           : Arp bug fixes.
  *             Florian         : Removed many unnecessary functions, code cleanup
  *                               and changes for new arp and skbuff.
  *             Alan Cox        : Redid header building to reflect new format.
@@ -40,7 +40,6 @@
 #include <linux/module.h>
 #include <linux/types.h>
 #include <linux/kernel.h>
-#include <linux/sched.h>
 #include <linux/string.h>
 #include <linux/mm.h>
 #include <linux/socket.h>
@@ -60,7 +59,6 @@
 #include <net/ip.h>
 #include <asm/uaccess.h>
 #include <asm/system.h>
-#include <asm/checksum.h>
 
 __setup("ether=", netdev_boot_setup);
 
@@ -158,7 +156,8 @@ __be16 eth_type_trans(struct sk_buff *skb, struct net_device *dev)
        struct ethhdr *eth;
        unsigned char *rawp;
 
-       skb->mac.raw = skb->data;
+       skb->dev = dev;
+       skb_reset_mac_header(skb);
        skb_pull(skb, ETH_HLEN);
        eth = eth_hdr(skb);
 
@@ -230,7 +229,7 @@ int eth_header_cache(struct neighbour *neigh, struct hh_cache *hh)
        eth = (struct ethhdr *)
            (((u8 *) hh->hh_data) + (HH_DATA_OFF(sizeof(*eth))));
 
-       if (type == __constant_htons(ETH_P_802_3))
+       if (type == htons(ETH_P_802_3))
                return -1;
 
        eth->h_proto = type;
@@ -308,9 +307,9 @@ void ether_setup(struct net_device *dev)
        dev->hard_header_len    = ETH_HLEN;
        dev->mtu                = ETH_DATA_LEN;
        dev->addr_len           = ETH_ALEN;
-       dev->tx_queue_len       = 1000; /* Ethernet wants good queues */        
+       dev->tx_queue_len       = 1000; /* Ethernet wants good queues */
        dev->flags              = IFF_BROADCAST|IFF_MULTICAST;
-       
+
        memset(dev->broadcast, 0xFF, ETH_ALEN);
 
 }