From: Giuliano Pochini <pochini@shiny.it>
To: Alsa-devel <alsa-devel@alsa-project.org>
Subject: Echoaudio, suspend/resume question on rawmidi device
Date: Sun, 3 Jan 2010 21:55:45 +0100 [thread overview]
Message-ID: <20100103215545.1e76385e@Jay> (raw)
I have some patches that add PM support to all echoaudio drivers. It seems
to work fine, but it has been tested on two cards only and the rawmidi
device hasn't been tested at all. I can't test it because
suspend-to-anything does not work on my pmac. I want to be sure at least it
cannot deadlock.
* On suspend:
Rawmidi input is interrupt-driven. The driver tells the card to stop
accepting data.
Rawmidi output is timer-driven. The driver uses a timer to check if the
card's output buffer has room for more data to send. Do del_timer_sync()
and wait until all buffered data is sent, which may take 20ms (64 bytes at
31250bps).
* On resume:
Input: Re-enable midi in.
Output: Restart the timer.
Do you see any race condition or weak points in this scheme, especially in
the midi-out part ? Is del_timer_sync() safe ?
--
Giuliano.
reply other threads:[~2010-01-03 20:56 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20100103215545.1e76385e@Jay \
--to=pochini@shiny.it \
--cc=alsa-devel@alsa-project.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.