Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750852AbWC0KQT (ORCPT ); Mon, 27 Mar 2006 05:16:19 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1750861AbWC0KQT (ORCPT ); Mon, 27 Mar 2006 05:16:19 -0500 Received: from ns2.suse.de ([195.135.220.15]:7116 "EHLO mx2.suse.de") by vger.kernel.org with ESMTP id S1750852AbWC0KQS (ORCPT ); Mon, 27 Mar 2006 05:16:18 -0500 Date: Mon, 27 Mar 2006 12:16:17 +0200 Message-ID: From: Takashi Iwai To: Christian Trefzer Cc: lkml Subject: Re: snd-nm256: hard lockup on every second module load after powerup In-Reply-To: <20060326054542.GA11961@hermes.uziel.local> References: <20060326054542.GA11961@hermes.uziel.local> 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 (beta25) (eggplant) (i386-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 X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2493 Lines: 50 At Sun, 26 Mar 2006 07:45:42 +0200, Christian Trefzer wrote: > > Hi folks, > > I have this really old Dell Latitude CPiA here containing the dreaded > neomagic combined audio/video chipset, and observe some hard lockup > sometimes, which is not supposed to be anything special wrt. other > people with similar laptops having the same trouble. The only regularity > I noticed was that after completely removing power to the machine, the > sound driver can be loaded without locking the thing hard. Any further > attempt, eg. rmmod and insmod or reboot with alsasound startup script, > will result in a dead machine. Every time. Cut the power, and next time > it will survive - exactly once. > > Now this chip is a NM2200 / 256AV, and I already did some reading in the > alsa driver source code, but adding printk()s all over the place just > showed that it does not lock up during init_chip() or poking at the > registers during ac97_reset(), but shortly after the latter, approx. > half a second or so - it might still be a consequence thereof. > > My basic idea is, with the device being entirely undocumented (to hell > with all hardware vendors who don't even release specs after the devices > are not even sold anymore, by the way), that the code is missing a > proper device reset, and trying to re-init some parts just kill the > machine. Cutting the power really is not that nice as a workaround. I'd > love to try something along the lines of saving the device's state as a > whole, and before reloading the module, restore that state again. The > difference between before and after should somehow give a clue about the > proper reset procedure - or so I hope. > > Unfortunately I failed with my previous attempts to modify the driver > appropriately. Now that it's basically back to formula, I wanted to ask > whether there is a possibility to read and write back whole parts of > memory directly from/to the device, or if I should rather store each and > every register somewhere I can later restore it from, one by one. I'd > even prefer userspace, and am currently experimenting with pcidump. > > > Any hints would be greatly appreciated! Thanks a bunch, Try 2.6.16-git tree. Some patches for this problem are there. 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/