Messages in this thread | | | Date | Mon, 17 Nov 1997 02:41:04 -0500 | From | Joe Pranevich <> | Subject | Re: CD-ROM support question. |
| |
Isaac Connor wrote: > > This seems like it should be simple to do...let's see, when do we need to > mount the CD? Only when someone tries to access it...which means we need > something to detect when someone takes a look at the mount point... > > Now, all we need to do is trap when someone presses the eject > button...does doing so send any sort of signal? Can it be looked for? > If it can, when you press the button, we unmount the CD.. So we need two > things: > > 1. Something to detect a mount point access > 2. Something to detect the Eject button press...
Not to express my desire for such a feature (I rather like the current setup) but it would be far easier to detect the CD-ROM insertion than it would be to monitor the mount point access. Although you would not *need* the cdrom to be mounted at all times, it certainly wouldn't harm things. And since the 'eject' button can already be blocked when a CD-ROM is mounted, I'd assume that you can set up an alternate handler for the 'eject' press to unmount (or not, if it's in use) the drive.
Of course, this may be all an internal part of the ATAPI driver and not available for prodding and poking. But someone (?) if I recall has been working on updating all the cdrom drivers into a nice, neat set with identical features (or at least, interface)... that might be the person to consult for this type of addition.
I'd just also like to mention that a BSD clone I was using for the Power Mac a while back had this. It was called 'mountd' and was run as a daemon process. (Obviously) In addition to CD-ROMs, it handled all 'ejectable' mediums (which, on the Mac, included all the floppy drives) and worked with the fstab (I think) Don't know if it can be handled this way in Linux, I'm not an expert in this functionality nor do I have the time to check, unfortunately. But, maybe... just maybe, in the long run it would be good to have this sort of thing be doable, somehow, for the non-UNIX savvy that may grace our humble OS.
Joe Pranevich, who is up far too late
> Isaac > iconnor@uwaterloo.ca
| |