Re: Problem with kernel 2.4ac9, ava1505, snapscan1236s, sane1.0.4

From: Erik Inge Bolsų (
Date: Sun Jan 14 2001 - 10:53:44 PST

  • Next message: Douglas Gilbert: "Re: Problem with kernel 2.4ac9, ava1505, snapscan1236s, sane1.0.4"

    On Sun, 14 Jan 2001, Douglas Gilbert wrote:
    >> [snapscan] request_sense
    >> [snapscan] sense_handler(5, 0xbffff324, 0x8050c90)
    >> [snapscan] sense_handler: sense key is invalid.

    The problem was here. The aha152x.c driver filtered out request_sense
    commands and always returned 0 on them. (At least that's my layman's
    understanding of the problem.)

    int aha152x_queue(Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *))
         if(*SCpnt->cmnd == REQUEST_SENSE) {
                    SCpnt->result = 0;

                    return SUCCESS;

            return aha152x_internal_queue(SCpnt, 0, 0, 0, done);

    Removing everything but the "return" line fixed the problem :)

    Thanks to Marcel Martin for the fix :)

    P.S. Judging from a quick look, a few other drivers may have the same
    problem. aha1542.c at least seems to be affected. I have no such card, so
    can't test.

    The scanner works fine now, whee :)=

    Erik I. Bolsų | email: <knan at>
    The UNIX philosophy basically involves giving you enough rope to
    hang yourself.  And then a couple of feet more, just to be sure.

    -- Source code, list archive, and docs: To unsubscribe: echo unsubscribe sane-devel | mail

    This archive was generated by hypermail 2b29 : Sun Jan 14 2001 - 10:11:54 PST