All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/5] Use dma_pool_zalloc
@ 2016-04-29 20:09 ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: linux-crypto
  Cc: kernel-janitors, linux-arm-kernel, Sören Brinkmann,
	linux-kernel, Dan Williams, dmaengine, linuxppc-dev

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
type T;
T *d;
expression e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(T));

@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

---

 drivers/crypto/marvell/tdma.c    |    5 ++---
 drivers/dma/fsldma.c             |    3 +--
 drivers/dma/ioat/init.c          |    5 ++---
 drivers/dma/mmp_pdma.c           |    3 +--
 drivers/dma/xilinx/xilinx_vdma.c |    3 +--
 5 files changed, 7 insertions(+), 12 deletions(-)

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

* [PATCH 0/5] Use dma_pool_zalloc
@ 2016-04-29 20:09 ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: linux-arm-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
type T;
T *d;
expression e;
statement S;
@@

        d -            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(T));

@@
expression d,e;
statement S;
@@

        d -            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

---

 drivers/crypto/marvell/tdma.c    |    5 ++---
 drivers/dma/fsldma.c             |    3 +--
 drivers/dma/ioat/init.c          |    5 ++---
 drivers/dma/mmp_pdma.c           |    3 +--
 drivers/dma/xilinx/xilinx_vdma.c |    3 +--
 5 files changed, 7 insertions(+), 12 deletions(-)

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

* [PATCH 0/5] Use dma_pool_zalloc
@ 2016-04-29 20:09 ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: linux-arm-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
type T;
T *d;
expression e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(T));

@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

---

 drivers/crypto/marvell/tdma.c    |    5 ++---
 drivers/dma/fsldma.c             |    3 +--
 drivers/dma/ioat/init.c          |    5 ++---
 drivers/dma/mmp_pdma.c           |    3 +--
 drivers/dma/xilinx/xilinx_vdma.c |    3 +--
 5 files changed, 7 insertions(+), 12 deletions(-)

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

* [PATCH 1/5] dmaengine: mmp_pdma: Use dma_pool_zalloc
  2016-04-29 20:09 ` Julia Lawall
@ 2016-04-29 20:09   ` Julia Lawall
  -1 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Dan Williams; +Cc: kernel-janitors, Vinod Koul, dmaengine, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/dma/mmp_pdma.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/dma/mmp_pdma.c b/drivers/dma/mmp_pdma.c
index e39457f..56f1fd6 100644
--- a/drivers/dma/mmp_pdma.c
+++ b/drivers/dma/mmp_pdma.c
@@ -364,13 +364,12 @@ mmp_pdma_alloc_descriptor(struct mmp_pdma_chan *chan)
 	struct mmp_pdma_desc_sw *desc;
 	dma_addr_t pdesc;
 
-	desc = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
+	desc = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
 	if (!desc) {
 		dev_err(chan->dev, "out of memory for link descriptor\n");
 		return NULL;
 	}
 
-	memset(desc, 0, sizeof(*desc));
 	INIT_LIST_HEAD(&desc->tx_list);
 	dma_async_tx_descriptor_init(&desc->async_tx, &chan->chan);
 	/* each desc has submit */

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

* [PATCH 1/5] dmaengine: mmp_pdma: Use dma_pool_zalloc
@ 2016-04-29 20:09   ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Dan Williams; +Cc: kernel-janitors, Vinod Koul, dmaengine, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d -            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/dma/mmp_pdma.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/dma/mmp_pdma.c b/drivers/dma/mmp_pdma.c
index e39457f..56f1fd6 100644
--- a/drivers/dma/mmp_pdma.c
+++ b/drivers/dma/mmp_pdma.c
@@ -364,13 +364,12 @@ mmp_pdma_alloc_descriptor(struct mmp_pdma_chan *chan)
 	struct mmp_pdma_desc_sw *desc;
 	dma_addr_t pdesc;
 
-	desc = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
+	desc = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
 	if (!desc) {
 		dev_err(chan->dev, "out of memory for link descriptor\n");
 		return NULL;
 	}
 
