From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from soft.uni-linz.ac.at ([140.78.95.99] helo=zeus.soft.uni-linz.ac.at) by canuck.infradead.org with esmtp (Exim 4.54 #1 (Red Hat Linux)) id 1FBvBQ-000137-Hb for linux-mtd@lists.infradead.org; Wed, 22 Feb 2006 09:41:40 -0500 Received: from [140.78.95.234] (wall4.soft.uni-linz.ac.at [140.78.95.234]) by zeus.soft.uni-linz.ac.at (8.11.7p1+Sun/8.11.1) with ESMTP id k1MEfYa09953 for ; Wed, 22 Feb 2006 15:41:34 +0100 (MET) Message-ID: <43FC781B.5030608@researchstudios.at> Date: Wed, 22 Feb 2006 15:41:31 +0100 From: Simon Vogl MIME-Version: 1.0 To: linux-mtd@lists.infradead.org Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: [PATCH] cfi: init wait queue in chip struct List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , This patch fixes a kernel oops for Intel P30 flashes, where the wait queue head was not initialized for the flchip struct, which in turn caused a crash at the first read operation. Simon diff -ur linux-2.6.15.4.mtd-git/drivers/mtd/chips/cfi_cmdset_0001.c linux-2.6.15.4/drivers/mtd/chips/cfi_cmdset_0001.c --- linux-2.6.15.4.mtd-git/drivers/mtd/chips/cfi_cmdset_0001.c 2006-02-21 15:23:34.000000000 +0100 +++ linux-2.6.15.4/drivers/mtd/chips/cfi_cmdset_0001.c 2006-02-22 11:48:29.000000000 +0100 @@ -408,6 +408,7 @@ cfi->chips[i].buffer_write_time = 1<cfiq->BufWriteTimeoutTyp; cfi->chips[i].erase_time = 1<cfiq->BlockEraseTimeoutTyp; cfi->chips[i].ref_point_counter = 0; + init_waitqueue_head(&(cfi->chips[i].wq)); } map->fldrv = &cfi_intelext_chipdrv; -- _______________________________________________________________________ Dr. Simon Vogl ARC Seibersdorf research GmbH Research Studios Austria, Studio Pervasive Computing Applications Aubrunnerweg 1, A-4040 Linz, Austria Tel: +43 732 2468-5350, Fax: +43 732 2468-25350 mailto: simon.vogl@researchstudio.at