Skip to content

Commit 8b3bdd9

Browse files
steffen-maiermartinkpetersen
authored andcommitted
scsi: zfcp: Report port fc_security as unknown early during remote cable pull
On remote cable pull, a zfcp_port keeps its status and only gets ZFCP_STATUS_PORT_LINK_TEST added. Only after an ADISC timeout, we would actually start port recovery and remove ZFCP_STATUS_COMMON_UNBLOCKED which zfcp_sysfs_port_fc_security_show() detected and reported as "unknown" instead of the old and possibly stale zfcp_port->connection_info. Add check for ZFCP_STATUS_PORT_LINK_TEST for timely "unknown" report. Link: https://lore.kernel.org/r/[email protected] Fixes: a17c784 ("scsi: zfcp: report FC Endpoint Security in sysfs") Cc: <[email protected]> Rust-for-Linux#5.7+ Reviewed-by: Benjamin Block <[email protected]> Signed-off-by: Steffen Maier <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent 93aa71a commit 8b3bdd9

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/s390/scsi/zfcp_sysfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -487,6 +487,7 @@ static ssize_t zfcp_sysfs_port_fc_security_show(struct device *dev,
487487
if (0 == (status & ZFCP_STATUS_COMMON_OPEN) ||
488488
0 == (status & ZFCP_STATUS_COMMON_UNBLOCKED) ||
489489
0 == (status & ZFCP_STATUS_PORT_PHYS_OPEN) ||
490+
0 != (status & ZFCP_STATUS_PORT_LINK_TEST) ||
490491
0 != (status & ZFCP_STATUS_COMMON_ERP_FAILED) ||
491492
0 != (status & ZFCP_STATUS_COMMON_ACCESS_BOXED))
492493
i = sprintf(buf, "unknown\n");

0 commit comments

Comments
 (0)