]> git.baikalelectronics.ru Git - kernel.git/commit
ila: ipv6/ila: fix nlsize calculation for lwtunnel
authorTom Herbert <tom@herbertland.com>
Tue, 10 May 2016 09:56:32 +0000 (11:56 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 10 May 2016 20:00:25 +0000 (16:00 -0400)
commit1e452a37dfd4a78ccb5d828aa94646b1026f901d
tree79d8331b4c26a3464ee36ab7297b35b247ebf9e2
parent58619a158ebbd18863bc6e17c3a0dd99b3b93b22
ila: ipv6/ila: fix nlsize calculation for lwtunnel

The handler 'ila_fill_encap_info' adds two attributes: ILA_ATTR_LOCATOR
and ILA_ATTR_CSUM_MODE.

nla_total_size_64bit() must be use for ILA_ATTR_LOCATOR.

Also, do nla_put_u8 instead of nla_put_u64 for ILA_ATTR_CSUM_MODE.

Fixes: cf701c833f5b ("ipv6: use nla_put_u64_64bit()")
Fixes: 2b0a79937979 ("ila: add checksum neutral ILA translations")
Reported-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: Tom Herbert <tom@herbertland.com>
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: Tom Herbert <tom@herbertland.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/ila/ila_lwt.c