scsi: scsi_dh_alua: Ensure that alua_activate() calls the completion function
authorBart Van Assche <bart.vanassche@sandisk.com>
Sat, 18 Mar 2017 00:02:02 +0000 (17:02 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 8 Apr 2017 07:30:33 +0000 (09:30 +0200)
commit8f9155989f12aae24bedfcec33f9226beb466574
tree5e0982e10ab16b2e4113479b3aed15de194cf54c
parent68b275b7cbf065a8ea9b964cbb7d78d2b63c635f
scsi: scsi_dh_alua: Ensure that alua_activate() calls the completion function

commit 7cb689fe42927281b8d98606ae5450173fcc66a9 upstream.

Callers of scsi_dh_activate(), e.g. dm-mpath, assume that this function
either returns an error code or calls the completion function. Make
alua_activate() call the completion function even if scsi_device_get()
fails.

Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
Cc: Hannes Reinecke <hare@suse.de>
Cc: Tang Junhui <tang.junhui@zte.com.cn>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/scsi/device_handler/scsi_dh_alua.c