All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vinod Koul <vinod.koul@intel.com>
To: Boojin Kim <boojin.kim@samsung.com>
Cc: linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	'Kukjin Kim' <kgene.kim@samsung.com>,
	'Russell King' <linux@arm.linux.org.uk>,
	'Dan Williams' <djbw@fb.com>,
	'Jaswinder Singh' <jassi.brar@samsung.com>,
	'Ben Dooks' <ben-linux@fluff.org>
Subject: Re: [PATCH 2/2] ARM: EXYNOS: support burst mode for for dev-to-mem and dev-to-mem transmit
Date: Mon, 4 Mar 2013 11:15:56 +0530	[thread overview]
Message-ID: <20130304054556.GG22513@intel.com> (raw)
In-Reply-To: <00eb01ce0e45$20223c90$6066b5b0$%kim@samsung.com>

On Tue, Feb 19, 2013 at 11:02:09AM +0900, Boojin Kim wrote:
> This patch adds to support burst mode for for dev-to-mem and dev-to-mem transmit
> 
> Signed-off-by: Boojin Kim <boojin.kim@samsung.com>
> ---
>  arch/arm/plat-samsung/dma-ops.c              |   10 ++++++++--
>  arch/arm/plat-samsung/include/plat/dma-ops.h |    1 +
>  2 files changed, 9 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm/plat-samsung/dma-ops.c b/arch/arm/plat-samsung/dma-ops.c
> index d088afa..c25e842 100644
> --- a/arch/arm/plat-samsung/dma-ops.c
> +++ b/arch/arm/plat-samsung/dma-ops.c
> @@ -54,14 +54,20 @@ static int samsung_dmadev_config(unsigned ch,
>  		slave_config.direction = param->direction;
>  		slave_config.src_addr = param->fifo;
>  		slave_config.src_addr_width = param->width;
> -		slave_config.src_maxburst = 1;
Hi Boojin,

what do you mean by the busrt mode here?

fwiw the meanining of above maxburst is:
@src_maxburst: the maximum number of words (note: words, as in
units of the src_addr_width member, not bytes) that can be sent
in one burst to the device. Typically something like half the
FIFO depth on I/O peripherals so you don't overflow it. This
may or may not be applicable on memory sources.

> +		if (param->maxburst)
> +			slave_config.src_maxburst = param->maxburst;
> +		else
> +			slave_config.src_maxburst = 1;
>  		dmaengine_slave_config(chan, &slave_config);
>  	} else if (param->direction == DMA_MEM_TO_DEV) {
>  		memset(&slave_config, 0, sizeof(struct dma_slave_config));
>  		slave_config.direction = param->direction;
>  		slave_config.dst_addr = param->fifo;
>  		slave_config.dst_addr_width = param->width;
> -		slave_config.dst_maxburst = 1;
> +		if (param->maxburst)
> +			slave_config.dst_maxburst = param->maxburst;
> +		else
> +			slave_config.dst_maxburst = 1;
>  		dmaengine_slave_config(chan, &slave_config);
>  	} else {
>  		pr_warn("unsupported direction\n");
> diff --git a/arch/arm/plat-samsung/include/plat/dma-ops.h b/arch/arm/plat-samsung/include/plat/dma-ops.h
> index f5144cd..95893c7 100644
> --- a/arch/arm/plat-samsung/include/plat/dma-ops.h
> +++ b/arch/arm/plat-samsung/include/plat/dma-ops.h
> @@ -35,6 +35,7 @@ struct samsung_dma_prep {
>  struct samsung_dma_config {
>  	enum dma_transfer_direction direction;
>  	enum dma_slave_buswidth width;
> +	u32 maxburst;
>  	dma_addr_t fifo;
>  };
> 
> --
> 1.7.5.4
> 
> 
> 

WARNING: multiple messages have this Message-ID (diff)
From: vinod.koul@intel.com (Vinod Koul)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/2] ARM: EXYNOS: support burst mode for for dev-to-mem and dev-to-mem transmit
Date: Mon, 4 Mar 2013 11:15:56 +0530	[thread overview]
Message-ID: <20130304054556.GG22513@intel.com> (raw)
In-Reply-To: <00eb01ce0e45$20223c90$6066b5b0$%kim@samsung.com>

On Tue, Feb 19, 2013 at 11:02:09AM +0900, Boojin Kim wrote:
> This patch adds to support burst mode for for dev-to-mem and dev-to-mem transmit
> 
> Signed-off-by: Boojin Kim <boojin.kim@samsung.com>
> ---
>  arch/arm/plat-samsung/dma-ops.c              |   10 ++++++++--
>  arch/arm/plat-samsung/include/plat/dma-ops.h |    1 +
>  2 files changed, 9 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm/plat-samsung/dma-ops.c b/arch/arm/plat-samsung/dma-ops.c
> index d088afa..c25e842 100644
> --- a/arch/arm/plat-samsung/dma-ops.c
> +++ b/arch/arm/plat-samsung/dma-ops.c
> @@ -54,14 +54,20 @@ static int samsung_dmadev_config(unsigned ch,
>  		slave_config.direction = param->direction;
>  		slave_config.src_addr = param->fifo;
>  		slave_config.src_addr_width = param->width;
> -		slave_config.src_maxburst = 1;
Hi Boojin,

what do you mean by the busrt mode here?

fwiw the meanining of above maxburst is:
@src_maxburst: the maximum number of words (note: words, as in
units of the src_addr_width member, not bytes) that can be sent
in one burst to the device. Typically something like half the
FIFO depth on I/O peripherals so you don't overflow it. This
may or may not be applicable on memory sources.

> +		if (param->maxburst)
> +			slave_config.src_maxburst = param->maxburst;
> +		else
> +			slave_config.src_maxburst = 1;
>  		dmaengine_slave_config(chan, &slave_config);
>  	} else if (param->direction == DMA_MEM_TO_DEV) {
>  		memset(&slave_config, 0, sizeof(struct dma_slave_config));
>  		slave_config.direction = param->direction;
>  		slave_config.dst_addr = param->fifo;
>  		slave_config.dst_addr_width = param->width;
> -		slave_config.dst_maxburst = 1;
> +		if (param->maxburst)
> +			slave_config.dst_maxburst = param->maxburst;
> +		else
> +			slave_config.dst_maxburst = 1;
>  		dmaengine_slave_config(chan, &slave_config);
>  	} else {
>  		pr_warn("unsupported direction\n");
> diff --git a/arch/arm/plat-samsung/include/plat/dma-ops.h b/arch/arm/plat-samsung/include/plat/dma-ops.h
> index f5144cd..95893c7 100644
> --- a/arch/arm/plat-samsung/include/plat/dma-ops.h
> +++ b/arch/arm/plat-samsung/include/plat/dma-ops.h
> @@ -35,6 +35,7 @@ struct samsung_dma_prep {
>  struct samsung_dma_config {
>  	enum dma_transfer_direction direction;
>  	enum dma_slave_buswidth width;
> +	u32 maxburst;
>  	dma_addr_t fifo;
>  };
> 
> --
> 1.7.5.4
> 
> 
> 

  reply	other threads:[~2013-03-04  5:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-19  2:02 [PATCH 2/2] ARM: EXYNOS: support burst mode for for dev-to-mem and dev-to-mem transmit Boojin Kim
2013-02-19  2:02 ` Boojin Kim
2013-03-04  5:45 ` Vinod Koul [this message]
2013-03-04  5:45   ` Vinod Koul

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130304054556.GG22513@intel.com \
    --to=vinod.koul@intel.com \
    --cc=ben-linux@fluff.org \
    --cc=boojin.kim@samsung.com \
    --cc=djbw@fb.com \
    --cc=jassi.brar@samsung.com \
    --cc=kgene.kim@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.