From: Clemens Ladisch <clemens@ladisch.de>
To: Yiliang Bao <yiliangb@gmail.com>
Cc: alsa-devel@alsa-project.org
Subject: Re: Why use spin_lock or spin_lock_irq in trigger callback (audio capture)?
Date: Fri, 26 Feb 2010 10:05:43 +0100 [thread overview]
Message-ID: <4B878EE7.2010200@ladisch.de> (raw)
In-Reply-To: <e5baf3861002251332n7333fb12tb15b055baffaa4a2@mail.gmail.com>
Yiliang Bao wrote:
> I looked at some PCI audio capture driver like BT878 (sound/pci/bt87x.c) or
> SAA7134 (drivers/media/video/saa7134-alsa.c), I found that spin_lock instead
> of spin_lock_irq (or spin_lock_irqsave) is used in trigger function. Is
> there any reason for that?
Yes, the trigger callback is called with interrupts already disabled.
http://www.alsa-project.org/~tiwai/writing-an-alsa-driver/ch05s08.html
Regards,
Clemens
prev parent reply other threads:[~2010-02-26 9:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-25 21:32 Why use spin_lock or spin_lock_irq in trigger callback (audio capture)? Yiliang Bao
2010-02-26 9:05 ` Clemens Ladisch [this message]
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=4B878EE7.2010200@ladisch.de \
--to=clemens@ladisch.de \
--cc=alsa-devel@alsa-project.org \
--cc=yiliangb@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.