Re: question on block-layer timeout change

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

 



Shi, Harris <Harris.Shi@xxxxxxx> wrote:
>    Due to the current timeout management change, our RDAC (failover) driver
>    had some difficulties in handling SCSI I/O timeout. The RDAC driver is in
>    the similar        layer as HBA driver in that it will register into scsi
>    mid-layer as scsi_host_template and stays below mid-layer. However, all
>    scsi I/Os coming to RDAC stack are routed by a path then dispatched to the
>    real HBA driver via mid-layer. We used to rely on the timer in
>    scsi_cmnd->eh_timeout to deal with scsi i/o coming into the RDAC stack.
>    Basically when I/O is coming to RDAC stack, we need to delete the timer
>    for each I/O. Then after selecting a specific path for this I/O, we need
>    to send the I/O back to mid-layer with a larger timeout value just to
>    avoid the forced failover. When I/O completes successfully, we added the
>    original timer back to the I/O and pass it over to upper block layer for
>    further process.
> 
> 
> 
>    However, with the current timeout management functions moving to block
>    layer, it became difficult for us to explicitly control the timeout value
>    for specific I/O.
> 
>    Can you shed some lights on how to handle the I/O based timeout in this
>    case?
> 

Since long term mpp capabilities should be handled by dm-mp and the SCSI
RDAC handler exporting functions to allow direct adding and deleting of the
timer may not be something that would be needed long term. It may not be
really clean to add these interfaces in.

Could similar prior functionality be created by the following?
	1.) To the RDAC vhba add a hostt->eh_timed_out function. In this
	timeout function return BLK_EH_RESET_TIMER until it is done with
	the command. Since the vhba does not have a transport
	scsi_times_out should call this function on every timeout. There is
	some overhead here depending on the default timeout value set in
	timing out and then resetting the timer.

	2.) For each sdev that is taken over store the previous
	rq_timed_out_fn and then use blk_queue_rq_timed_out to set a mpp
	specific function for the requests sent to the real HBA drivers.

	3.) Set the timeout in the real HBA driver requests prior to
	sending it to the mid layer.

-andmike
--
Michael Anderson
andmike@xxxxxxxxxxxxxxxxxx
--
To unsubscribe from this list: 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