Re: Pb with external RAID controller in lk 2.4

Kurt Garloff
2002-05-24T17:17:33Z

[-- Attachment #1: Type: text/plain, Size: 2147 bytes --]

Hi Patrick,

On Wed, May 22, 2002 at 10:03:39AM -0700, Patrick Mansfield wrote:
> On Wed, May 22, 2002 at 09:49:01AM +0200, Fabien Salvi wrote:
> > Fabien Salvi wrote:
>
> > > May 17 16:19:36 node01 kernel: Attached scsi disk sda at scsi0, channel
> > > 0, id 0, lun 0
> > > May 17 16:19:36 node01 kernel: Attached scsi disk sdb at scsi0, channel
> > > 0, id 0, lun 1
[...]
> > > May 17 16:19:36 node01 kernel: Attached scsi disk sdh at scsi0, channel
> > > 0, id 0, lun 7
> > > May 17 16:19:36 node01 kernel: Attached scsi CD-ROM sr0 at scsi2,
> > > channel 0, id 5, lun 0
[...]
> > > Like you can see, it founds 8 disks !
[...]
> > I've tried in the 2.4 kernel to increase the max_scsi_luns because I
> > thought lk may find as disks as many luns I have, but it's not the case
> > : it don't find more than 8 disks (maybe this is reassuring...).
> >
> > So here is the problem : the lk 2.4 finds more disks than I have !
>
> The 2.4 kernel won't scan past LUN 7 for SCSI-2 devices - you can try
> modifying the code and set the max to 31 in scsi_scan.c.

If you have a FC device (or whatever device that supports LUNs > 7) that
reports as SCSI-2, you can flag it with BLIST_LARGELUN in scsi_scan.c
to get it treated as SCSI-3.
(New in 2.4.18)

> The device is probably setting the peripheral-qualifier (PQ) such that the
> scan continues but the device is marked offline, this is just annoying
> if do not have a lot of them. In scsi_scan.c:
>
> /* Use the peripheral qualifier field to determine online/offline */
> if (((scsi_result[0] >> 5) & 7) == 1) SDpnt->online = FALSE;
> else SDpnt->online = TRUE;

Those fields should not be set by the device, IMHO.
Or has their meaning changed for SCSI-3 devs? Then the appropriate check
should be added to the code.

But actually the problem is different: Too many LUNs where detected :-(

Regards,
--
Kurt Garloff <garloff@suse.de> Eindhoven, NL
GPG key: See mail header, key servers Linux kernel development
SuSE Linux AG, Nuernberg, DE SCSI, Security

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]