Subject: Re: looking for devices on PCI bus
To: None <jonathan@DSG.Stanford.EDU,>
From: None <>
List: tech-kern
Date: 05/03/2001 00:49:27
	>> All bus drivers (that support hotplug of any sort) need a method
	>> of determining what devices are attached to them, and that requires
	>> a reprobe.  If the bus hardware can inform the driver that the state
	>> of a specific slot has changed, then the reprobe can be limited to that
	>> slot.  Otherwise the entire bus needs to be re-probed.
	>> The simplest way to handle re-probing the bus is to keep the original
	>> locator information around.  

	No, the *really* simplest thing is to just do a reprobe :).

	We just have to make the autoconfiguration system is smart enough to
	avoid re-probing on "slots" which are already "match"ed (and not yet detached).

If we're talking about *Hot* swap then any device can be removed at any
time, so you do need to probe each slot to make sure the hardware is still
the same.

For `luke warm swap' you can force the user to manually detach drivers
before removing the hardware.  In this case you would not need to re-probe
attached devices since removing hardware with an attached driver is an
illegal operation.

	In the hotswap case, i think we need to know which device has been
	swapped in any case-- unless we rely on rescanning fast enough to
	detect duplicates.  Just what do hotswap direct buses (PCI)
	provide, here?

It allows you to add or remove devices w/o needing to reconfigure
the kernel.  PCMCIA devices tend to be hotswapped.  The operation
is detected and drivers changed without user intervention.  (Now,
if there was some way to keep the configuration information for 
the driver so I wouldn't have to reconfigure my network if I
accidentally eject my network card....)