linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bryan O'Donoghue <pure.logic@nexus-software.ie>
To: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Peter Hurley <peter@hurleysoftware.com>,
	"linux-serial@vger.kernel.org" <linux-serial@vger.kernel.org>,
	Vinod Koul <vinod.koul@intel.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	dmaengine <dmaengine@vger.kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	"Puustinen, Ismo" <ismo.puustinen@intel.com>,
	Heikki Krogerus <heikki.krogerus@linux.intel.com>
Subject: Re: [PATCH v5 00/11] serial: 8250: split LPSS to 8250_lpss, enable DMA on Quark
Date: Sun, 12 Jun 2016 18:13:07 +0100	[thread overview]
Message-ID: <1465751587.15050.23.camel@nexus-software.ie> (raw)
In-Reply-To: <CAHp75VczbhPEvp6gn-5hPFdSGscNeyZMzPQWeeB1Xza1mHD8dw@mail.gmail.com>

On Tue, 2016-06-07 at 13:04 +0300, Andy Shevchenko wrote:
> > I'll find some time to look at both a short stream and a long
> stream,
> > based on the branch you've indicated and maybe against the latest
> > stable kernel.
> 
> Please, do. I'm planning to resend new version soon (this week or
> lately beginning of the next one).

So.

Generally DMA appears to make little-to-no difference here. With small
data sets, 128 bytes in the test case - there appears to be a slight
performance gain at lower BAUD rates, however for small data-sets and
large data sets 32k for the large test case, there appears to be a
performance penalty at higher BAUD rates.

One thing I have noticed is that the following never completes and
can't be reset back to mode=0 or mode=3 to restore functionality -
definitely worth looking at if you are spinning another patch.

### never completes ####
root@galileo:~# echo 1 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# stty -F /dev/ttyS0 921600
root@galileo:~# time cat tester.txt > /dev/ttyS0
### never completes ####

Performance data set

root@galileo:~# dmesg > tester.txt
root@galileo:~# ls -las tester.txt 
32 -rw-r--r-- 1 root root 32300
Jan  1  2001 tester.txt


#### With DMA on @ 926100 32k file ####

root@galileo:~# echo 0 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# stty -F /dev/ttyS0 921600
root@galileo:~# time cat tester.txt > /dev/ttyS0

real    0m0.421s
user    0m0.010s
sys     0m0.000s


### With NoDMA on @ 926100 32k file ####

root@galileo:~# echo 3 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# stty -F /dev/ttyS0 921600
root@galileo:~# time cat tester.txt > /dev/ttyS0

real    0m0.421s
user    0m0.020s
sys     0m0.000s

#### With DMA on @ 9600 32k file ####
root@galileo:~# echo 0 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# stty -F /dev/ttyS0 9600  
root@galileo:~# time cat tester.txt > /dev/ttyS0

real    0m34.381s
user    0m0.000s
sys     0m0.010s

#### With NoDMA on @ 9600 32k file #####
root@galileo:~# echo 3 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# stty -F /dev/ttyS0 9600
root@galileo:~# time cat tester.txt > /dev/ttyS0

real    0m34.391s
user    0m0.010s
sys     0m0.000s


root@galileo:~# ls -las tester_small.txt 
4 -rw-r--r-- 1 root root 128 Jan  1 00:06 tester_small.txt

### With DMA on @ 921600 128 byte test file ###
root@galileo:~# stty -F /dev/ttyS0 921600
root@galileo:~# echo 0 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# time cat tester_small.txt > /dev/ttyS0

real    0m0.031s
user    0m0.010s
sys     0m0.000s

### With NoDMA on @ 921600 128 byte test file ###
root@galileo:~# stty -F /dev/ttyS0 921600
root@galileo:~# echo 3 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# time cat tester_small.txt > /dev/ttyS0

real    0m0.013s
user    0m0.010s
sys     0m0.000s

### With DMA on @ 9600 128 byte test file ###
root@galileo:~# stty -F /dev/ttyS0 9600
root@galileo:~# echo 0 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# time cat tester_small.txt > /dev/ttyS0

real    0m0.161s
user    0m0.000s
sys     0m0.010s

### With NoDMA on @ 9600 128 byte test file ###
root@galileo:~# stty -F /dev/ttyS0 9600
root@galileo:~# echo 3 > /sys/class/tty/ttyS0/dma_mode
root@galileo:~# time cat tester_small.txt > /dev/ttyS0

real    0m0.161s
user    0m0.000s
sys     0m0.000s

---
bod

  reply	other threads:[~2016-06-12 17:13 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-06 15:17 [PATCH v5 00/11] serial: 8250: split LPSS to 8250_lpss, enable DMA on Quark Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 01/11] dmaengine: dw: keep copy of custom slave config in dwc Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 02/11] dmaengine: dw: provide probe(), remove() stubs for users Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 03/11] dmaengine: dw: set polarity of handshake interface Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 04/11] dmaengine: dw: override LLP support if asked in platform data Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 05/11] serial: 8250_dma: switch to new dmaengine_terminate_* API Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 06/11] serial: 8250_dma: adjust DMA address of the UART Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 07/11] serial: 8250: enable AFE on ports where FIFO is 16 bytes Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 08/11] serial: 8250_lpss: split LPSS driver to separate module Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 09/11] serial: 8250_lpss: move Quark code from PCI driver Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 10/11] serial: 8250_lpss: enable MSI for Intel Quark Andy Shevchenko
2016-05-06 15:17 ` [PATCH v5 11/11] serial: 8250_lpss: enable DMA on Intel Quark UART Andy Shevchenko
2016-05-12 15:06 ` [PATCH v5 00/11] serial: 8250: split LPSS to 8250_lpss, enable DMA on Quark Andy Shevchenko
2016-05-12 15:59   ` Vinod Koul
2016-05-19  1:18   ` Bryan O'Donoghue
2016-05-24 17:37     ` Andy Shevchenko
2016-05-24 18:08       ` Andy Shevchenko
2016-05-26 16:36         ` Bryan O'Donoghue
2016-06-07 10:04           ` Andy Shevchenko
2016-06-12 17:13             ` Bryan O'Donoghue [this message]
2016-06-13 11:16               ` Andy Shevchenko
2016-05-26 16:11       ` Bryan O'Donoghue

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=1465751587.15050.23.camel@nexus-software.ie \
    --to=pure.logic@nexus-software.ie \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=dmaengine@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=heikki.krogerus@linux.intel.com \
    --cc=ismo.puustinen@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=peter@hurleysoftware.com \
    --cc=vinod.koul@intel.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).