[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201023185241.03830682@kicinski-fedora-PC1C0HJN.hsd1.ca.comcast.net>
Date: Fri, 23 Oct 2020 18:52:41 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Rohit Maheshwari <rohitm@...lsio.com>
Cc: netdev@...r.kernel.org, davem@...emloft.net, secdev@...lsio.com
Subject: Re: [net v2 1/7] cxgb4/ch_ktls: decrypted bit is not enough
On Fri, 23 Oct 2020 11:01:28 +0530 Rohit Maheshwari wrote:
> +#if IS_ENABLED(CONFIG_CHELSIO_TLS_DEVICE)
> + cxgb4_is_ktls_skb(skb) ||
> +#endif
> (proto != IPPROTO_TCP && proto != IPPROTO_UDP))
> txq = txq % pi->nqsets;
>
> diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.h b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.h
> index b169776ab484..65a8d4d4c6e5 100644
> --- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.h
> +++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.h
> @@ -493,6 +493,13 @@ struct cxgb4_uld_info {
> #endif
> };
>
> +#if IS_ENABLED(CONFIG_CHELSIO_TLS_DEVICE)
> +static inline bool cxgb4_is_ktls_skb(struct sk_buff *skb)
> +{
> + return skb->sk && tls_is_sk_tx_device_offloaded(skb->sk);
> +}
> +#endif
There is no need for those ifdefs.
Powered by blists - more mailing lists