* [PATCH 1/2] dma: edma: Update caps->residue_granularity to match with reality
2014-07-16 12:29 [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer Peter Ujfalusi
@ 2014-07-16 12:29 ` Peter Ujfalusi
2014-07-16 12:29 ` [PATCH 2/2] dma: edma: Support to suppress the period interrupts in cyclic mode Peter Ujfalusi
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Peter Ujfalusi @ 2014-07-16 12:29 UTC (permalink / raw)
To: nsekhar, joelf, vinod.koul
Cc: linux-kernel, linux-omap, davinci-linux-open-source, dmaengine,
tglx
The edma can report accurate DMA position so update the residue_granularity
to DMA_RESIDUE_GRANULARITY_BURST.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
---
drivers/dma/edma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/dma/edma.c b/drivers/dma/edma.c
index fe55f78ea137..d5017abcf7cb 100644
--- a/drivers/dma/edma.c
+++ b/drivers/dma/edma.c
@@ -1001,7 +1001,7 @@ static int edma_dma_device_slave_caps(struct dma_chan *dchan,
caps->directions = BIT(DMA_DEV_TO_MEM) | BIT(DMA_MEM_TO_DEV);
caps->cmd_pause = true;
caps->cmd_terminate = true;
- caps->residue_granularity = DMA_RESIDUE_GRANULARITY_DESCRIPTOR;
+ caps->residue_granularity = DMA_RESIDUE_GRANULARITY_BURST;
return 0;
}
--
2.0.0
^ permalink raw reply related [flat|nested] 5+ messages in thread* [PATCH 2/2] dma: edma: Support to suppress the period interrupts in cyclic mode
2014-07-16 12:29 [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer Peter Ujfalusi
2014-07-16 12:29 ` [PATCH 1/2] dma: edma: Update caps->residue_granularity to match with reality Peter Ujfalusi
@ 2014-07-16 12:29 ` Peter Ujfalusi
2014-07-28 6:13 ` [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer Peter Ujfalusi
2014-07-28 11:34 ` Vinod Koul
3 siblings, 0 replies; 5+ messages in thread
From: Peter Ujfalusi @ 2014-07-16 12:29 UTC (permalink / raw)
To: nsekhar, joelf, vinod.koul
Cc: linux-kernel, linux-omap, davinci-linux-open-source, dmaengine,
tglx
If the client (audio) does not request interrupts for every period we can
disable them.
With updated audio driver stack we can play audio w/o the need to process
any edma interrupts.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
---
drivers/dma/edma.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/dma/edma.c b/drivers/dma/edma.c
index d5017abcf7cb..69f1f5250120 100644
--- a/drivers/dma/edma.c
+++ b/drivers/dma/edma.c
@@ -723,10 +723,10 @@ static struct dma_async_tx_descriptor *edma_prep_dma_cyclic(
edesc->absync = ret;
/*
- * Enable interrupts for every period because callback
- * has to be called for every period.
+ * Enable period interrupt only if it is requested
*/
- edesc->pset[i].param.opt |= TCINTEN;
+ if (tx_flags & DMA_PREP_INTERRUPT)
+ edesc->pset[i].param.opt |= TCINTEN;
}
/* Place the cyclic channel to highest priority queue */
--
2.0.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer
2014-07-16 12:29 [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer Peter Ujfalusi
2014-07-16 12:29 ` [PATCH 1/2] dma: edma: Update caps->residue_granularity to match with reality Peter Ujfalusi
2014-07-16 12:29 ` [PATCH 2/2] dma: edma: Support to suppress the period interrupts in cyclic mode Peter Ujfalusi
@ 2014-07-28 6:13 ` Peter Ujfalusi
2014-07-28 11:34 ` Vinod Koul
3 siblings, 0 replies; 5+ messages in thread
From: Peter Ujfalusi @ 2014-07-28 6:13 UTC (permalink / raw)
To: nsekhar, joelf, vinod.koul
Cc: linux-kernel, linux-omap, davinci-linux-open-source, dmaengine,
tglx
On 07/16/2014 03:29 PM, Peter Ujfalusi wrote:
> Hi,
>
> After this series clients can ask to not receive notifications after each period.
> In this case we can disable the completion interrupt since the position reporting
> does not rely on it for cyclic mode.
> Patchset for ASoC part has been sent which allows users space to take adventage
> of SNDRV_PCM_INFO_NO_PERIOD_WAKEUP:
> [1] http://mailman.alsa-project.org/pipermail/alsa-devel/2014-July/078993.html
ping.
> When both series applied on top of linux-next:
>
> # cache the audio file in memory
> cat some_music.mp3 > /dev/null
> # start PA
> pulseaudio -v
> # in another terminal, play the music via PA
> mplayer -ao pulse some_music.mp3
> # yet another terminal to monitor the interrupts
> watch cat /proc/interrupts
> # note the non increasing number of edma interrupts ;)
>
> Regards,
> Peter
> ---
> Peter Ujfalusi (2):
> dma: edma: Update caps->residue_granularity to match with reality
> dma: edma: Support to suppress the period interrupts in cyclic mode
>
> drivers/dma/edma.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
--
Péter
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer
2014-07-16 12:29 [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer Peter Ujfalusi
` (2 preceding siblings ...)
2014-07-28 6:13 ` [PATCH 0/2] dma: edma: Allow to disable eDMA IRQ during cyclic transfer Peter Ujfalusi
@ 2014-07-28 11:34 ` Vinod Koul
3 siblings, 0 replies; 5+ messages in thread
From: Vinod Koul @ 2014-07-28 11:34 UTC (permalink / raw)
To: Peter Ujfalusi
Cc: nsekhar, joelf, linux-kernel, linux-omap,
davinci-linux-open-source, dmaengine, tglx
On Wed, Jul 16, 2014 at 03:29:19PM +0300, Peter Ujfalusi wrote:
> Hi,
>
> After this series clients can ask to not receive notifications after each period.
> In this case we can disable the completion interrupt since the position reporting
> does not rely on it for cyclic mode.
> Patchset for ASoC part has been sent which allows users space to take adventage
> of SNDRV_PCM_INFO_NO_PERIOD_WAKEUP:
> [1] http://mailman.alsa-project.org/pipermail/alsa-devel/2014-July/078993.html
Applied, thanks
Please use right subsystem name for patches, i have fixed that while
applying
--
~Vinod
^ permalink raw reply [flat|nested] 5+ messages in thread