diff options
author | Kuniyuki Iwashima <kuniyu@amazon.co.jp> | 2022-04-20 03:58:51 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-04-22 13:47:50 +0200 |
commit | 81ee0eb6c0fe34490ed92667538197d9295e899e (patch) | |
tree | ecd21aa4fc72c17f4fbf6074a2f6f036b66018c2 /drivers/net/ethernet/chelsio | |
parent | ipv6: Remove __ipv6_only_sock(). (diff) | |
download | linux-81ee0eb6c0fe34490ed92667538197d9295e899e.tar.xz linux-81ee0eb6c0fe34490ed92667538197d9295e899e.zip |
ipv6: Use ipv6_only_sock() helper in condition.
This patch replaces some sk_ipv6only tests with ipv6_only_sock().
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.co.jp>
Reviewed-by: David Ahern <dsahern@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/chelsio')
-rw-r--r-- | drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c b/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c index 59683f79959c..60b648b46f75 100644 --- a/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c +++ b/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c @@ -483,7 +483,7 @@ static int chcr_ktls_dev_add(struct net_device *netdev, struct sock *sk, tx_info->ip_family = AF_INET; #if IS_ENABLED(CONFIG_IPV6) } else { - if (!sk->sk_ipv6only && + if (!ipv6_only_sock(sk) && ipv6_addr_type(&sk->sk_v6_daddr) == IPV6_ADDR_MAPPED) { memcpy(daaddr, &sk->sk_daddr, 4); tx_info->ip_family = AF_INET; |