scsi: tcm_fc: use target_remove_session
authorMike Christie <mchristi@redhat.com>
Thu, 2 Aug 2018 17:12:26 +0000 (12:12 -0500)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 2 Aug 2018 19:29:31 +0000 (15:29 -0400)
commit60daca10065a13a133e88b738fdc5a40b3654575
tree87ddff129e542ab625e0ff9f1a536a7ecc09da29
parentb287e3517ed5c76ad48afdfc4f11fadb58a0707e
scsi: tcm_fc: use target_remove_session

This converts tcm_fc to use target_remove_session

tcm_fc was calling transport_deregister_session_configfs then calling
transport_deregister_session when commands have completed. It should be ok
for it to call transport_deregister_session_configfs later via
target_remove_session because transport_deregister_session_configfs only
prevents access from configfs via tpg removal and its call to the
close_session callback for that driver, and this is already protected by
the ft_lport_lock and its port lookup handling.

Signed-off-by: Mike Christie <mchristi@redhat.com>
Reviewed-by: Bart Van Assche <bart.vanassche@wdc.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Cc: Johannes Thumshirn <jth@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/target/tcm_fc/tfc_sess.c