From 9eb69aff79264b5f35e41922df20a488c67e9ee2 Mon Sep 17 00:00:00 2001 From: Maxim Shchetynin Date: Thu, 5 Jan 2006 09:56:47 +0100 Subject: [PATCH] [SCSI] zfcp: handle unsolicited status notification lost Handle unsolicited adapter status that informs about loss of previous unsolicited status notification(s). Signed-off-by: Maxim Shchetynin Signed-off-by: Andreas Herrmann Signed-off-by: James Bottomley --- drivers/s390/scsi/zfcp_fsf.c | 35 +++++++++++++++++++++++++++++++++++ drivers/s390/scsi/zfcp_fsf.h | 12 ++++++++++++ 2 files changed, 47 insertions(+) diff --git a/drivers/s390/scsi/zfcp_fsf.c b/drivers/s390/scsi/zfcp_fsf.c index 59587951c847..bf859c9982df 100644 --- a/drivers/s390/scsi/zfcp_fsf.c +++ b/drivers/s390/scsi/zfcp_fsf.c @@ -964,6 +964,40 @@ zfcp_fsf_status_read_handler(struct zfcp_fsf_req *fsf_req) | ZFCP_STATUS_COMMON_ERP_FAILED); break; + case FSF_STATUS_READ_NOTIFICATION_LOST: + ZFCP_LOG_NORMAL("Unsolicited status notification(s) lost: " + "adapter %s%s%s%s%s%s%s%s%s\n", + zfcp_get_busid_by_adapter(adapter), + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_INCOMING_ELS) ? + ", incoming ELS" : "", + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_SENSE_DATA) ? + ", sense data" : "", + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_LINK_STATUS) ? + ", link status change" : "", + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_PORT_CLOSED) ? + ", port close" : "", + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_BIT_ERROR_THRESHOLD) ? + ", bit error exception" : "", + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_ACT_UPDATED) ? + ", ACT update" : "", + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_ACT_HARDENED) ? + ", ACT hardening" : "", + (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_FEATURE_UPDATE_ALERT) ? + ", adapter feature change" : ""); + + if (status_buffer->status_subtype & + FSF_STATUS_READ_SUB_ACT_UPDATED) + zfcp_erp_adapter_access_changed(adapter); + break; + case FSF_STATUS_READ_CFDC_UPDATED: ZFCP_LOG_NORMAL("CFDC has been updated on the adapter %s\n", zfcp_get_busid_by_adapter(adapter)); @@ -1954,6 +1988,7 @@ zfcp_fsf_exchange_config_data(struct zfcp_erp_action *erp_action) erp_action->fsf_req->qtcb->bottom.config.feature_selection = FSF_FEATURE_CFDC | FSF_FEATURE_LUN_SHARING | + FSF_FEATURE_NOTIFICATION_LOST | FSF_FEATURE_UPDATE_ALERT; /* start QDIO request for this FSF request */ diff --git a/drivers/s390/scsi/zfcp_fsf.h b/drivers/s390/scsi/zfcp_fsf.h index 48719f055952..39475dbcb614 100644 --- a/drivers/s390/scsi/zfcp_fsf.h +++ b/drivers/s390/scsi/zfcp_fsf.h @@ -166,6 +166,7 @@ #define FSF_STATUS_READ_BIT_ERROR_THRESHOLD 0x00000004 #define FSF_STATUS_READ_LINK_DOWN 0x00000005 #define FSF_STATUS_READ_LINK_UP 0x00000006 +#define FSF_STATUS_READ_NOTIFICATION_LOST 0x00000009 #define FSF_STATUS_READ_CFDC_UPDATED 0x0000000A #define FSF_STATUS_READ_CFDC_HARDENED 0x0000000B #define FSF_STATUS_READ_FEATURE_UPDATE_ALERT 0x0000000C @@ -179,6 +180,16 @@ #define FSF_STATUS_READ_SUB_FDISC_FAILED 0x00000001 #define FSF_STATUS_READ_SUB_FIRMWARE_UPDATE 0x00000002 +/* status subtypes for unsolicited status notification lost */ +#define FSF_STATUS_READ_SUB_INCOMING_ELS 0x00000001 +#define FSF_STATUS_READ_SUB_SENSE_DATA 0x00000002 +#define FSF_STATUS_READ_SUB_LINK_STATUS 0x00000004 +#define FSF_STATUS_READ_SUB_PORT_CLOSED 0x00000008 +#define FSF_STATUS_READ_SUB_BIT_ERROR_THRESHOLD 0x00000010 +#define FSF_STATUS_READ_SUB_ACT_UPDATED 0x00000020 +#define FSF_STATUS_READ_SUB_ACT_HARDENED 0x00000040 +#define FSF_STATUS_READ_SUB_FEATURE_UPDATE_ALERT 0x00000080 + /* status subtypes for CFDC */ #define FSF_STATUS_READ_SUB_CFDC_HARDENED_ON_SE 0x00000002 #define FSF_STATUS_READ_SUB_CFDC_HARDENED_ON_SE2 0x0000000F @@ -211,6 +222,7 @@ /* channel features */ #define FSF_FEATURE_CFDC 0x00000002 #define FSF_FEATURE_LUN_SHARING 0x00000004 +#define FSF_FEATURE_NOTIFICATION_LOST 0x00000008 #define FSF_FEATURE_HBAAPI_MANAGEMENT 0x00000010 #define FSF_FEATURE_ELS_CT_CHAINED_SBALS 0x00000020 #define FSF_FEATURE_UPDATE_ALERT 0x00000100 -- 2.30.2