From: Christophe JAILLET Date: Thu, 19 Sep 2019 20:04:28 +0000 (+0200) Subject: crypto: chtls - simplify a bit 'create_flowc_wr_skb()' X-Git-Tag: v5.5-rc1~175^2~230 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3dc8b01ebcdd3a43d6c766618b92c2becbcf96b8;p=thirdparty%2Fkernel%2Flinux.git crypto: chtls - simplify a bit 'create_flowc_wr_skb()' Use '__skb_put_data()' instead of rewritting it. This improves readability. Signed-off-by: Christophe JAILLET Signed-off-by: Herbert Xu --- diff --git a/drivers/crypto/chelsio/chtls/chtls_io.c b/drivers/crypto/chelsio/chtls/chtls_io.c index 0891ab829b1b6..2512bfb24d712 100644 --- a/drivers/crypto/chelsio/chtls/chtls_io.c +++ b/drivers/crypto/chelsio/chtls/chtls_io.c @@ -97,7 +97,7 @@ static struct sk_buff *create_flowc_wr_skb(struct sock *sk, if (!skb) return NULL; - memcpy(__skb_put(skb, flowclen), flowc, flowclen); + __skb_put_data(skb, flowc, flowclen); skb_set_queue_mapping(skb, (csk->txq_idx << 1) | CPL_PRIORITY_DATA); return skb;