patch-2.1.25 linux/drivers/net/net_init.c
Next file: linux/drivers/net/ni52.c
Previous file: linux/drivers/net/myri_sbus.h
Back to the patch index
Back to the overall index
- Lines: 59
- Date:
Sun Feb 2 15:18:40 1997
- Orig file:
v2.1.24/linux/drivers/net/net_init.c
- Orig date:
Thu Jan 23 21:06:47 1997
diff -u --recursive --new-file v2.1.24/linux/drivers/net/net_init.c linux/drivers/net/net_init.c
@@ -39,6 +39,7 @@
#include <linux/if_arp.h>
#include <linux/fddidevice.h>
#include <linux/net_alias.h>
+#include <linux/if_ltalk.h>
/* The network devices currently exist only in the socket namespace, so these
entries are unused. The only ones that make sense are
@@ -243,6 +244,50 @@
dev->pa_mask = 0;
dev->pa_alen = 4;
return;
+}
+
+#endif
+
+#ifdef CONFIG_ATALK
+
+static int ltalk_change_mtu(struct device *dev, int mtu)
+{
+ return -EINVAL;
+}
+
+static int ltalk_mac_addr(struct device *dev, void *addr)
+{
+ return -EINVAL;
+}
+
+
+void ltalk_setup(struct device *dev)
+{
+ /* Fill in the fields of the device structure with localtalk-generic values. */
+
+ dev_init_buffers(dev);
+
+ dev->change_mtu = ltalk_change_mtu;
+ dev->hard_header = NULL;
+ dev->rebuild_header = NULL;
+ dev->set_mac_address = ltalk_mac_addr;
+ dev->hard_header_cache = NULL;
+ dev->header_cache_update= NULL;
+
+ dev->type = ARPHRD_LOCALTLK;
+ dev->hard_header_len = LTALK_HLEN;
+ dev->mtu = LTALK_MTU;
+ dev->addr_len = LTALK_ALEN;
+ dev->tx_queue_len = 10;
+
+ dev->broadcast[0] = 0xFF;
+
+ dev->flags = IFF_BROADCAST|IFF_MULTICAST|IFF_NOARP;
+ dev->family = AF_APPLETALK;
+ dev->pa_addr = 0;
+ dev->pa_brdaddr = 0;
+ dev->pa_mask = 0;
+ dev->pa_alen = 1;
}
#endif
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov