Re: Recommended way to handle suspend/resume on notebooks
Re: Recommended way to handle suspend/resume on notebooks
- Subject: Re: Recommended way to handle suspend/resume on notebooks
- From: Jeff Moore <email@hidden>
- Date: Sun, 11 Oct 2009 12:15:25 -0700
The HAL doesn't do anything special to handle sleep/wake. It just
happens. The HAL treats it just like any other large discrepancy in
time. Generally, the HAL notices it when it does the first overload
check after waking up. Ultimately, it depends on what was going on
when sleep happened as to when the HAL will first notice the
discontinuity. The result is that the HAL re-synchs the IO thread's
time line with the hardware's time stamps.
For a piece of hardware, sleep generally means that things like DMAs
are turned off and what not. So while the HAL is sorting out it's own
issues, the driver is also contending with restarting itself. In
practical terms, this usually means that the driver's time stamps will
either re-start back at 0 or have some other large discontinuity in
both the sample and host time.
At any rate, I would expect that the result of all this re-synching
might result in a few overloads in a row (two or three seem likely for
a lot of cases where the interruption might happen). But I would not
expect that there would be an endless stream of them followed by the
hardware stopping.
A couple of questions come to mind:
- What hardware/OS are you using?
- Is this behavior particular to your app or do other apps have
similar behaviors?
- Have you looked at the telemetry in HALLab?
On Oct 11, 2009, at 10:32 AM, Stéphane Letz wrote:
Our application does not do anything to handle suspend/resume on
notebooks, but is seems CoreAudio gets disturbed when resume occurs.
We can bunch of kAudioDeviceProcessorOverload notifications and
audio actually stops.
What is the recommended way to handle suspend/resume on notebooks
for audio applications?
--
Jeff Moore
Core Audio
Apple
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden