[PATCH] CONFIG_SCSI_MULTI_LUN && CONFIG_BLK_DEV_IDE_SCSI ==> Oops.

David Woodhouse (David.Woodhouse@mvhi.com)
Wed, 25 Nov 1998 21:01:40 +0000


When enabling both CONFIG_SCSI_MULTI_LUN and ide-scsi emulation, the ATAPI
devices will usually respond to every LUN. This can lead to an (as yet
untraced) oops.

My simple workaround for the problem was to get the 'victim' to turn off the
MULTI_LUN option. The cause of the oops, however, is as yet unknown. I'll post
that in a moment.

I've now produced a simple patch which disables multi-lun support on the IDE
devices, by aborting any request directed at a LUN other than zero.

Is this the correct response, though - is it ever possible that an ATAPI device
would have multiple LUNs?

--- linux/drivers/scsi/ide-scsi.c.orig Wed Nov 25 20:19:43 1998
+++ linux/drivers/scsi/ide-scsi.c Wed Nov 25 20:47:26 1998
@@ -728,6 +728,10 @@
printk (KERN_ERR "ide-scsi: drive id %d not present\n", cmd->target);
goto abort;
}
+ if (cmd->lun != 0) {
+ printk (KERN_DEBUG "ide-scsi: Request for lun %d on drive %d - aborted.\n",cmd->lun, cmd->target);
+ goto abort;
+ }
scsi = drive->driver_data;
pc = kmalloc (sizeof (idescsi_pc_t), GFP_ATOMIC);
rq = kmalloc (sizeof (struct request), GFP_ATOMIC);

---- ---- ----
David Woodhouse David.Woodhouse@mvhi.com Office: (+44) 1223 810302
Project Leader, Process Information Systems Mobile: (+44) 976 658355
Axiom (Cambridge) Ltd., Swaffham Bulbeck, Cambridge, CB5 0NA, UK.
finger dwmw2@ferret.lmh.ox.ac.uk for PGP key.

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