-	memset(desc, 0, sizeof(*desc));
 	INIT_LIST_HEAD(&desc->tx_list);
 	dma_async_tx_descriptor_init(&desc->async_tx, &chan->chan);
 	/* each desc has submit */


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

* [PATCH 2/5] dmaengine: vdma: Use dma_pool_zalloc
  2016-04-29 20:09 ` Julia Lawall
  (?)
@ 2016-04-29 20:09   ` Julia Lawall
  -1 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Dan Williams
  Cc: kernel-janitors, Vinod Koul, Michal Simek, Sören Brinkmann,
	dmaengine, linux-arm-kernel, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/dma/xilinx/xilinx_vdma.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/dma/xilinx/xilinx_vdma.c b/drivers/dma/xilinx/xilinx_vdma.c
index a95d603..6a70987 100644
--- a/drivers/dma/xilinx/xilinx_vdma.c
+++ b/drivers/dma/xilinx/xilinx_vdma.c
@@ -343,11 +343,10 @@ xilinx_vdma_alloc_tx_segment(struct xilinx_vdma_chan *chan)
 	struct xilinx_vdma_tx_segment *segment;
 	dma_addr_t phys;
 
-	segment = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &phys);
+	segment = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &phys);
 	if (!segment)
 		return NULL;
 
-	memset(segment, 0, sizeof(*segment));
 	segment->phys = phys;
 
 	return segment;

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

* [PATCH 2/5] dmaengine: vdma: Use dma_pool_zalloc
@ 2016-04-29 20:09   ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: linux-arm-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d -            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/dma/xilinx/xilinx_vdma.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/dma/xilinx/xilinx_vdma.c b/drivers/dma/xilinx/xilinx_vdma.c
index a95d603..6a70987 100644
--- a/drivers/dma/xilinx/xilinx_vdma.c
+++ b/drivers/dma/xilinx/xilinx_vdma.c
@@ -343,11 +343,10 @@ xilinx_vdma_alloc_tx_segment(struct xilinx_vdma_chan *chan)
 	struct xilinx_vdma_tx_segment *segment;
 	dma_addr_t phys;
 
-	segment = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &phys);
+	segment = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &phys);
 	if (!segment)
 		return NULL;
 
-	memset(segment, 0, sizeof(*segment));
 	segment->phys = phys;
 
 	return segment;


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

* [PATCH 2/5] dmaengine: vdma: Use dma_pool_zalloc
@ 2016-04-29 20:09   ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: linux-arm-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/dma/xilinx/xilinx_vdma.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/dma/xilinx/xilinx_vdma.c b/drivers/dma/xilinx/xilinx_vdma.c
index a95d603..6a70987 100644
--- a/drivers/dma/xilinx/xilinx_vdma.c
+++ b/drivers/dma/xilinx/xilinx_vdma.c
@@ -343,11 +343,10 @@ xilinx_vdma_alloc_tx_segment(struct xilinx_vdma_chan *chan)
 	struct xilinx_vdma_tx_segment *segment;
 	dma_addr_t phys;
 
-	segment = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &phys);
+	segment = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &phys);
 	if (!segment)
 		return NULL;
 
-	memset(segment, 0, sizeof(*segment));
 	segment->phys = phys;
 
 	return segment;

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

* [PATCH 3/5] dmaengine: ioatdma: Use dma_pool_zalloc
  2016-04-29 20:09 ` Julia Lawall
@ 2016-04-29 20:09   ` Julia Lawall
  -1 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Vinod Koul; +Cc: kernel-janitors, Dan Williams, dmaengine, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---

 drivers/dma/ioat/init.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/dma/ioat/init.c b/drivers/dma/ioat/init.c
index efdee1a..d4c63d4 100644
--- a/drivers/dma/ioat/init.c
+++ b/drivers/dma/ioat/init.c
@@ -690,12 +690,11 @@ static int ioat_alloc_chan_resources(struct dma_chan *c)
 	/* allocate a completion writeback area */
 	/* doing 2 32bit writes to mmio since 1 64b write doesn't work */
 	ioat_chan->completion =
