lkml.org 
[lkml]   [2018]   [Jun]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH net v2] ipv6: omit traffic class when calculating flow hash
From
Date
On 6/2/18 1:40 AM, Michal Kubecek wrote:
> diff --git a/include/net/ipv6.h b/include/net/ipv6.h
> index 836f31af1369..7fbdc3e9e25d 100644
> --- a/include/net/ipv6.h
> +++ b/include/net/ipv6.h
> @@ -906,6 +906,11 @@ static inline __be32 ip6_make_flowinfo(unsigned int tclass, __be32 flowlabel)
> return htonl(tclass << IPV6_TCLASS_SHIFT) | flowlabel;
> }
>
> +static inline u32 flowi6_get_flowlabel(const struct flowi6 *fl6)
> +{
> + return (__force u32)(fl6->flowlabel & IPV6_FLOWLABEL_MASK);
> +}
> +
> /*
> * Prototypes exported by ipv6
> */

discussing the fix for net-next and making the label vs info consistent,
Michal notes a few places where this helper is needed as a __be32, so
the typecast should be outside of this helper.

\
 
 \ /
  Last update: 2018-06-03 17:00    [W:0.066 / U:1.816 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site