linux-omap.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kevin Hilman <khilman@ti.com>
To: Grazvydas Ignotas <notasas@gmail.com>
Cc: linux-omap@vger.kernel.org, Paul Walmsley <paul@pwsan.com>
Subject: Re: PM related performance degradation on OMAP3
Date: Mon, 09 Apr 2012 12:03:18 -0700	[thread overview]
Message-ID: <877gxobudk.fsf@ti.com> (raw)
In-Reply-To: <CANOLnOP5gq4Vtt00SgRNW-3GZDWk0sukBgJx4V6rkMLL+b6G-w@mail.gmail.com> (Grazvydas Ignotas's message of "Sat, 7 Apr 2012 01:50:19 +0300")

Grazvydas Ignotas <notasas@gmail.com> writes:

> Hello,
>
> I'm DMA seeing performance loss related to CONFIG_PM on OMAP3.
>
> # CONFIG_PM is set:
> echo 3 > /proc/sys/vm/drop_caches
> # file copy from NAND (using NAND driver in DMA mode)
> dd if=/mnt/tmp/a of=/dev/null bs=1M count=32
> 33554432 bytes (32.0MB) copied, 9.088714 seconds, 3.5MB/s
> # file read from SD (hsmmc uses DMA)
> dd if=/dev/mmcblk0 of=/dev/null bs=1M count=32
> 33554432 bytes (32.0MB) copied, 2.065460 seconds, 15.5MB/s
>
> # CONFIG_PM not set:
> # NAND
> dd if=/mnt/tmp/a of=/dev/null bs=1M count=32
> 33554432 bytes (32.0MB) copied, 5.653534 seconds, 5.7MB/s
> # SD
> dd if=/dev/mmcblk0 of=/dev/null bs=1M count=32
> 33554432 bytes (32.0MB) copied, 1.919007 seconds, 16.7MB/s
>
> While SD card performance loss is not that bad (~7%), NAND one is
> worrying (~39%). I've tried disabling/enabling CONFIG_CPU_IDLE, also
> cpuidle states over sysfs, it did not have any significant effect. Is
> there something else to try?

Looks like we might need a PM QoS constraint when there is DMA activity
in progress.  

You can try doing a pm_qos_add_request() for PM_QOS_CPU_DMA_LATENCY when
DMA transfers are active and I suspect that will help.

> I'm guessing this is caused by CPU wakeup latency to service DMA
> interrupts? I've noticed that if I keep CPU busy, the loss is reduced
> almost completely.

Yeah, that suggests a QoS constraint is what's needed here.

> Talking about cpuidle, what's the difference between C1 and C2 states?
> They look mostly the same.

Except for clockdomains are not allowed to idle in C1 which results in
much shorter wakeup latency.

> Then there is omap3_do_wfi, it seems to be unconditionally putting
> SDRC on self-refresh, would it make sense to just do wfi in higher
> power states, like OMAP4 seems to be doing?

Not sure what you're referring to in OMAP4.  There we do WFI in every
idle state.

Kevin

  reply	other threads:[~2012-04-09 19:03 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-06 22:50 PM related performance degradation on OMAP3 Grazvydas Ignotas
2012-04-09 19:03 ` Kevin Hilman [this message]
2012-04-11  0:29   ` Grazvydas Ignotas
2012-04-12  0:19     ` Kevin Hilman
2012-04-13 17:32       ` Grazvydas Ignotas
2012-04-13 19:32       ` Grazvydas Ignotas
2012-04-17 14:30         ` Kevin Hilman
2012-04-17 21:50           ` Grazvydas Ignotas
2012-04-18  0:36             ` Kevin Hilman
2012-04-24  9:50           ` Jean Pihet
2012-04-24 10:38             ` Santosh Shilimkar
2012-04-24 12:21               ` Tero Kristo
2012-04-24 12:50                 ` Jean Pihet
2012-04-24 13:04                   ` Tero Kristo
2012-04-24 14:29             ` Kevin Hilman
2012-05-01 14:10               ` Jean Pihet
2012-05-01 17:27                 ` Kevin Hilman
2012-05-02  5:59                   ` Paul Walmsley
2012-05-02 19:46                   ` Jean Pihet
2012-05-07 17:31                     ` Kevin Hilman
2012-05-09 11:00                       ` Jean Pihet
2012-04-12 23:02     ` Woodruff, Richard
2012-04-11 14:59 ` Gary Thomas
2012-04-11 17:23   ` Grazvydas Ignotas
2012-04-11 18:20     ` Gary Thomas
2012-04-11 19:17   ` Kevin Hilman
2012-04-12 10:44     ` Gary Thomas
2012-04-12 14:14       ` Kevin Hilman
2012-04-12 15:28         ` Gary Thomas
2012-04-12 16:57           ` Kevin Hilman
2012-04-12 17:10             ` Gary Thomas
2012-04-12 18:08               ` Kevin Hilman
2012-04-12 19:05                 ` Gary Thomas
2012-04-12 22:03                   ` Kevin Hilman
2012-04-13  0:39                     ` Gary Thomas
2012-04-13  9:13             ` Felipe Balbi

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=877gxobudk.fsf@ti.com \
    --to=khilman@ti.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=notasas@gmail.com \
    --cc=paul@pwsan.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).