netfilter: nft_tunnel: no need to call htons() when dumping ports
authorXin Long <lucien.xin@gmail.com>
Fri, 13 Dec 2019 08:53:05 +0000 (16:53 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Mar 2020 15:43:50 +0000 (16:43 +0100)
commitbeffc17b843c57a6fbf697d458d28d02b2cba095
treec3483471d6af36420626f6c9ea6c1941f919a6fe
parent860a70e2a6f68e31b4bb3c4e34f198119d39f1f5
netfilter: nft_tunnel: no need to call htons() when dumping ports

commit cf3e204a1ca5442190018a317d9ec181b4639bd6 upstream.

info->key.tp_src and tp_dst are __be16, when using nla_put_be16()
to dump them, htons() is not needed, so remove it in this patch.

Fixes: af308b94a2a4 ("netfilter: nf_tables: add tunnel support")
Signed-off-by: Xin Long <lucien.xin@gmail.com>
Reviewed-by: Simon Horman <simon.horman@netronome.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/netfilter/nft_tunnel.c