Re: TEAC CD-R55S doesn't work

Bernhard Erdmann (Bernhard.Erdmann@gmx.de)
Thu, 18 Feb 1999 12:59:31 +0100


> > > What I tried: I tried to burn an image, I built with xcdroast -->
> > > Master (but I think that makes no sense). After some output (see
> > > attached cdrecord-error.txt.gz) I get this error:
> > >
> > > [...]
> > > Waiting for reader process to fill input-buffer ... input-buffer
> > > ready.
> > > Judging disk...done.
> > > Calibrating laser...done.
> > > cdrecord: Cannot allocate memory. Cannot send SCSI cmd via ioctl

I've had the same problem some days ago and I was able to solve it.
There's probably something wrong with your /usr/include/scsi/sg.h and
the SCSI buffers.

man sane-scsi (generic scanner driver) recommends to increase the value
of SG_BIG_BUFF in /usr/include/scsi/sg.h from 32768 to 130560 for faster
scanning. (There should be a symlink /usr/include/scsi ->
../src/linux/include/scsi.) Thereafter I had to recompile both the
kernel and sane.

[man sane-scsi]
To keep scanning times to a minimum, it is strongly recom
mended to use a large buffer size for the generic SCSI
driver. By default, Linux uses a buffer of size 32KB.
This works, but for many cheaper scanners this causes
scanning to be slower by about a factor of four than when
using a size of 127KB. Linux defines the size of this
buffer by macro SG_BIG_BUFF in header file
/usr/include/scsi/sg.h. Unless a system is seriously
short on memory, it is recommended to increase this value
to the maximum legal value of 128*1024-512=130560 bytes.
After changing this value, it is necessary to recompile
both the kernel (or the SCSI generic module) and the SCSI
backends.

So weeks ago I put a generic SCSI buffer of 128 KB into the 2.0.36
kernel I got from a tarball.
Then I bought a Teac CD-R55S, I compiled xcdroast 0.96e, everything went
fine and I toasted 20 CDs on a single weekend.

Then, for some reason I wanted to have the 2.0.36 kernel installed by an
rpm. I deleted /usr/src/linux, rpm -ihv kernel-source-2.0.36-3.i386.rpm,
compiled a new kernel and bang: cdrecord: Cannot allocate memory. Cannot
send SCSI cmd via ioctl. And xscanimage told me: Error - out of memory.
It took me 1 1/2 days to get an idea about that sg.h I had modified
weeks ago. Well, the kernel presented a SCSI-buffer of 32 KB to xcdroast
expecting 128 KB... You can imagine what happens!

I modified sg.h once again, recompiled the kernel, recompiled xcdroast,
recompiled sane-1.00, but xcdroast didn't work.

Oh, f***king rpm, rpm -e --nodeps kernel-source-2.0.36-3, installed the
original tarball again, made some symlinks as being told in
/usr/src/linux/README, modified sg.h once more, compiled...
And everything's okay now.

Hope this helps,
Bernie

-- 
Computers are actually powered by Chaos theory, not electricity...that
is just for the fan.

- 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/