On Tue, Jun 8, 2010 at 7:46 AM, Thomas Schmitt <[email protected]> wrote:
> Hi, > > attached is my proposal how to make the Solaris > driver capable of detecting drives without vold, > and how to implement access mode MMC_RDWR. > > There are still some problems to solve: > > ------------------------------------------------ > > Executing SCSI commands needs superuser > authority. I do not know yet, whether there > is a finer granulated way to aquire the right > to perform the uscsi ioctl. > It has been a while, but I think have running a suid program would be sufficient. And going further it might be that being in the right administrative group with would be okay too. > ------------------------------------------------ > > When inserting a CD with 5000 files in four > sessions, the operating system rattles the > drive for about 30 seconds. > During that time it is nearly impossible > to do own read operations. The drive even > reports read errors in SCSI sense reply. > I suspect my old enemy hald behind that. >:[ > > ------------------------------------------------ > > MMC_RDWR_EXCL does not yet trigger a locking > attempt. I need to learn more about Solaris. > > ------------------------------------------------ > > There are two alternative ways to identify > CD drives among the /dev/rdsk devices: > > - perform SCSI command INQUIRY and look for > CD-ROM code 5 in byte 0 of reply. > This relies on SCSI specs SPC-3. > > - perform ioctl(DKIOCINFO) and check .dki_ctype > whether it is DKC_CDROM. > This relies on Solaris man dkio. > libcdio already used ioctl(DKIOCGMEDIAINFO) > and included <dkio.h> > I don't any reason not to do this. Do you? > > See #ifdef LIBCDIO_SOLARIS_WITH_CD_INQUIRY > Currently it is not defined. I.e. DKIO gets used. > > I gather by this you are suggesting adding an option to libcdio's configure script. I am not opposed to that if you can show a benefit in some circumstances. Right now it is not clear what the benefit is of forcing SCSI INQUIRY over DKIO. Do we know what the benefit is? > ------------------------------------------------ > > Have a nice day :) > > Thomas > > -- > GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT! > Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01 >
