diff options
| author | David S. Miller <davem@nuts.davemloft.net> | 2004-09-12 23:32:09 -0700 |
|---|---|---|
| committer | David S. Miller <davem@nuts.davemloft.net> | 2004-09-12 23:32:09 -0700 |
| commit | 925de4e47ed04f7de255541c65ab26ec595b918f (patch) | |
| tree | 50442345d1c3cb9e90ddf079e03687083ea33f6d /include | |
| parent | bac3431450c33664fd766c6d3f215b3e5ade1577 (diff) | |
| parent | 43a5fede44682b9777760fa567c32e226a5577ae (diff) | |
Merge bk://bk.skbuff.net:20609/linux-2.6-ndp-20040913/
into nuts.davemloft.net:/disk1/BK/net-2.6
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/ip6_tunnel.h | 2 | ||||
| -rw-r--r-- | include/net/inet_ecn.h | 7 |
2 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/ip6_tunnel.h b/include/linux/ip6_tunnel.h index 85805a797f91..5c23aeb104ca 100644 --- a/include/linux/ip6_tunnel.h +++ b/include/linux/ip6_tunnel.h @@ -16,6 +16,8 @@ #define IP6_TNL_F_USE_ORIG_FLOWLABEL 0x4 /* being used for Mobile IPv6 */ #define IP6_TNL_F_MIP6_DEV 0x8 +/* copy DSCP from the outer packet */ +#define IP6_TNL_F_RCV_DSCP_COPY 0x10 struct ip6_tnl_parm { char name[IFNAMSIZ]; /* name of tunnel device */ diff --git a/include/net/inet_ecn.h b/include/net/inet_ecn.h index 2aee47abb463..e04db26f4d84 100644 --- a/include/net/inet_ecn.h +++ b/include/net/inet_ecn.h @@ -2,6 +2,7 @@ #define _INET_ECN_H_ #include <linux/ip.h> +#include <net/dsfield.h> enum { INET_ECN_NOT_ECT = 0, @@ -93,4 +94,10 @@ static inline void IP6_ECN_clear(struct ipv6hdr *iph) *(u32*)iph &= ~htonl(INET_ECN_MASK << 20); } +static inline void ipv6_copy_dscp(struct ipv6hdr *outer, struct ipv6hdr *inner) +{ + u32 dscp = ipv6_get_dsfield(outer) & ~INET_ECN_MASK; + ipv6_change_dsfield(inner, INET_ECN_MASK, dscp); +} + #endif |
