summaryrefslogtreecommitdiff
path: root/pfinet
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1995-10-19 21:25:49 +0000
committerMichael I. Bushnell <mib@gnu.org>1995-10-19 21:25:49 +0000
commitd8f9092a6974734431b23fa17b923491cb34e966 (patch)
tree067c2572c58cf04b4243796407b2954cca545825 /pfinet
parentd26812e8851d3e9b00a126b55615f2d8ed851d27 (diff)
Formerly ethernet.c.~10~
Diffstat (limited to 'pfinet')
-rw-r--r--pfinet/ethernet.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/pfinet/ethernet.c b/pfinet/ethernet.c
index 77fd5a0e..21b9a980 100644
--- a/pfinet/ethernet.c
+++ b/pfinet/ethernet.c
@@ -71,7 +71,7 @@ int
ethernet_open (struct device *dev)
{
if (ether_port != MACH_PORT_NULL)
- return 1;
+ return 0;
etherreadclass = ports_create_class (0, 0);
readpt = ports_allocate_port (pfinet_bucket, sizeof (struct port_info),
@@ -107,15 +107,6 @@ ethernet_demuxer (mach_msg_header_t *inp,
return 1;
}
- if (ntohs (pkthdr->type) != HDR_ETHERNET)
- return 1;
-
- /* The total size is the size of the ethernet header (which had
- better equal sizeof (struct ethhdr) and the data portion of the
- frame. So compute it. */
- if (msg->header_type.msgt_number != ETH_HLEN)
- return 1;
-
datalen = ETH_HLEN
+ msg->packet_type.msgt_number - sizeof (struct packet_header);