Re: [PATCH v4 33/37] target: Inline transport_lun_remove_cmd()

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

 



On Thu, 2017-02-09 at 03:28 -0800, Nicholas A. Bellinger wrote:
> As-is, this patch breaks active I/O configfs shutdown of
> /sys/kernel/config/target/$FABRIC/$WWN/$TPGT/lun/$LUN_ID/$DEV_SYMLINK.
> 
> The reason why cmd->se_lun->lun_ref is dropped, and se_cmd->se_lun is
> cleared before the response hand-off back to the fabric driver is so
> that ../$WWN/$TPGT/lun/$LUN_ID/ shutdown can occur from configfs,
> without having to wait for se_cmd->cmd_kref to reach zero.
> 
> Depending on initiator fabric ACKs coming back to drop the last
> se_cmd->cmd_kref in order to release se_lun->lun_ref once user has
> explicitly requested ../$WWN/$TPGT/lun/$LUN_ID doesn't work in practice
> for a scale-out distributed use-case.
> 
> This must be able to happen asychronously from the fabric ACK.

There can only be a delay between the last kref_put() call from the target
driver and the final kref_put() if a task management function is being
processed or a session is being shut down. The time needed to process any
of these actions is finite so shutdown of a target driver while I/O is in
progress still works.

Bart.--
To unsubscribe from this list: send the line "unsubscribe target-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux SCSI]     [Kernel Newbies]     [Linux SCSI Target Infrastructure]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Device Mapper]

  Powered by Linux