Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit be1459de authored by Al Viro's avatar Al Viro Committed by David S. Miller
Browse files

mellanox: fix the dport endianness in call of __inet6_lookup_established()



__inet6_lookup_established() expect th->dport passed in host-endian,
not net-endian.  The reason is microoptimization in __inet6_lookup(),
but if you use the lower-level helpers, you have to play by their
rules...

Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 98146703
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -328,7 +328,7 @@ static int tls_update_resync_sn(struct net_device *netdev,


		sk = __inet6_lookup_established(dev_net(netdev), &tcp_hashinfo,
		sk = __inet6_lookup_established(dev_net(netdev), &tcp_hashinfo,
						&ipv6h->saddr, th->source,
						&ipv6h->saddr, th->source,
						&ipv6h->daddr, th->dest,
						&ipv6h->daddr, ntohs(th->dest),
						netdev->ifindex, 0);
						netdev->ifindex, 0);
#endif
#endif
	}
	}