From: Pavel Machek Subject: Re: [regression] Re: 2.6.26-rc6: pcmcia stopped working Date: Thu, 26 Jun 2008 00:15:29 +0200 Message-ID: <20080625221529.GA1600@elf.ucw.cz> References: <20080622224022.GA2066@elf.ucw.cz> <20080623081309.GA10820@isilmar.linta.de> <20080623081811.GA1850@elf.ucw.cz> <20080623083046.GA12849@isilmar.linta.de> <20080625102347.GA2011@elf.ucw.cz> <20080625110105.GA1551@elf.ucw.cz> <20080625215324.GA1562@elf.ucw.cz> <20080625220946.GA1587@elf.ucw.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from gprs189-60.eurotel.cz ([160.218.189.60]:51715 "EHLO gprs189-60.eurotel.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753218AbYFYWPw (ORCPT ); Wed, 25 Jun 2008 18:15:52 -0400 Content-Disposition: inline In-Reply-To: <20080625220946.GA1587@elf.ucw.cz> Sender: linux-ide-owner@vger.kernel.org List-Id: linux-ide@vger.kernel.org To: kernel list , "Rafael J. Wysocki" , linux-pcmcia@lists.infradead.org, bzolnier@gmail.com, linux-ide@vger.kernel.org, Greg KH Hi! > > Hmm, hitting sysrq-w produces no blocked task until I eject pcmcia > > card. Backtrace there is: > > > > Greg, I believe some traces lead to sysfs, can you help here? > > ide_unregister() does not complete :-(. > > device_unregister(&hwif->gendev); > + printk("ide_unregister: waiting for rel_comp\n"); > wait_for_completion(&hwif->gendev_rel_comp); > > ...that wait_for_completion never returns. ...and this fixes PCMCIA/IDE for me... (Pseudopatch) Pavel diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c --- a/drivers/ide/ide.c +++ b/drivers/ide/ide.c @@ -336,29 +341,38 @@ void ide_unregister(ide_hwif_t *hwif) ++irq_count; g = g->next; } while (g != hwgroup->hwif); if (irq_count == 1) free_irq(hwif->irq, hwgroup); ide_remove_port_from_hwgroup(hwif); device_unregister(hwif->portdev); device_unregister(&hwif->gendev); - wait_for_completion(&hwif->gendev_rel_comp); +// wait_for_completion(&hwif->gendev_rel_comp); + msleep(1000); /* * Remove us from the kernel's knowledge */ -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html