X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fpackets.h;h=e5be1cb99c9cc959ccaf057ef8e7e4e77dd3211f;hb=51c14ddd8df9617e641748a98ac52b78fd19290a;hp=4a0fcae14ce2026689e35113bae9b197aa02f312;hpb=05be4e2c6af8ce22bd262820bc951c9408a6de3d;p=sliver-openvswitch.git diff --git a/lib/packets.h b/lib/packets.h index 4a0fcae14..e5be1cb99 100644 --- a/lib/packets.h +++ b/lib/packets.h @@ -135,9 +135,7 @@ static inline void eth_addr_nicira_random(uint8_t ea[ETH_ADDR_LEN]) bool eth_addr_is_reserved(const uint8_t ea[ETH_ADDR_LEN]); bool eth_addr_from_string(const char *, uint8_t ea[ETH_ADDR_LEN]); -void compose_benign_packet(struct ofpbuf *, const char *tag, - uint16_t snap_type, - const uint8_t eth_src[ETH_ADDR_LEN]); +void compose_rarp(struct ofpbuf *, const uint8_t eth_src[ETH_ADDR_LEN]); void eth_push_vlan(struct ofpbuf *, ovs_be16 tci); void eth_pop_vlan(struct ofpbuf *); @@ -182,6 +180,9 @@ void eth_addr_bitand(const uint8_t src[ETH_ADDR_LEN], #define ETH_TYPE_VLAN 0x8100 #define ETH_TYPE_IPV6 0x86dd #define ETH_TYPE_LACP 0x8809 +#define ETH_TYPE_RARP 0x8035 +#define ETH_TYPE_MPLS 0x8847 +#define ETH_TYPE_MPLS_MCAST 0x8848 /* Minimum value for an Ethernet type. Values below this are IEEE 802.2 frame * lengths. */ @@ -319,6 +320,10 @@ void ip_format_masked(ovs_be32 ip, ovs_be32 mask, struct ds *); #define IP_IHL(ip_ihl_ver) ((ip_ihl_ver) & 15) #define IP_IHL_VER(ihl, ver) (((ver) << 4) | (ihl)) +#ifndef IPPROTO_SCTP +#define IPPROTO_SCTP 132 +#endif + /* TOS fields. */ #define IP_ECN_MASK 0x03 #define IP_DSCP_MASK 0xfc @@ -403,6 +408,7 @@ BUILD_ASSERT_DECL(TCP_HEADER_LEN == sizeof(struct tcp_header)); #define ARP_PRO_IP 0x0800 #define ARP_OP_REQUEST 1 #define ARP_OP_REPLY 2 +#define ARP_OP_RARP 3 #define ARP_ETH_HEADER_LEN 28 struct arp_eth_header {