From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: spin_lock_irqwhat ? Date: Fri, 14 May 2004 12:37:46 +0200 Sender: alsa-devel-admin@lists.sourceforge.net Message-ID: References: <20040513205751.6b61e53c.pochini@shiny.it> Mime-Version: 1.0 (generated by SEMI 1.14.5 - "Awara-Onsen") Content-Type: text/plain; charset=US-ASCII Return-path: In-Reply-To: <20040513205751.6b61e53c.pochini@shiny.it> Errors-To: alsa-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: Giuliano Pochini Cc: alsa-devel@lists.sourceforge.net, clemens@ladisch.de List-Id: alsa-devel@alsa-project.org At Thu, 13 May 2004 20:57:51 +0200, Giuliano Pochini wrote: > > > On Mon, 10 May 2004 17:08:49 +0200 > Takashi Iwai wrote: > > > prepare and trigger callbacks are already in irq-disabled. > > i.e. you need only spin_lock() in them. > > Does it mean that ALSA acquires the lock only when it calls PCM callbacks, > that is trigger(), etc., are atomic only wrt other PCM functions ? sorry i don't understand your question. the prepare and the trigger callbacks acquire several locks. first, the global rw_lock for the pcm linking (snd_pcm_link_rwlock), the group lock the substream belongs to, and the lock for the substream itself. and the first lock/unlock is done with *_irq(). > hdsp.c and rme9652.x use spin_*lock_irq() inside prepare(). oh, it's wrong. fixed on cvs now. thanks, Takashi ------------------------------------------------------- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click