All of lore.kernel.org
 help / color / mirror / Atom feed
From: ludovic.desroches@atmel.com (Ludovic Desroches)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/7] serial: at91: add tx dma support
Date: Tue, 9 Jul 2013 11:57:04 +0200	[thread overview]
Message-ID: <20130709095704.GE4013@ludovic.desroches@atmel.com> (raw)
In-Reply-To: <1373351626-30143-3-git-send-email-elen.song@atmel.com>

On Tue, Jul 09, 2013 at 02:33:41PM +0800, Elen Song wrote:

[...]
  
> @@ -977,6 +1172,8 @@ static int atmel_startup(struct uart_port *port)
>  		pdc->ofs = 0;
>  	}
>  
> +	atmel_tx_request_dma(atmel_port);
> +
>  	/*
>  	 * If there is a specific "open" function (to register
>  	 * control line interrupts)

Here we can have both use_pdc_tx and use_dma_tx set to true. To avoid this, we
can do:

if (atmel_use_pdc_tx(port)) {

} else {
	atmel_tx_request_dma(atmel_port);
}

or force use_pdc_tx to 0 in atmel_tx_request_dma function when we set
use_dma_tx to 1.

I prefer the second one since using dma has a higher priority than using pdc
contrary to the first one.


Regards

Ludovic

  reply	other threads:[~2013-07-09  9:57 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-09  6:33 [PATCH 0/7] serial: at91: make usart and uart support dma transfer Elen Song
2013-07-09  6:33 ` [PATCH 1/7] serial: at91: correct definition from DMA to PDC Elen Song
2013-07-09  7:31   ` Ludovic Desroches
2013-07-09  7:57     ` elen.song
2013-07-09  9:17       ` Ludovic Desroches
2013-07-09  9:19         ` elen.song
2013-07-09 11:21     ` Jean-Christophe PLAGNIOL-VILLARD
2013-07-09 11:22   ` Jean-Christophe PLAGNIOL-VILLARD
2013-07-09 13:34     ` Jean-Christophe PLAGNIOL-VILLARD
2013-07-09 16:07   ` Nicolas Ferre
2013-07-09  6:33 ` [PATCH 2/7] serial: at91: add tx dma support Elen Song
2013-07-09  9:57   ` Ludovic Desroches [this message]
2013-07-09 10:24     ` elen.song
2013-07-09  6:33 ` [PATCH 3/7] serial: at91: add rx " Elen Song
2013-07-09  6:33 ` [PATCH 4/7] serial: at91: make DBGU support dma and pdc transfers Elen Song
2013-07-09 13:26   ` Jean-Christophe PLAGNIOL-VILLARD
2013-07-09  6:33 ` [PATCH 5/7] serial: at91: distinguish usart and uart Elen Song
2013-07-09 11:25   ` Jean-Christophe PLAGNIOL-VILLARD
2013-07-09  6:33 ` [PATCH 6/7] serial: at91: modify UART to use software timer to trigger rx Elen Song
2013-07-09  6:33 ` [PATCH 7/7] serial: at91: add dma support in usart binding descriptions Elen Song
2013-07-09  7:40   ` Ludovic Desroches

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=20130709095704.GE4013@ludovic.desroches@atmel.com \
    --to=ludovic.desroches@atmel.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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.