net: 6lo: Fix compress bit calculation

Compress bit calculation was wrong. It should be moved
to 4 bits left to cache it properly.

Change-Id: Ib011874881a69032795c2ecfd9a615b6cf559c69
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
This commit is contained in:
Ravi kumar Veeramally 2017-03-03 14:11:00 +02:00 committed by Jukka Rissanen
commit 2e3e93dccb

View file

@ -36,7 +36,7 @@ struct net_6lo_context {
static inline uint8_t get_6co_compress(struct net_icmpv6_nd_opt_6co *opt)
{
return opt->flag & 0x10;
return (opt->flag & 0x10) > 4;
}
static inline uint8_t get_6co_cid(struct net_icmpv6_nd_opt_6co *opt)