-		dma_pool_alloc(ioat_chan->ioat_dma->completion_pool,
-			       GFP_KERNEL, &ioat_chan->completion_dma);
+		dma_pool_zalloc(ioat_chan->ioat_dma->completion_pool,
+				GFP_KERNEL, &ioat_chan->completion_dma);
 	if (!ioat_chan->completion)
 		return -ENOMEM;
 
-	memset(ioat_chan->completion, 0, sizeof(*ioat_chan->completion));
 	writel(((u64)ioat_chan->completion_dma) & 0x00000000FFFFFFFF,
 	       ioat_chan->reg_base + IOAT_CHANCMP_OFFSET_LOW);
 	writel(((u64)ioat_chan->completion_dma) >> 32,

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

* [PATCH 3/5] dmaengine: ioatdma: Use dma_pool_zalloc
@ 2016-04-29 20:09   ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Vinod Koul; +Cc: kernel-janitors, Dan Williams, dmaengine, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d -            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---

 drivers/dma/ioat/init.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/dma/ioat/init.c b/drivers/dma/ioat/init.c
index efdee1a..d4c63d4 100644
--- a/drivers/dma/ioat/init.c
+++ b/drivers/dma/ioat/init.c
@@ -690,12 +690,11 @@ static int ioat_alloc_chan_resources(struct dma_chan *c)
 	/* allocate a completion writeback area */
 	/* doing 2 32bit writes to mmio since 1 64b write doesn't work */
 	ioat_chan->completion -		dma_pool_alloc(ioat_chan->ioat_dma->completion_pool,
-			       GFP_KERNEL, &ioat_chan->completion_dma);
+		dma_pool_zalloc(ioat_chan->ioat_dma->completion_pool,
+				GFP_KERNEL, &ioat_chan->completion_dma);
 	if (!ioat_chan->completion)
 		return -ENOMEM;
 
-	memset(ioat_chan->completion, 0, sizeof(*ioat_chan->completion));
 	writel(((u64)ioat_chan->completion_dma) & 0x00000000FFFFFFFF,
 	       ioat_chan->reg_base + IOAT_CHANCMP_OFFSET_LOW);
 	writel(((u64)ioat_chan->completion_dma) >> 32,

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

* [PATCH 4/5] crypto: Use dma_pool_zalloc
  2016-04-29 20:09 ` Julia Lawall
@ 2016-04-29 20:09   ` Julia Lawall
  -1 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Boris Brezillon
  Cc: kernel-janitors, Arnaud Ebalard, Herbert Xu, David S. Miller,
	linux-crypto, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---

 drivers/crypto/marvell/tdma.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/crypto/marvell/tdma.c b/drivers/crypto/marvell/tdma.c
index 7642798..0ad8f1e 100644
--- a/drivers/crypto/marvell/tdma.c
+++ b/drivers/crypto/marvell/tdma.c
@@ -99,12 +99,11 @@ mv_cesa_dma_add_desc(struct mv_cesa_tdma_chain *chain, gfp_t flags)
 	struct mv_cesa_tdma_desc *new_tdma = NULL;
 	dma_addr_t dma_handle;
 
-	new_tdma = dma_pool_alloc(cesa_dev->dma->tdma_desc_pool, flags,
-				  &dma_handle);
+	new_tdma = dma_pool_zalloc(cesa_dev->dma->tdma_desc_pool, flags,
+				   &dma_handle);
 	if (!new_tdma)
 		return ERR_PTR(-ENOMEM);
 
-	memset(new_tdma, 0, sizeof(*new_tdma));
 	new_tdma->cur_dma = dma_handle;
 	if (chain->last) {
 		chain->last->next_dma = cpu_to_le32(dma_handle);

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

* [PATCH 4/5] crypto: Use dma_pool_zalloc
@ 2016-04-29 20:09   ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Boris Brezillon
  Cc: kernel-janitors, Arnaud Ebalard, Herbert Xu, David S. Miller,
	linux-crypto, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d -            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---

 drivers/crypto/marvell/tdma.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/crypto/marvell/tdma.c b/drivers/crypto/marvell/tdma.c
index 7642798..0ad8f1e 100644
--- a/drivers/crypto/marvell/tdma.c
+++ b/drivers/crypto/marvell/tdma.c
@@ -99,12 +99,11 @@ mv_cesa_dma_add_desc(struct mv_cesa_tdma_chain *chain, gfp_t flags)
 	struct mv_cesa_tdma_desc *new_tdma = NULL;
 	dma_addr_t dma_handle;
 
-	new_tdma = dma_pool_alloc(cesa_dev->dma->tdma_desc_pool, flags,
-				  &dma_handle);
+	new_tdma = dma_pool_zalloc(cesa_dev->dma->tdma_desc_pool, flags,
+				   &dma_handle);
 	if (!new_tdma)
 		return ERR_PTR(-ENOMEM);
 
-	memset(new_tdma, 0, sizeof(*new_tdma));
 	new_tdma->cur_dma = dma_handle;
 	if (chain->last) {
 		chain->last->next_dma = cpu_to_le32(dma_handle);

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

* [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
  2016-04-29 20:09 ` Julia Lawall
@ 2016-04-29 20:09   ` Julia Lawall
  -1 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Li Yang
  Cc: kernel-janitors, Zhang Wei, Vinod Koul, Dan Williams,
	linuxppc-dev, dmaengine, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d =
-            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/dma/fsldma.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/dma/fsldma.c b/drivers/dma/fsldma.c
index aac85c3..a8828ed 100644
--- a/drivers/dma/fsldma.c
+++ b/drivers/dma/fsldma.c
@@ -462,13 +462,12 @@ static struct fsl_desc_sw *fsl_dma_alloc_descriptor(struct fsldma_chan *chan)
 	struct fsl_desc_sw *desc;
 	dma_addr_t pdesc;
 
-	desc = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
+	desc = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
 	if (!desc) {
 		chan_dbg(chan, "out of memory for link descriptor\n");
 		return NULL;
 	}
 
-	memset(desc, 0, sizeof(*desc));
 	INIT_LIST_HEAD(&desc->tx_list);
 	dma_async_tx_descriptor_init(&desc->async_tx, &chan->common);
 	desc->async_tx.tx_submit = fsl_dma_tx_submit;

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

* [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
@ 2016-04-29 20:09   ` Julia Lawall
  0 siblings, 0 replies; 27+ messages in thread
From: Julia Lawall @ 2016-04-29 20:09 UTC (permalink / raw)
  To: Li Yang
  Cc: kernel-janitors, Zhang Wei, Vinod Koul, Dan Williams,
	linuxppc-dev, dmaengine, linux-kernel

Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

// <smpl>
@@
expression d,e;
statement S;
@@

        d -            dma_pool_alloc
+            dma_pool_zalloc
             (...);
        if (!d) S
-       memset(d, 0, sizeof(*d));
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

---
 drivers/dma/fsldma.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/dma/fsldma.c b/drivers/dma/fsldma.c
index aac85c3..a8828ed 100644
--- a/drivers/dma/fsldma.c
+++ b/drivers/dma/fsldma.c
@@ -462,13 +462,12 @@ static struct fsl_desc_sw *fsl_dma_alloc_descriptor(struct fsldma_chan *chan)
 	struct fsl_desc_sw *desc;
 	dma_addr_t pdesc;
 
-	desc = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
+	desc = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
 	if (!desc) {
 		chan_dbg(chan, "out of memory for link descriptor\n");
 		return NULL;
 	}
 
-	memset(desc, 0, sizeof(*desc));
 	INIT_LIST_HEAD(&desc->tx_list);
 	dma_async_tx_descriptor_init(&desc->async_tx, &chan->common);
 	desc->async_tx.tx_submit = fsl_dma_tx_submit;


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

* Re: [PATCH 4/5] crypto: Use dma_pool_zalloc
  2016-04-29 20:09   ` Julia Lawall
@ 2016-04-29 20:37     ` Boris Brezillon
  -1 siblings, 0 replies; 27+ messages in thread
From: Boris Brezillon @ 2016-04-29 20:37 UTC (permalink / raw)
  To: Julia Lawall
  Cc: kernel-janitors, Arnaud Ebalard, Herbert Xu, David S. Miller,
	linux-crypto, linux-kernel

On Fri, 29 Apr 2016 22:09:11 +0200
Julia Lawall <Julia.Lawall@lip6.fr> wrote:

> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d =
> -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>

> 
> ---
> 
>  drivers/crypto/marvell/tdma.c |    5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/crypto/marvell/tdma.c b/drivers/crypto/marvell/tdma.c
> index 7642798..0ad8f1e 100644
> --- a/drivers/crypto/marvell/tdma.c
> +++ b/drivers/crypto/marvell/tdma.c
> @@ -99,12 +99,11 @@ mv_cesa_dma_add_desc(struct mv_cesa_tdma_chain *chain, gfp_t flags)
>  	struct mv_cesa_tdma_desc *new_tdma = NULL;
>  	dma_addr_t dma_handle;
>  
> -	new_tdma = dma_pool_alloc(cesa_dev->dma->tdma_desc_pool, flags,
> -				  &dma_handle);
> +	new_tdma = dma_pool_zalloc(cesa_dev->dma->tdma_desc_pool, flags,
> +				   &dma_handle);
>  	if (!new_tdma)
>  		return ERR_PTR(-ENOMEM);
>  
> -	memset(new_tdma, 0, sizeof(*new_tdma));
>  	new_tdma->cur_dma = dma_handle;
>  	if (chain->last) {
>  		chain->last->next_dma = cpu_to_le32(dma_handle);



-- 
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

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

* Re: [PATCH 4/5] crypto: Use dma_pool_zalloc
@ 2016-04-29 20:37     ` Boris Brezillon
  0 siblings, 0 replies; 27+ messages in thread
From: Boris Brezillon @ 2016-04-29 20:37 UTC (permalink / raw)
  To: Julia Lawall
  Cc: kernel-janitors, Arnaud Ebalard, Herbert Xu, David S. Miller,
	linux-crypto, linux-kernel

On Fri, 29 Apr 2016 22:09:11 +0200
Julia Lawall <Julia.Lawall@lip6.fr> wrote:

> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d > -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>

> 
> ---
> 
>  drivers/crypto/marvell/tdma.c |    5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/crypto/marvell/tdma.c b/drivers/crypto/marvell/tdma.c
> index 7642798..0ad8f1e 100644
> --- a/drivers/crypto/marvell/tdma.c
> +++ b/drivers/crypto/marvell/tdma.c
> @@ -99,12 +99,11 @@ mv_cesa_dma_add_desc(struct mv_cesa_tdma_chain *chain, gfp_t flags)
>  	struct mv_cesa_tdma_desc *new_tdma = NULL;
>  	dma_addr_t dma_handle;
>  
> -	new_tdma = dma_pool_alloc(cesa_dev->dma->tdma_desc_pool, flags,
> -				  &dma_handle);
> +	new_tdma = dma_pool_zalloc(cesa_dev->dma->tdma_desc_pool, flags,
> +				   &dma_handle);
>  	if (!new_tdma)
>  		return ERR_PTR(-ENOMEM);
>  
> -	memset(new_tdma, 0, sizeof(*new_tdma));
>  	new_tdma->cur_dma = dma_handle;
>  	if (chain->last) {
>  		chain->last->next_dma = cpu_to_le32(dma_handle);



-- 
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

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

* RE: [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
  2016-04-29 20:09   ` Julia Lawall
  (?)
@ 2016-04-29 20:48     ` Yang-Leo Li
  -1 siblings, 0 replies; 27+ messages in thread
From: Yang-Leo Li @ 2016-04-29 20:48 UTC (permalink / raw)
  To: Julia Lawall, Li Yang
  Cc: kernel-janitors, Zhang Wei, Vinod Koul, Dan Williams,
	linuxppc-dev, dmaengine, linux-kernel



> -----Original Message-----
> From: Julia Lawall [mailto:Julia.Lawall@lip6.fr]
> Sent: Friday, April 29, 2016 3:09 PM
> To: Li Yang <leoli@freescale.com>
> Cc: kernel-janitors@vger.kernel.org; Zhang Wei <zw@zh-kernel.org>; Vinod
> Koul <vinod.koul@intel.com>; Dan Williams <dan.j.williams@intel.com>;
> linuxppc-dev@lists.ozlabs.org; dmaengine@vger.kernel.org; linux-
> kernel@vger.kernel.org
> Subject: [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
> 
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d =
> -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Acked-by: Li Yang <leoyang.li@nxp.com>

> 
> ---
>  drivers/dma/fsldma.c |    3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/dma/fsldma.c b/drivers/dma/fsldma.c index
> aac85c3..a8828ed 100644
> --- a/drivers/dma/fsldma.c
> +++ b/drivers/dma/fsldma.c
> @@ -462,13 +462,12 @@ static struct fsl_desc_sw
> *fsl_dma_alloc_descriptor(struct fsldma_chan *chan)
>  	struct fsl_desc_sw *desc;
>  	dma_addr_t pdesc;
> 
> -	desc = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
> +	desc = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
>  	if (!desc) {
>  		chan_dbg(chan, "out of memory for link descriptor\n");
>  		return NULL;
>  	}
> 
> -	memset(desc, 0, sizeof(*desc));
>  	INIT_LIST_HEAD(&desc->tx_list);
>  	dma_async_tx_descriptor_init(&desc->async_tx, &chan->common);
>  	desc->async_tx.tx_submit = fsl_dma_tx_submit;

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

* RE: [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
@ 2016-04-29 20:48     ` Yang-Leo Li
  0 siblings, 0 replies; 27+ messages in thread
From: Yang-Leo Li @ 2016-04-29 20:48 UTC (permalink / raw)
  To: Julia Lawall, Li Yang
  Cc: kernel-janitors, Zhang Wei, Vinod Koul, Dan Williams,
	linuxppc-dev, dmaengine, linux-kernel



> -----Original Message-----
> From: Julia Lawall [mailto:Julia.Lawall@lip6.fr]
> Sent: Friday, April 29, 2016 3:09 PM
> To: Li Yang <leoli@freescale.com>
> Cc: kernel-janitors@vger.kernel.org; Zhang Wei <zw@zh-kernel.org>; Vinod
> Koul <vinod.koul@intel.com>; Dan Williams <dan.j.williams@intel.com>;
> linuxppc-dev@lists.ozlabs.org; dmaengine@vger.kernel.org; linux-
> kernel@vger.kernel.org
> Subject: [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
> 
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d > -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Acked-by: Li Yang <leoyang.li@nxp.com>

> 
> ---
>  drivers/dma/fsldma.c |    3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/dma/fsldma.c b/drivers/dma/fsldma.c index
> aac85c3..a8828ed 100644
> --- a/drivers/dma/fsldma.c
> +++ b/drivers/dma/fsldma.c
> @@ -462,13 +462,12 @@ static struct fsl_desc_sw
> *fsl_dma_alloc_descriptor(struct fsldma_chan *chan)
>  	struct fsl_desc_sw *desc;
>  	dma_addr_t pdesc;
> 
> -	desc = dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
> +	desc = dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
>  	if (!desc) {
>  		chan_dbg(chan, "out of memory for link descriptor\n");
>  		return NULL;
>  	}
> 
> -	memset(desc, 0, sizeof(*desc));
>  	INIT_LIST_HEAD(&desc->tx_list);
>  	dma_async_tx_descriptor_init(&desc->async_tx, &chan->common);
>  	desc->async_tx.tx_submit = fsl_dma_tx_submit;


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

* RE: [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
@ 2016-04-29 20:48     ` Yang-Leo Li
  0 siblings, 0 replies; 27+ messages in thread
From: Yang-Leo Li @ 2016-04-29 20:48 UTC (permalink / raw)
  To: Julia Lawall, Li Yang
  Cc: kernel-janitors, Zhang Wei, Vinod Koul, Dan Williams,
	linuxppc-dev, dmaengine, linux-kernel



> -----Original Message-----
> From: Julia Lawall [mailto:Julia.Lawall@lip6.fr]
> Sent: Friday, April 29, 2016 3:09 PM
> To: Li Yang <leoli@freescale.com>
> Cc: kernel-janitors@vger.kernel.org; Zhang Wei <zw@zh-kernel.org>; Vinod
> Koul <vinod.koul@intel.com>; Dan Williams <dan.j.williams@intel.com>;
> linuxppc-dev@lists.ozlabs.org; dmaengine@vger.kernel.org; linux-
> kernel@vger.kernel.org
> Subject: [PATCH 5/5] dmaengine: fsldma: Use dma_pool_zalloc
>=20
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/=
)
>=20
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
>=20
>         d =3D
> -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
>=20
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Acked-by: Li Yang <leoyang.li@nxp.com>

>=20
> ---
>  drivers/dma/fsldma.c |    3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
>=20
> diff --git a/drivers/dma/fsldma.c b/drivers/dma/fsldma.c index
> aac85c3..a8828ed 100644
> --- a/drivers/dma/fsldma.c
> +++ b/drivers/dma/fsldma.c
> @@ -462,13 +462,12 @@ static struct fsl_desc_sw
> *fsl_dma_alloc_descriptor(struct fsldma_chan *chan)
>  	struct fsl_desc_sw *desc;
>  	dma_addr_t pdesc;
>=20
> -	desc =3D dma_pool_alloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
> +	desc =3D dma_pool_zalloc(chan->desc_pool, GFP_ATOMIC, &pdesc);
>  	if (!desc) {
>  		chan_dbg(chan, "out of memory for link descriptor\n");
>  		return NULL;
>  	}
>=20
> -	memset(desc, 0, sizeof(*desc));
>  	INIT_LIST_HEAD(&desc->tx_list);
>  	dma_async_tx_descriptor_init(&desc->async_tx, &chan->common);
>  	desc->async_tx.tx_submit =3D fsl_dma_tx_submit;

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

* Re: [PATCH 2/5] dmaengine: vdma: Use dma_pool_zalloc
  2016-04-29 20:09   ` Julia Lawall
  (?)
@ 2016-04-29 21:13     ` Sören Brinkmann
  -1 siblings, 0 replies; 27+ messages in thread
From: Sören Brinkmann @ 2016-04-29 21:13 UTC (permalink / raw)
  To: Julia Lawall
  Cc: Dan Williams, kernel-janitors, Vinod Koul, Michal Simek,
	dmaengine, linux-arm-kernel, linux-kernel

On Fri, 2016-04-29 at 22:09:09 +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d =
> -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: Sören Brinkmann <soren.brinkmann@xilinx.com>

	Sören

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

* Re: [PATCH 2/5] dmaengine: vdma: Use dma_pool_zalloc
@ 2016-04-29 21:13     ` Sören Brinkmann
  0 siblings, 0 replies; 27+ messages in thread
From: Sören Brinkmann @ 2016-04-29 21:13 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, 2016-04-29 at 22:09:09 +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d > -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: Sören Brinkmann <soren.brinkmann@xilinx.com>

	Sören

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

* [PATCH 2/5] dmaengine: vdma: Use dma_pool_zalloc
@ 2016-04-29 21:13     ` Sören Brinkmann
  0 siblings, 0 replies; 27+ messages in thread
From: Sören Brinkmann @ 2016-04-29 21:13 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, 2016-04-29 at 22:09:09 +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d =
> -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: S?ren Brinkmann <soren.brinkmann@xilinx.com>

	S?ren

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

* Re: [PATCH 0/5] Use dma_pool_zalloc
  2016-04-29 20:09 ` Julia Lawall
  (?)
@ 2016-05-03  6:55   ` Vinod Koul
  -1 siblings, 0 replies; 27+ messages in thread
From: Vinod Koul @ 2016-05-03  6:50 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Apr 29, 2016 at 10:09:07PM +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

Applied all dmaengine patches

-- 
~Vinod

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

* Re: [PATCH 0/5] Use dma_pool_zalloc
@ 2016-05-03  6:55   ` Vinod Koul
  0 siblings, 0 replies; 27+ messages in thread
From: Vinod Koul @ 2016-05-03  6:55 UTC (permalink / raw)
  To: Julia Lawall
  Cc: linux-crypto, kernel-janitors, linux-arm-kernel,
	Sören Brinkmann, linux-kernel, Dan Williams, dmaengine,
	linuxppc-dev

On Fri, Apr 29, 2016 at 10:09:07PM +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

Applied all dmaengine patches

-- 
~Vinod

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

* [PATCH 0/5] Use dma_pool_zalloc
@ 2016-05-03  6:55   ` Vinod Koul
  0 siblings, 0 replies; 27+ messages in thread
From: Vinod Koul @ 2016-05-03  6:55 UTC (permalink / raw)
  To: linux-arm-kernel

On Fri, Apr 29, 2016 at 10:09:07PM +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)

Applied all dmaengine patches

-- 
~Vinod

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

* Re: [PATCH 4/5] crypto: Use dma_pool_zalloc
  2016-04-29 20:09   ` Julia Lawall
@ 2016-05-03  8:17     ` Herbert Xu
  -1 siblings, 0 replies; 27+ messages in thread
From: Herbert Xu @ 2016-05-03  8:17 UTC (permalink / raw)
  To: Julia Lawall
  Cc: Boris Brezillon, kernel-janitors, Arnaud Ebalard,
	David S. Miller, linux-crypto, linux-kernel

On Fri, Apr 29, 2016 at 10:09:11PM +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d =
> -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Applied.
-- 
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] 27+ messages in thread

* Re: [PATCH 4/5] crypto: Use dma_pool_zalloc
@ 2016-05-03  8:17     ` Herbert Xu
  0 siblings, 0 replies; 27+ messages in thread
From: Herbert Xu @ 2016-05-03  8:17 UTC (permalink / raw)
  To: Julia Lawall
  Cc: Boris Brezillon, kernel-janitors, Arnaud Ebalard,
	David S. Miller, linux-crypto, linux-kernel

On Fri, Apr 29, 2016 at 10:09:11PM +0200, Julia Lawall wrote:
> Dma_pool_zalloc combines dma_pool_alloc and memset 0.  The semantic patch
> that makes this transformation is as follows: (http://coccinelle.lip6.fr/)
> 
> // <smpl>
> @@
> expression d,e;
> statement S;
> @@
> 
>         d > -            dma_pool_alloc
> +            dma_pool_zalloc
>              (...);
>         if (!d) S
> -       memset(d, 0, sizeof(*d));
> // </smpl>
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>

Applied.
-- 
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] 27+ messages in thread

end of thread, other threads:[~2016-05-03  8:17 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-29 20:09 [PATCH 0/5] Use dma_pool_zalloc Julia Lawall
2016-04-29 20:09 ` Julia Lawall
2016-04-29 20:09 ` Julia Lawall
2016-04-29 20:09 ` [PATCH 1/5] dmaengine: mmp_pdma: " Julia Lawall
2016-04-29 20:09   ` Julia Lawall
2016-04-29 20:09 ` [PATCH 2/5] dmaengine: vdma: " Julia Lawall
2016-04-29 20:09   ` Julia Lawall
2016-04-29 20:09   ` Julia Lawall
2016-04-29 21:13   ` Sören Brinkmann
2016-04-29 21:13     ` Sören Brinkmann
2016-04-29 21:13     ` Sören Brinkmann
2016-04-29 20:09 ` [PATCH 3/5] dmaengine: ioatdma: " Julia Lawall
2016-04-29 20:09   ` Julia Lawall
2016-04-29 20:09 ` [PATCH 4/5] crypto: " Julia Lawall
2016-04-29 20:09   ` Julia Lawall
2016-04-29 20:37   ` Boris Brezillon
2016-04-29 20:37     ` Boris Brezillon
2016-05-03  8:17   ` Herbert Xu
2016-05-03  8:17     ` Herbert Xu
2016-04-29 20:09 ` [PATCH 5/5] dmaengine: fsldma: " Julia Lawall
2016-04-29 20:09   ` Julia Lawall
2016-04-29 20:48   ` Yang-Leo Li
2016-04-29 20:48     ` Yang-Leo Li
2016-04-29 20:48     ` Yang-Leo Li
2016-05-03  6:50 ` [PATCH 0/5] " Vinod Koul
2016-05-03  6:55   ` Vinod Koul
2016-05-03  6:55   ` Vinod Koul

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.