diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2006-11-08 03:25:17 -0500 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2006-12-03 00:21:21 -0500 |
commit | 90bcaf7b4a33bb9b100cc06869f0c033a870d4a0 (patch) | |
tree | fb8307b99fd9779d17fdfb0c35d836a8438d424a /net/ipv6/ip6_output.c | |
parent | 92d9ece7af9c84bfbd1ff640926fac5b573a09f7 (diff) |
[IPV6]: flowlabels are net-endian
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/ip6_output.c')
-rw-r--r-- | net/ipv6/ip6_output.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c index 66716911962e..9ff1be1bc2e7 100644 --- a/net/ipv6/ip6_output.c +++ b/net/ipv6/ip6_output.c | |||
@@ -217,7 +217,7 @@ int ip6_xmit(struct sock *sk, struct sk_buff *skb, struct flowi *fl, | |||
217 | if (tclass < 0) | 217 | if (tclass < 0) |
218 | tclass = 0; | 218 | tclass = 0; |
219 | 219 | ||
220 | *(u32 *)hdr = htonl(0x60000000 | (tclass << 20)) | fl->fl6_flowlabel; | 220 | *(__be32 *)hdr = htonl(0x60000000 | (tclass << 20)) | fl->fl6_flowlabel; |
221 | 221 | ||
222 | hdr->payload_len = htons(seg_len); | 222 | hdr->payload_len = htons(seg_len); |
223 | hdr->nexthdr = proto; | 223 | hdr->nexthdr = proto; |
@@ -1311,7 +1311,7 @@ int ip6_push_pending_frames(struct sock *sk) | |||
1311 | 1311 | ||
1312 | skb->nh.ipv6h = hdr = (struct ipv6hdr*) skb_push(skb, sizeof(struct ipv6hdr)); | 1312 | skb->nh.ipv6h = hdr = (struct ipv6hdr*) skb_push(skb, sizeof(struct ipv6hdr)); |
1313 | 1313 | ||
1314 | *(u32*)hdr = fl->fl6_flowlabel | | 1314 | *(__be32*)hdr = fl->fl6_flowlabel | |
1315 | htonl(0x60000000 | ((int)np->cork.tclass << 20)); | 1315 | htonl(0x60000000 | ((int)np->cork.tclass << 20)); |
1316 | 1316 | ||
1317 | if (skb->len <= sizeof(struct ipv6hdr) + IPV6_MAXPLEN) | 1317 | if (skb->len <= sizeof(struct ipv6hdr) + IPV6_MAXPLEN) |