Re: [PATCH 4/5] convert st to use scsi_execte_async

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kai Makisara wrote:

st sends the command using a buffer of one segment. The command is passed to the HBA driver and it sees 8 segments. Clustering seems to work properly (the maximum segment size is set to 65536 bytes by default).
Here is what is seen when the block size is increased to 513 kB:
dd if=tdata of=/dev/nst0 bs=513k count=1

The dd process hangs in device wait. It turns out that scsi_execute_async() fails. This is an async write and the process later waits for the failed write to finish. The patch at the end of this message fixes this st bug (don't worry about the line shifts, I have some debugging printks in this driver).

The real problem is that scsi_execute_async() fails. The 513 kB request is 129 pages. Could the reason be related to these defaults in include/linux?
#define MAX_PHYS_SEGMENTS 128
#define MAX_HW_SEGMENTS 128


Yeah I think this is due to the MAX_PHYS_SEGMENTS limit. The hw segments is set by scsi_lib in scsi_alloc_queue and is the sg_tablesize value on the host. Right now all I do is return a error when someone violates one of the limits, but I think the right thing to do is have the ULDs take some of these values into account when they build their lists. However if I do that we will not be able to make large requests since the MAX_PHYS_SEGMENTS/SCSI_MAX_PHYS_SEGMENTS will limit them. Umm let me rethink.
-
: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux