[12] in linux-scsi channel archive

home help back first fref pref prev next nref lref last post

Re: SCSI generic

daemon@ATHENA.MIT.EDU (Daniel MORRISON)
Mon Jan 16 15:35:36 1995

From: draker@binkley.cs.mcgill.ca (Daniel MORRISON)
Date: Mon, 16 Jan 1995 15:00:25 -0500
To: linux-scsi@vger.rutgers.edu

>> On Sun, 15 Jan 1995 04:36:57 -0500, jered@vorlon.mit.edu said:

  j> I seem to be having troubles with the SCSI generic interface. I ran
  j> MAKEDEV sg to create the devices, and compiled generic into my kernel
  j> (1.1.80), but when I try to use a program called cdda2wav, it complains
  j> that my CD-ROM is not a valid CD-ROM device. There don't appear to be any
  j> man pages on the sg# devices.

I have the same with kernels after 1.1.76. 1.1.76 itself still did
access the sg device of the CDROM properly with cdda2wav.

I really have no idea if this is related, but I thought I'd throw it
out in case it caused some sudden realizations or something.  I am on
both the scsi list and the kernel release list, and got this from
Jeremy Garman:

>From owner-linux-kernel-patch@vger.rutgers.edu Sun Jan 15 04:31:34 1995
Date: Sun, 15 Jan 1995 02:05:19 -0600 (CST)
From: Jason Garman <garman@phs.k12.ar.us>

If you have SCSI CD-ROMS, you might want to apply the following patch 
from Linus which fixes a (very small) error in the kernel:

=====   sr.c one-character patch: apply by hand   =====
===== the "sg_template" should be a "sr_template" =====

--- v1.1.81/linux/drivers/scsi/sr.c     Fri Jan 13 16:57:06 1995
+++ linux/drivers/scsi/sr.c     Fri Jan 13 17:22:53 1995
@@ -985,7 +985,7 @@

   major = MAJOR_NR << 8;

-  for(cpnt = scsi_CDs, i=0; i<sg_template.dev_max; i++, cpnt++)
+  for(cpnt = scsi_CDs, i=0; i<sr_template.dev_max; i++, cpnt++)
     if(cpnt->device == SDp) {
       /*
        * Since the cdrom is read-only, no need to sync the device.

-- 
-------------------------------------------------------------------------------
Daniel `Jeem!' Morrison	 draker@cs.mcgill.ca | Snail Mail Address indeterminate
Whenever anyone says, "theoretically", they really mean, "not really".
		-- Dave Parnas

home help back first fref pref prev next nref lref last post