From: Nishanth Menon <nm@ti.com>
To: Daniel Mack <zonque@gmail.com>,
Gururaja Hebbar <gururaja.hebbar@ti.com>,
joelf@ti.com, Vaibhav Bedia <vaibhav.bedia@gmail.com>
Cc: balajitk@ti.com, s.neumann@raumfeld.com,
Sekhar Nori <nsekhar@ti.com>, Russ Dill <Russ.Dill@ti.com>,
"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
Linux ARM Kernel List <linux-arm-kernel@lists.infradead.org>,
Matt Porter <matt@ohporter.com>
Subject: Re: [PATCH v4] ARM: omap: edma: add suspend suspend/resume hooks
Date: Thu, 7 Nov 2013 09:48:06 -0600 [thread overview]
Message-ID: <527BB636.60403@ti.com> (raw)
In-Reply-To: <527BB38A.1060609@gmail.com>
On 11/07/2013 09:36 AM, Daniel Mack wrote:
> On 11/07/2013 04:18 PM, Nishanth Menon wrote:
>> Tested this on a vendor V3.12 tag based kernel:
>>
>> Test patch: http://pastebin.com/AmnktQ7B
>> test: echo -n "1">/sys/power/pm_print_times; rtcwake -d /dev/rtc0 -m
>> mem -s 5
>>
>>
>> with the current patch: http://pastebin.com/RujarRLV
>> suspend_late and resume_early: http://pastebin.com/RujarRLV
>
> These two are identical.
>
>> suspend_noirq and resume_noirq: http://pastebin.com/nKfbm7Mj
>
> And I can't see any difference between this one and the first one,
> except for slightly different timings. Am I missing anything?
aah, that happens to be a little key :)
if you see the current patch, it happens around line 417,
with suspend_late, it moves deeper(or later) into suspend around 738
with noirq - it is as late as it can get - around line 823 just before
the last set of arch suspend calls are done.
>> one needs to be careful of the sequence - donot forget that
>> omap_device also does stuff in the background to every SoC device in
>> noirq - sequence is paramount. you would want to ensure edma is saving
>> after every single dependent device is done with it's stuff and
>> guarenteed to never request any further transaction, and resume is
>> done before any of the dependent devices need edma. but edma is also a
>> peripheral that omap_device and generic runtime pm framework deals
>> with - so ensure sequences consider that as well.
>
> So, what would you say which sequence is correct then? :)
Disclaimer: I have not dug deeper, other than a cursory look. With
proper error handling, proper split between suspend and suspend_late
seems appropriate to me(at noirq, runtime_get could fail as pmruntime
is disabled as part of suspend sequence and could race with
omap_device handling in a future cleanup there) - with the assumption
that all drivers that are using things have cleaned up prior to that.
edma is a generic engine that many drivers may choose to use - example
of MMC used in this discussion is just one of other potential users -
for a generic driver like dma, you'd want to stay as deep in the
suspend as possible. you may also want to ensure that further calls
will not succeed until resume is invoked.
--
Regards,
Nishanth Menon
WARNING: multiple messages have this Message-ID (diff)
From: nm@ti.com (Nishanth Menon)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v4] ARM: omap: edma: add suspend suspend/resume hooks
Date: Thu, 7 Nov 2013 09:48:06 -0600 [thread overview]
Message-ID: <527BB636.60403@ti.com> (raw)
In-Reply-To: <527BB38A.1060609@gmail.com>
On 11/07/2013 09:36 AM, Daniel Mack wrote:
> On 11/07/2013 04:18 PM, Nishanth Menon wrote:
>> Tested this on a vendor V3.12 tag based kernel:
>>
>> Test patch: http://pastebin.com/AmnktQ7B
>> test: echo -n "1">/sys/power/pm_print_times; rtcwake -d /dev/rtc0 -m
>> mem -s 5
>>
>>
>> with the current patch: http://pastebin.com/RujarRLV
>> suspend_late and resume_early: http://pastebin.com/RujarRLV
>
> These two are identical.
>
>> suspend_noirq and resume_noirq: http://pastebin.com/nKfbm7Mj
>
> And I can't see any difference between this one and the first one,
> except for slightly different timings. Am I missing anything?
aah, that happens to be a little key :)
if you see the current patch, it happens around line 417,
with suspend_late, it moves deeper(or later) into suspend around 738
with noirq - it is as late as it can get - around line 823 just before
the last set of arch suspend calls are done.
>> one needs to be careful of the sequence - donot forget that
>> omap_device also does stuff in the background to every SoC device in
>> noirq - sequence is paramount. you would want to ensure edma is saving
>> after every single dependent device is done with it's stuff and
>> guarenteed to never request any further transaction, and resume is
>> done before any of the dependent devices need edma. but edma is also a
>> peripheral that omap_device and generic runtime pm framework deals
>> with - so ensure sequences consider that as well.
>
> So, what would you say which sequence is correct then? :)
Disclaimer: I have not dug deeper, other than a cursory look. With
proper error handling, proper split between suspend and suspend_late
seems appropriate to me(at noirq, runtime_get could fail as pmruntime
is disabled as part of suspend sequence and could race with
omap_device handling in a future cleanup there) - with the assumption
that all drivers that are using things have cleaned up prior to that.
edma is a generic engine that many drivers may choose to use - example
of MMC used in this discussion is just one of other potential users -
for a generic driver like dma, you'd want to stay as deep in the
suspend as possible. you may also want to ensure that further calls
will not succeed until resume is invoked.
--
Regards,
Nishanth Menon
next prev parent reply other threads:[~2013-11-07 15:48 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-30 20:21 [PATCH v4] ARM: omap: edma: add suspend suspend/resume hooks Daniel Mack
2013-10-30 20:21 ` Daniel Mack
2013-10-31 22:25 ` Vaibhav Bedia
2013-10-31 22:25 ` Vaibhav Bedia
2013-11-06 17:36 ` Joel Fernandes
2013-11-06 17:36 ` Joel Fernandes
2013-11-07 13:30 ` Gururaja Hebbar
2013-11-07 13:30 ` Gururaja Hebbar
2013-11-07 13:32 ` Daniel Mack
2013-11-07 13:32 ` Daniel Mack
2013-11-07 15:18 ` Nishanth Menon
2013-11-07 15:18 ` Nishanth Menon
2013-11-07 15:36 ` Daniel Mack
2013-11-07 15:36 ` Daniel Mack
2013-11-07 15:48 ` Nishanth Menon [this message]
2013-11-07 15:48 ` Nishanth Menon
2013-11-07 20:42 ` Vaibhav Bedia
2013-11-07 20:42 ` Vaibhav Bedia
2013-11-15 14:39 ` Nishanth Menon
2013-11-15 14:39 ` Nishanth Menon
2013-11-17 22:09 ` Daniel Mack
2013-11-17 22:09 ` Daniel Mack
2013-11-07 20:34 ` Vaibhav Bedia
2013-11-07 20:34 ` Vaibhav Bedia
2013-11-07 15:34 ` Nishanth Menon
2013-11-07 15:34 ` Nishanth Menon
2013-11-07 16:27 ` Grygorii Strashko
2013-11-07 16:27 ` Grygorii Strashko
2013-11-07 20:46 ` Vaibhav Bedia
2013-11-07 20:46 ` Vaibhav Bedia
2013-11-07 16:34 ` Joel Fernandes
2013-11-07 16:34 ` Joel Fernandes
2013-11-07 16:49 ` Joel Fernandes
2013-11-07 16:49 ` Joel Fernandes
2013-11-07 17:37 ` Daniel Mack
2013-11-07 17:37 ` Daniel Mack
2013-11-07 21:39 ` Joel Fernandes
2013-11-07 21:39 ` Joel Fernandes
2013-11-08 4:07 ` Gururaja Hebbar
2013-11-08 4:07 ` Gururaja Hebbar
2013-11-08 7:51 ` Daniel Mack
2013-11-08 7:51 ` Daniel Mack
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=527BB636.60403@ti.com \
--to=nm@ti.com \
--cc=Russ.Dill@ti.com \
--cc=balajitk@ti.com \
--cc=gururaja.hebbar@ti.com \
--cc=joelf@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-omap@vger.kernel.org \
--cc=matt@ohporter.com \
--cc=nsekhar@ti.com \
--cc=s.neumann@raumfeld.com \
--cc=vaibhav.bedia@gmail.com \
--cc=zonque@gmail.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 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.