From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg KH Date: Wed, 14 Jan 2004 23:24:12 +0000 Subject: Re: unclean yanking out of device? Message-Id: <20040114232412.GA9983@kroah.com> List-Id: References: <20040114160002.G57254@forte.austin.ibm.com> In-Reply-To: <20040114160002.G57254@forte.austin.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org On Wed, Jan 14, 2004 at 05:08:49PM -0600, linas@austin.ibm.com wrote: > On Wed, Jan 14, 2004 at 02:19:21PM -0800, Greg KH wrote: > > On Wed, Jan 14, 2004 at 04:00:02PM -0600, linas@austin.ibm.com wrote: > > > > > > What is supposed to happen if I just yank out a (network/scsi) device > > > while it is being used, without calling any of the hotplug unregister > > > remove etc. functions in advance? > > > > Depends on the driver, device type, subsystem type, and most > > importantly, the kernel version (2.2?, 2.4?, 2.6?) > > > > This is better asked on the linux-kernel mailing list, with a specific > > and detailed question, as you have asked a very broad one. > > Sorry, this was intentionally a broad question; I'm hoping to hash > out a broad answer here before I go lkml. > > Let me rephrase: I want to make 'appropriate' changes to the 2.6/2.7 > kernel, and some selected device drivers, so that a sysadmin can > stupidly yank out an *ordinary* PCI card (not a pcmcia) without doing > an orderly shutdown in advance. Hahahaha... no, PCI drivers can not handle that. See the PCI Hotplug spec for why. PCI drivers need to be told to shut down before removing them. And that will not change, sorry. > More specifically, I have a whiz-bang PCI controller that will > shut down a PCI slot when it is hit by a cosmic ray (data/address > parity error, other error, etc.). I want to be able to "recover" > that slot, (if its recoverable), and get things going again. That pci controller needs to tell the OS that it is going to shut down that pci slot. Otherwise that pci controller violates the PCI spec. Note, yes I know that cPCI controllers do this, that's a totally different story... the os still needs to know before turning off a slot. greg k-h ------------------------------------------------------- This SF.net email is sponsored by: Perforce Software. Perforce is the Fast Software Configuration Management System offering advanced branching capabilities and atomic changes on 50+ platforms. Free Eval! http://www.perforce.com/perforce/loadprog.html _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel