All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] crypto: chtls - simplify a bit 'create_flowc_wr_skb()'
@ 2019-09-19 20:04 ` Christophe JAILLET
  0 siblings, 0 replies; 4+ messages in thread
From: Christophe JAILLET @ 2019-09-19 20:04 UTC (permalink / raw)
  To: atul.gupta, herbert, davem, akpm, willy, kirill.shutemov,
	kstewart, yuehaibing, tglx
  Cc: linux-crypto, linux-kernel, kernel-janitors, Christophe JAILLET

Use '__skb_put_data()' instead of rewritting it.
This improves readability.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
---
 drivers/crypto/chelsio/chtls/chtls_io.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/chelsio/chtls/chtls_io.c b/drivers/crypto/chelsio/chtls/chtls_io.c
index 0891ab829b1b..2512bfb24d71 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;
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] crypto: chtls - simplify a bit 'create_flowc_wr_skb()'
@ 2019-09-19 20:04 ` Christophe JAILLET
  0 siblings, 0 replies; 4+ messages in thread
From: Christophe JAILLET @ 2019-09-19 20:04 UTC (permalink / raw)
  To: atul.gupta, herbert, davem, akpm, willy, kirill.shutemov,
	kstewart, yuehaibing, tglx
  Cc: linux-crypto, linux-kernel, kernel-janitors, Christophe JAILLET

Use '__skb_put_data()' instead of rewritting it.
This improves readability.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
---
 drivers/crypto/chelsio/chtls/chtls_io.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/crypto/chelsio/chtls/chtls_io.c b/drivers/crypto/chelsio/chtls/chtls_io.c
index 0891ab829b1b..2512bfb24d71 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;
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] crypto: chtls - simplify a bit 'create_flowc_wr_skb()'
  2019-09-19 20:04 ` Christophe JAILLET
@ 2019-10-04 15:44   ` Herbert Xu
  -1 siblings, 0 replies; 4+ messages in thread
From: Herbert Xu @ 2019-10-04 15:44 UTC (permalink / raw)
  To: Christophe JAILLET
  Cc: atul.gupta, davem, akpm, willy, kirill.shutemov, kstewart,
	yuehaibing, tglx, linux-crypto, linux-kernel, kernel-janitors

On Thu, Sep 19, 2019 at 10:04:28PM +0200, Christophe JAILLET wrote:
> Use '__skb_put_data()' instead of rewritting it.
> This improves readability.
> 
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
>  drivers/crypto/chelsio/chtls/chtls_io.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Patch applied.  Thanks.
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] crypto: chtls - simplify a bit 'create_flowc_wr_skb()'
@ 2019-10-04 15:44   ` Herbert Xu
  0 siblings, 0 replies; 4+ messages in thread
From: Herbert Xu @ 2019-10-04 15:44 UTC (permalink / raw)
  To: Christophe JAILLET
  Cc: atul.gupta, davem, akpm, willy, kirill.shutemov, kstewart,
	yuehaibing, tglx, linux-crypto, linux-kernel, kernel-janitors

On Thu, Sep 19, 2019 at 10:04:28PM +0200, Christophe JAILLET wrote:
> Use '__skb_put_data()' instead of rewritting it.
> This improves readability.
> 
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
>  drivers/crypto/chelsio/chtls/chtls_io.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Patch applied.  Thanks.
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-10-04 15:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-19 20:04 [PATCH] crypto: chtls - simplify a bit 'create_flowc_wr_skb()' Christophe JAILLET
2019-09-19 20:04 ` Christophe JAILLET
2019-10-04 15:44 ` Herbert Xu
2019-10-04 15:44   ` Herbert Xu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.