[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20140113.212540.653813046935024687.davem@davemloft.net>
Date: Mon, 13 Jan 2014 21:25:40 -0800 (PST)
From: David Miller <davem@...emloft.net>
To: roy.qing.li@...il.com
Cc: netdev@...r.kernel.org
Subject: Re: [PATCH net-next v2] ipv6: move IPV6_TCLASS_SHIFT into ipv6.h
From: roy.qing.li@...il.com
Date: Fri, 10 Jan 2014 18:03:18 +0800
> @@ -150,6 +150,8 @@ static int fib6_rule_match(struct fib_rule *rule, struct flowi *fl, int flags)
> {
> struct fib6_rule *r = (struct fib6_rule *) rule;
> struct flowi6 *fl6 = &fl->u.ip6;
> + u8 tclass = ntohl(fl6->flowlabel & IPV6_TCLASS_MASK) >>
> + IPV6_TCLASS_SHIFT;
As others have mentioned, please make a helper inline function or
macro for this calculation. It happens in two places.
Thanks.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists