Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757676AbYFWMSv (ORCPT ); Mon, 23 Jun 2008 08:18:51 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753678AbYFWMSo (ORCPT ); Mon, 23 Jun 2008 08:18:44 -0400 Received: from mx1.suse.de ([195.135.220.2]:42574 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753407AbYFWMSo (ORCPT ); Mon, 23 Jun 2008 08:18:44 -0400 Date: Mon, 23 Jun 2008 14:18:42 +0200 Message-ID: From: Takashi Iwai To: Marcin Slusarz Cc: Cedric Bregardis , Jean-Christian Hassler , LKML Subject: Re: oops in Audiowerk2 ALSA driver In-Reply-To: <20080622164443.GA7208@joi> References: <20080622164443.GA7208@joi> User-Agent: Wanderlust/2.12.0 (Your Wildest Dreams) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 MULE XEmacs/21.5 (beta28) (fuki) (x86_64-suse-linux) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1202 Lines: 32 At Sun, 22 Jun 2008 18:47:17 +0200, Marcin Slusarz wrote: > > Hi > There's a race between registration routine and interrupt handler in aw2 driver > which manifested as oops on some box [1]. > > When snd_aw2_create calls request_irq chip data are not yet fully initialized. > If interrupt raises before snd_aw2_create call snd_aw2_saa7146_setup, driver may > oops or read/write other port than its own. (chip->base_addr is initialized in > snd_aw2_saa7146_setup, but is used in snd_aw2_saa7146_interrupt via READREG/WRITEREG) > > The simple fix would be to move call to snd_aw2_saa7146_setup before request_irq, > but snd_aw2_saa7146_setup enables interrupts... > > PS: I don't have this hardware. > > Marcin > > [1] http://kerneloops.org/guilty.php?guilty=snd_aw2_saa7146_interrupt&version=2.6.26-rc&start=1703936&end=1736703&class=oops Thanks for spotting the bug. I fixed this on my git tree now and will post a pull request soon later. Takashi -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/