Messages in this thread | | | Date | Mon, 7 Jun 1999 12:45:05 +0200 | From | Martin Mares <> | Subject | Re: RFC: Devices, buses and hotplug |
| |
Hello,
> Hmm, as long as we don't have fds[1] that could die gracefully > and applications that could handle this... > > ... I would call this _impossible_ > > The thing is, that a fd is valid from sucessful open to > sucessful close. So everything this fd depends on, is open too. > > But we could introduce a new signal (bad, since not POSIX), or > use a new semantic for an existing one (even worse) to say "Hey, > this fd is dead now! Any use from now on will cause errors."
I think we need no new signals. All what we need is to revoke all file handles connected to the device having been unplugged.
> Another simplier problem is, if the ressource is _temporarly_ > unavailable[2].
The question is whether we really want to handle such situation without userland noticing the exchange or whether the right view is "the old device ceased to exist, a new one appeared with the same name, all programs need to re-open it."
(Please note that in the most common cases, i.e. swapping of disks in a disk array or replacing faulty network cards, the exchange can be fully transparent even without introducing any additional mechanisms and without userland programs noticing it.)
Have a nice fortnight -- Martin `MJ' Mares <mj@ucw.cz> http://atrey.karlin.mff.cuni.cz/~mj/ Faculty of Math and Physics, Charles University, Prague, Czech Rep., Earth "This message transmited on 100% recycled electrons."
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |