Commit bebc2f3f authored by Hideaki Yoshifuji's avatar Hideaki Yoshifuji

[IPV6]: ARCnet support, driver side.

parent 861c1242
...@@ -340,7 +340,7 @@ void arcdev_setup(struct net_device *dev) ...@@ -340,7 +340,7 @@ void arcdev_setup(struct net_device *dev)
dev->hard_header_len = sizeof(struct archdr); dev->hard_header_len = sizeof(struct archdr);
dev->mtu = choose_mtu(); dev->mtu = choose_mtu();
dev->addr_len = 1; dev->addr_len = ARCNET_ALEN;
dev->tx_queue_len = 30; dev->tx_queue_len = 30;
dev->broadcast[0] = 0x00; /* for us, broadcasts are address 0 */ dev->broadcast[0] = 0x00; /* for us, broadcasts are address 0 */
dev->watchdog_timeo = TX_TIMEOUT; dev->watchdog_timeo = TX_TIMEOUT;
......
...@@ -56,6 +56,7 @@ struct ArcProto rfc1201_proto = ...@@ -56,6 +56,7 @@ struct ArcProto rfc1201_proto =
void __init arcnet_rfc1201_init(void) void __init arcnet_rfc1201_init(void)
{ {
arc_proto_map[ARC_P_IP] arc_proto_map[ARC_P_IP]
= arc_proto_map[ARC_P_IPV6]
= arc_proto_map[ARC_P_ARP] = arc_proto_map[ARC_P_ARP]
= arc_proto_map[ARC_P_RARP] = arc_proto_map[ARC_P_RARP]
= arc_proto_map[ARC_P_IPX] = arc_proto_map[ARC_P_IPX]
...@@ -114,6 +115,8 @@ static unsigned short type_trans(struct sk_buff *skb, struct net_device *dev) ...@@ -114,6 +115,8 @@ static unsigned short type_trans(struct sk_buff *skb, struct net_device *dev)
switch (soft->proto) { switch (soft->proto) {
case ARC_P_IP: case ARC_P_IP:
return htons(ETH_P_IP); return htons(ETH_P_IP);
case ARC_P_IPV6:
return htons(ETH_P_IPV6);
case ARC_P_ARP: case ARC_P_ARP:
return htons(ETH_P_ARP); return htons(ETH_P_ARP);
case ARC_P_RARP: case ARC_P_RARP:
...@@ -389,6 +392,9 @@ static int build_header(struct sk_buff *skb, unsigned short type, ...@@ -389,6 +392,9 @@ static int build_header(struct sk_buff *skb, unsigned short type,
case ETH_P_IP: case ETH_P_IP:
soft->proto = ARC_P_IP; soft->proto = ARC_P_IP;
break; break;
case ETH_P_IPV6:
soft->proto = ARC_P_IPV6;
break;
case ETH_P_ARP: case ETH_P_ARP:
soft->proto = ARC_P_ARP; soft->proto = ARC_P_ARP;
break; break;
......
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
/* RFC1201 Protocol ID's */ /* RFC1201 Protocol ID's */
#define ARC_P_IP 212 /* 0xD4 */ #define ARC_P_IP 212 /* 0xD4 */
#define ARC_P_IPV6 196 /* 0xC4: RFC2497 */
#define ARC_P_ARP 213 /* 0xD5 */ #define ARC_P_ARP 213 /* 0xD5 */
#define ARC_P_RARP 214 /* 0xD6 */ #define ARC_P_RARP 214 /* 0xD6 */
#define ARC_P_IPX 250 /* 0xFA */ #define ARC_P_IPX 250 /* 0xFA */
...@@ -45,6 +46,9 @@ ...@@ -45,6 +46,9 @@
#define ARC_P_LANSOFT 251 /* 0xFB - what is this? */ #define ARC_P_LANSOFT 251 /* 0xFB - what is this? */
#define ARC_P_ATALK 0xDD #define ARC_P_ATALK 0xDD
/* Hardware address length */
#define ARCNET_ALEN 1
/* /*
* The RFC1201-specific components of an arcnet packet header. * The RFC1201-specific components of an arcnet packet header.
*/ */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment