All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
@ 2015-01-02 12:56 Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 2/7] ASoC: au1x: " Lars-Peter Clausen
                   ` (6 more replies)
  0 siblings, 7 replies; 9+ messages in thread
From: Lars-Peter Clausen @ 2015-01-02 12:56 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: alsa-devel, Lars-Peter Clausen, Kuninori Morimoto, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski

The ALSA core takes care that all preallocated memory is freed when the PCM
itself is freed. There is no need to do this manually in the driver.
Similarly there is also no need to do it on the pcm_new() error path as the
PCM will be freed if a error is returned.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/soc-generic-dmaengine-pcm.c | 15 ++-------------
 1 file changed, 2 insertions(+), 13 deletions(-)

diff --git a/sound/soc/soc-generic-dmaengine-pcm.c b/sound/soc/soc-generic-dmaengine-pcm.c
index b329b84..4864392 100644
--- a/sound/soc/soc-generic-dmaengine-pcm.c
+++ b/sound/soc/soc-generic-dmaengine-pcm.c
@@ -200,11 +200,6 @@ static int dmaengine_pcm_open(struct snd_pcm_substream *substream)
 	return snd_dmaengine_pcm_open(substream, chan);
 }
 
-static void dmaengine_pcm_free(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static struct dma_chan *dmaengine_pcm_compat_request_channel(
 	struct snd_soc_pcm_runtime *rtd,
 	struct snd_pcm_substream *substream)
@@ -283,8 +278,7 @@ static int dmaengine_pcm_new(struct snd_soc_pcm_runtime *rtd)
 		if (!pcm->chan[i]) {
 			dev_err(rtd->platform->dev,
 				"Missing dma channel for stream: %d\n", i);
-			ret = -EINVAL;
-			goto err_free;
+			return -EINVAL;
 		}
 
 		ret = snd_pcm_lib_preallocate_pages(substream,
@@ -293,7 +287,7 @@ static int dmaengine_pcm_new(struct snd_soc_pcm_runtime *rtd)
 				prealloc_buffer_size,
 				max_buffer_size);
 		if (ret)
-			goto err_free;
+			return ret;
 
 		/*
 		 * This will only return false if we know for sure that at least
@@ -307,10 +301,6 @@ static int dmaengine_pcm_new(struct snd_soc_pcm_runtime *rtd)
 	}
 
 	return 0;
-
-err_free:
-	dmaengine_pcm_free(rtd->pcm);
-	return ret;
 }
 
 static snd_pcm_uframes_t dmaengine_pcm_pointer(
@@ -341,7 +331,6 @@ static const struct snd_soc_platform_driver dmaengine_pcm_platform = {
 	},
 	.ops		= &dmaengine_pcm_ops,
 	.pcm_new	= dmaengine_pcm_new,
-	.pcm_free	= dmaengine_pcm_free,
 };
 
 static const char * const dmaengine_pcm_dma_channel_names[] = {
-- 
1.8.0

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

* [PATCH 2/7] ASoC: au1x: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
@ 2015-01-02 12:56 ` Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 3/7] ASoC: intel: " Lars-Peter Clausen
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 9+ messages in thread
From: Lars-Peter Clausen @ 2015-01-02 12:56 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: alsa-devel, Lars-Peter Clausen, Kuninori Morimoto, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski

The ALSA core takes care that all preallocated memory is freed when the PCM
itself is freed. There is no need to do this manually in the driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/au1x/dbdma2.c | 6 ------
 sound/soc/au1x/dma.c    | 6 ------
 2 files changed, 12 deletions(-)

diff --git a/sound/soc/au1x/dbdma2.c b/sound/soc/au1x/dbdma2.c
index b06b8d8..dd94fea 100644
--- a/sound/soc/au1x/dbdma2.c
+++ b/sound/soc/au1x/dbdma2.c
@@ -315,11 +315,6 @@ static struct snd_pcm_ops au1xpsc_pcm_ops = {
 	.pointer	= au1xpsc_pcm_pointer,
 };
 
-static void au1xpsc_pcm_free_dma_buffers(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int au1xpsc_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_card *card = rtd->card->snd_card;
@@ -335,7 +330,6 @@ static int au1xpsc_pcm_new(struct snd_soc_pcm_runtime *rtd)
 static struct snd_soc_platform_driver au1xpsc_soc_platform = {
 	.ops		= &au1xpsc_pcm_ops,
 	.pcm_new	= au1xpsc_pcm_new,
-	.pcm_free	= au1xpsc_pcm_free_dma_buffers,
 };
 
 static int au1xpsc_pcm_drvprobe(struct platform_device *pdev)
diff --git a/sound/soc/au1x/dma.c b/sound/soc/au1x/dma.c
index 6ffaaff..24cc7f4 100644
--- a/sound/soc/au1x/dma.c
+++ b/sound/soc/au1x/dma.c
@@ -287,11 +287,6 @@ static struct snd_pcm_ops alchemy_pcm_ops = {
 	.pointer		= alchemy_pcm_pointer,
 };
 
-static void alchemy_pcm_free_dma_buffers(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int alchemy_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_pcm *pcm = rtd->pcm;
@@ -305,7 +300,6 @@ static int alchemy_pcm_new(struct snd_soc_pcm_runtime *rtd)
 static struct snd_soc_platform_driver alchemy_pcm_soc_platform = {
 	.ops		= &alchemy_pcm_ops,
 	.pcm_new	= alchemy_pcm_new,
-	.pcm_free	= alchemy_pcm_free_dma_buffers,
 };
 
 static int alchemy_pcm_drvprobe(struct platform_device *pdev)
-- 
1.8.0

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

* [PATCH 3/7] ASoC: intel: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 2/7] ASoC: au1x: " Lars-Peter Clausen
@ 2015-01-02 12:56 ` Lars-Peter Clausen
  2015-01-05  9:28   ` Jarkko Nikula
  2015-01-02 12:56 ` [PATCH 4/7] ASoC: nuc900: " Lars-Peter Clausen
                   ` (4 subsequent siblings)
  6 siblings, 1 reply; 9+ messages in thread
From: Lars-Peter Clausen @ 2015-01-02 12:56 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: alsa-devel, Lars-Peter Clausen, Kuninori Morimoto, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski

The ALSA core takes care that all preallocated memory is freed when the PCM
itself is freed. There is no need to do this manually in the driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/intel/sst-baytrail-pcm.c      | 6 ------
 sound/soc/intel/sst-haswell-pcm.c       | 6 ------
 sound/soc/intel/sst-mfld-platform-pcm.c | 7 -------
 3 files changed, 19 deletions(-)

diff --git a/sound/soc/intel/sst-baytrail-pcm.c b/sound/soc/intel/sst-baytrail-pcm.c
index 3bb6288..224c49c 100644
--- a/sound/soc/intel/sst-baytrail-pcm.c
+++ b/sound/soc/intel/sst-baytrail-pcm.c
@@ -320,11 +320,6 @@ static struct snd_pcm_ops sst_byt_pcm_ops = {
 	.mmap		= sst_byt_pcm_mmap,
 };
 
-static void sst_byt_pcm_free(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int sst_byt_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_pcm *pcm = rtd->pcm;
@@ -403,7 +398,6 @@ static struct snd_soc_platform_driver byt_soc_platform = {
 	.remove		= sst_byt_pcm_remove,
 	.ops		= &sst_byt_pcm_ops,
 	.pcm_new	= sst_byt_pcm_new,
-	.pcm_free	= sst_byt_pcm_free,
 };
 
 static const struct snd_soc_component_driver byt_dai_component = {
diff --git a/sound/soc/intel/sst-haswell-pcm.c b/sound/soc/intel/sst-haswell-pcm.c
index 6195252..13f156b 100644
--- a/sound/soc/intel/sst-haswell-pcm.c
+++ b/sound/soc/intel/sst-haswell-pcm.c
@@ -735,11 +735,6 @@ static void hsw_pcm_free_modules(struct hsw_priv_data *pdata)
 	}
 }
 
-static void hsw_pcm_free(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int hsw_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_pcm *pcm = rtd->pcm;
@@ -936,7 +931,6 @@ static struct snd_soc_platform_driver hsw_soc_platform = {
 	.remove		= hsw_pcm_remove,
 	.ops		= &hsw_pcm_ops,
 	.pcm_new	= hsw_pcm_new,
-	.pcm_free	= hsw_pcm_free,
 };
 
 static const struct snd_soc_component_driver hsw_dai_component = {
diff --git a/sound/soc/intel/sst-mfld-platform-pcm.c b/sound/soc/intel/sst-mfld-platform-pcm.c
index a1a8d9d..7523cbe 100644
--- a/sound/soc/intel/sst-mfld-platform-pcm.c
+++ b/sound/soc/intel/sst-mfld-platform-pcm.c
@@ -643,12 +643,6 @@ static struct snd_pcm_ops sst_platform_ops = {
 	.pointer = sst_platform_pcm_pointer,
 };
 
-static void sst_pcm_free(struct snd_pcm *pcm)
-{
-	dev_dbg(pcm->dev, "sst_pcm_free called\n");
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int sst_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_soc_dai *dai = rtd->cpu_dai;
@@ -679,7 +673,6 @@ static struct snd_soc_platform_driver sst_soc_platform_drv  = {
 	.ops		= &sst_platform_ops,
 	.compr_ops	= &sst_platform_compr_ops,
 	.pcm_new	= sst_pcm_new,
-	.pcm_free	= sst_pcm_free,
 };
 
 static const struct snd_soc_component_driver sst_component = {
-- 
1.8.0

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

* [PATCH 4/7] ASoC: nuc900: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 2/7] ASoC: au1x: " Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 3/7] ASoC: intel: " Lars-Peter Clausen
@ 2015-01-02 12:56 ` Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 5/7] ASoC: rcar: " Lars-Peter Clausen
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 9+ messages in thread
From: Lars-Peter Clausen @ 2015-01-02 12:56 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: alsa-devel, Lars-Peter Clausen, Kuninori Morimoto, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski

The ALSA core takes care that all preallocated memory is freed when the PCM
itself is freed. There is no need to do this manually in the driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/nuc900/nuc900-pcm.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/sound/soc/nuc900/nuc900-pcm.c b/sound/soc/nuc900/nuc900-pcm.c
index b779a3d..b809fa9 100644
--- a/sound/soc/nuc900/nuc900-pcm.c
+++ b/sound/soc/nuc900/nuc900-pcm.c
@@ -306,11 +306,6 @@ static struct snd_pcm_ops nuc900_dma_ops = {
 	.mmap		= nuc900_dma_mmap,
 };
 
-static void nuc900_dma_free_dma_buffers(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int nuc900_dma_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_card *card = rtd->card->snd_card;
@@ -330,7 +325,6 @@ static int nuc900_dma_new(struct snd_soc_pcm_runtime *rtd)
 static struct snd_soc_platform_driver nuc900_soc_platform = {
 	.ops		= &nuc900_dma_ops,
 	.pcm_new	= nuc900_dma_new,
-	.pcm_free	= nuc900_dma_free_dma_buffers,
 };
 
 static int nuc900_soc_platform_probe(struct platform_device *pdev)
-- 
1.8.0

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

* [PATCH 5/7] ASoC: rcar: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
                   ` (2 preceding siblings ...)
  2015-01-02 12:56 ` [PATCH 4/7] ASoC: nuc900: " Lars-Peter Clausen
@ 2015-01-02 12:56 ` Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 6/7] ASoC: sh: " Lars-Peter Clausen
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 9+ messages in thread
From: Lars-Peter Clausen @ 2015-01-02 12:56 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: alsa-devel, Lars-Peter Clausen, Kuninori Morimoto, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski

The ALSA core takes care that all preallocated memory is freed when the PCM
itself is freed. There is no need to do this manually in the driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/sh/rcar/core.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/sound/soc/sh/rcar/core.c b/sound/soc/sh/rcar/core.c
index 75308bb..d9c81cd 100644
--- a/sound/soc/sh/rcar/core.c
+++ b/sound/soc/sh/rcar/core.c
@@ -1140,15 +1140,9 @@ static int rsnd_pcm_new(struct snd_soc_pcm_runtime *rtd)
 		PREALLOC_BUFFER, PREALLOC_BUFFER_MAX);
 }
 
-static void rsnd_pcm_free(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static struct snd_soc_platform_driver rsnd_soc_platform = {
 	.ops		= &rsnd_pcm_ops,
 	.pcm_new	= rsnd_pcm_new,
-	.pcm_free	= rsnd_pcm_free,
 };
 
 static const struct snd_soc_component_driver rsnd_soc_component = {
-- 
1.8.0

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

* [PATCH 6/7] ASoC: sh: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
                   ` (3 preceding siblings ...)
  2015-01-02 12:56 ` [PATCH 5/7] ASoC: rcar: " Lars-Peter Clausen
@ 2015-01-02 12:56 ` Lars-Peter Clausen
  2015-01-02 12:56 ` [PATCH 7/7] ASoC: txx9: " Lars-Peter Clausen
  2015-01-05 21:30 ` [PATCH 1/7] ASoC: dmaengine: " Mark Brown
  6 siblings, 0 replies; 9+ messages in thread
From: Lars-Peter Clausen @ 2015-01-02 12:56 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: alsa-devel, Lars-Peter Clausen, Kuninori Morimoto, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski

The ALSA core takes care that all preallocated memory is freed when the PCM
itself is freed. There is no need to do this manually in the driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/sh/dma-sh7760.c | 6 ------
 sound/soc/sh/fsi.c        | 6 ------
 sound/soc/sh/siu_pcm.c    | 1 -
 3 files changed, 13 deletions(-)

diff --git a/sound/soc/sh/dma-sh7760.c b/sound/soc/sh/dma-sh7760.c
index a5b2c4e..fd11404 100644
--- a/sound/soc/sh/dma-sh7760.c
+++ b/sound/soc/sh/dma-sh7760.c
@@ -305,11 +305,6 @@ static struct snd_pcm_ops camelot_pcm_ops = {
 	.pointer	= camelot_pos,
 };
 
-static void camelot_pcm_free(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int camelot_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_pcm *pcm = rtd->pcm;
@@ -328,7 +323,6 @@ static int camelot_pcm_new(struct snd_soc_pcm_runtime *rtd)
 static struct snd_soc_platform_driver sh7760_soc_platform = {
 	.ops		= &camelot_pcm_ops,
 	.pcm_new	= camelot_pcm_new,
-	.pcm_free	= camelot_pcm_free,
 };
 
 static int sh7760_soc_platform_probe(struct platform_device *pdev)
diff --git a/sound/soc/sh/fsi.c b/sound/soc/sh/fsi.c
index 8869971..422faa9 100644
--- a/sound/soc/sh/fsi.c
+++ b/sound/soc/sh/fsi.c
@@ -1765,11 +1765,6 @@ static struct snd_pcm_ops fsi_pcm_ops = {
 #define PREALLOC_BUFFER		(32 * 1024)
 #define PREALLOC_BUFFER_MAX	(32 * 1024)
 
-static void fsi_pcm_free(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int fsi_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	return snd_pcm_lib_preallocate_pages_for_all(
@@ -1821,7 +1816,6 @@ static struct snd_soc_dai_driver fsi_soc_dai[] = {
 static struct snd_soc_platform_driver fsi_soc_platform = {
 	.ops		= &fsi_pcm_ops,
 	.pcm_new	= fsi_pcm_new,
-	.pcm_free	= fsi_pcm_free,
 };
 
 static const struct snd_soc_component_driver fsi_soc_component = {
diff --git a/sound/soc/sh/siu_pcm.c b/sound/soc/sh/siu_pcm.c
index 32eb6da..82902f5 100644
--- a/sound/soc/sh/siu_pcm.c
+++ b/sound/soc/sh/siu_pcm.c
@@ -589,7 +589,6 @@ static void siu_pcm_free(struct snd_pcm *pcm)
 	tasklet_kill(&port_info->playback.tasklet);
 
 	siu_free_port(port_info);
-	snd_pcm_lib_preallocate_free_for_all(pcm);
 
 	dev_dbg(pcm->card->dev, "%s\n", __func__);
 }
-- 
1.8.0

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

* [PATCH 7/7] ASoC: txx9: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
                   ` (4 preceding siblings ...)
  2015-01-02 12:56 ` [PATCH 6/7] ASoC: sh: " Lars-Peter Clausen
@ 2015-01-02 12:56 ` Lars-Peter Clausen
  2015-01-05 21:30 ` [PATCH 1/7] ASoC: dmaengine: " Mark Brown
  6 siblings, 0 replies; 9+ messages in thread
From: Lars-Peter Clausen @ 2015-01-02 12:56 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: alsa-devel, Lars-Peter Clausen, Kuninori Morimoto, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski

The ALSA core takes care that all preallocated memory is freed when the PCM
itself is freed. There is no need to do this manually in the driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
---
 sound/soc/txx9/txx9aclc.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/sound/soc/txx9/txx9aclc.c b/sound/soc/txx9/txx9aclc.c
index 070e44e..88eacfd 100644
--- a/sound/soc/txx9/txx9aclc.c
+++ b/sound/soc/txx9/txx9aclc.c
@@ -282,11 +282,6 @@ static struct snd_pcm_ops txx9aclc_pcm_ops = {
 	.pointer	= txx9aclc_pcm_pointer,
 };
 
-static void txx9aclc_pcm_free_dma_buffers(struct snd_pcm *pcm)
-{
-	snd_pcm_lib_preallocate_free_for_all(pcm);
-}
-
 static int txx9aclc_pcm_new(struct snd_soc_pcm_runtime *rtd)
 {
 	struct snd_card *card = rtd->card->snd_card;
@@ -412,7 +407,6 @@ static struct snd_soc_platform_driver txx9aclc_soc_platform = {
 	.remove		= txx9aclc_pcm_remove,
 	.ops		= &txx9aclc_pcm_ops,
 	.pcm_new	= txx9aclc_pcm_new,
-	.pcm_free	= txx9aclc_pcm_free_dma_buffers,
 };
 
 static int txx9aclc_soc_platform_probe(struct platform_device *pdev)
-- 
1.8.0

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

* Re: [PATCH 3/7] ASoC: intel: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 ` [PATCH 3/7] ASoC: intel: " Lars-Peter Clausen
@ 2015-01-05  9:28   ` Jarkko Nikula
  0 siblings, 0 replies; 9+ messages in thread
From: Jarkko Nikula @ 2015-01-05  9:28 UTC (permalink / raw)
  To: Lars-Peter Clausen, Mark Brown, Liam Girdwood
  Cc: Manuel Lauss, alsa-devel, Guennadi Liakhovetski, Kuninori Morimoto

On 01/02/2015 02:56 PM, Lars-Peter Clausen wrote:
> The ALSA core takes care that all preallocated memory is freed when the PCM
> itself is freed. There is no need to do this manually in the driver.
>
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> ---
>   sound/soc/intel/sst-baytrail-pcm.c      | 6 ------
>   sound/soc/intel/sst-haswell-pcm.c       | 6 ------
>   sound/soc/intel/sst-mfld-platform-pcm.c | 7 -------
>   3 files changed, 19 deletions(-)

Acked-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>

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

* Re: [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all()
  2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
                   ` (5 preceding siblings ...)
  2015-01-02 12:56 ` [PATCH 7/7] ASoC: txx9: " Lars-Peter Clausen
@ 2015-01-05 21:30 ` Mark Brown
  6 siblings, 0 replies; 9+ messages in thread
From: Mark Brown @ 2015-01-05 21:30 UTC (permalink / raw)
  To: Lars-Peter Clausen
  Cc: alsa-devel, Kuninori Morimoto, Liam Girdwood, Manuel Lauss,
	Jarkko Nikula, Guennadi Liakhovetski


[-- Attachment #1.1: Type: text/plain, Size: 361 bytes --]

On Fri, Jan 02, 2015 at 01:56:07PM +0100, Lars-Peter Clausen wrote:
> The ALSA core takes care that all preallocated memory is freed when the PCM
> itself is freed. There is no need to do this manually in the driver.
> Similarly there is also no need to do it on the pcm_new() error path as the
> PCM will be freed if a error is returned.

Applied all, thanks.

[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



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

end of thread, other threads:[~2015-01-05 21:31 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-02 12:56 [PATCH 1/7] ASoC: dmaengine: Remove unnecessary snd_pcm_lib_preallocate_free_for_all() Lars-Peter Clausen
2015-01-02 12:56 ` [PATCH 2/7] ASoC: au1x: " Lars-Peter Clausen
2015-01-02 12:56 ` [PATCH 3/7] ASoC: intel: " Lars-Peter Clausen
2015-01-05  9:28   ` Jarkko Nikula
2015-01-02 12:56 ` [PATCH 4/7] ASoC: nuc900: " Lars-Peter Clausen
2015-01-02 12:56 ` [PATCH 5/7] ASoC: rcar: " Lars-Peter Clausen
2015-01-02 12:56 ` [PATCH 6/7] ASoC: sh: " Lars-Peter Clausen
2015-01-02 12:56 ` [PATCH 7/7] ASoC: txx9: " Lars-Peter Clausen
2015-01-05 21:30 ` [PATCH 1/7] ASoC: dmaengine: " Mark Brown

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.