[EMAIL PROTECTED] wrote:
>
> Hi Doug,
>
> I could **NOT** find your patch in either 2.2.14 nor 2.2.15-pre15 so I
> backported it into 2.2.15-pre15 but it did **NOT** help. Surprisingly the
> SCSI_IOCTL_TAGGED_ENABLE ioctl() also did not work, it appeared to me as a
> no-op since it succeeded but did not do anything...
>
> -> I did all that with 2.2.15-pre15.
>
> However, here's the /proc/scsi/aic7xxx/0 output:
> Default Tag Queue Depth: 8
> Tagged Queue By Device array for aic7xxx host instance 0:
> {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}
> Actual queue depth per device for aic7xxx host instance 0:
> {8,8,1,1,1,1,1,1,1,1,1,1,1,1,1,1}
>
> ------ After add-single-device
> -[begin]-------------------------------------
> Default Tag Queue Depth: 8
> Tagged Queue By Device array for aic7xxx host instance 0:
> {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}
> Actual queue depth per device for aic7xxx host instance 0:
> {1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1}
OK, I've added code in the 5.1.29 driver to address this problem. It should
exist any more. The general issue is that during the normal bus scan, the mid
layer SCSI code frobs around with device->queuing_supported (or something like
that) and we use that to determine if we should enabled TCQ on that device
when the mid layer calls our select_queue_depths() routine. However, when you
do a scsi-add-single-device, the select_queue_depths() routine gets called
once again with the same arguments as before, the complete device list, but
this time the devices don't have the queueing supported flag set. This was
causing the aic7xxx driver to reset the devices to untagged status as it
rescanned the list.
My fix for this in the driver was to simply check the
p->max_queue_depth[device] entry in the aic7xxx driver for each device in the
device list. If that entry is not at the default setting, then I assume its
queue depth has already been set and I leave it at what it currently is.
Otherwise, I set it.
The one thing I didn't check is if the scsi-add-single-device code bothers to
frob the queueing supported flag before calling into the select_queue_depths()
routine. If it doesn't, then devices added after the normal scan will always
get set to untagged status.
On the bright side, untagged status with the aic7xxx driver isn't really so
bad, since the driver sets the low level ops to untagged status, but always
lies to the mid layer and sets the mid layer's queue depth on the device to 3,
then the driver will queue up 2 commands on the p->delayed_scbs[target] queue
(it builds the commands before putting them on there) so that when we get a
command completion on the device we can issue the next command directly from
the interrupt handler to keep latency as low as possible.
> I'm pretty sure that I'm losing TCQ depth on the disks (id 0 and 1) because
> the "Tag Queue Enable Flags: " are all zeroed after add-single device. The
> SCSI_IOCTL_TAGGED_ENABLE ioctl() also did **NOT** turn them back on.
No, it won't because it doesn't effect the aic7xxx driver, only the mid layer
code. You're looking directly into the aic7xxx driver's queueing status when
you cat /proc/scsi/aic7xxx/?
--
Doug Ledford <[EMAIL PROTECTED]> http://people.redhat.com/dledford
Please check my web site for aic7xxx updates/answers before
e-mailing me about problems
-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to [EMAIL PROTECTED]