ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_PORT_CLOSED\n"); 
zfcp_fsf_status_read_handler(struct zfcp_fsf_req *fsf_req){	int retval = 0;	struct zfcp_adapter *adapter = fsf_req->adapter;	struct fsf_status_read_buffer *status_buffer =	    fsf_req->data.status_read.buffer;	if (fsf_req->status & ZFCP_STATUS_FSFREQ_DISMISSED) {		mempool_free(status_buffer, adapter->pool.data_status_read);		zfcp_fsf_req_cleanup(fsf_req);		goto out;	}	switch (status_buffer->status_type) {	case FSF_STATUS_READ_PORT_CLOSED:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_PORT_CLOSED\n");		debug_text_event(adapter->erp_dbf, 3, "unsol_pclosed:");		debug_event(adapter->erp_dbf, 3,			    &status_buffer->d_id, sizeof (u32));		zfcp_fsf_status_read_port_closed(fsf_req);		break;	case FSF_STATUS_READ_INCOMING_ELS:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_INCOMING_ELS\n");		debug_text_event(adapter->erp_dbf, 3, "unsol_els:");		zfcp_fsf_incoming_els(fsf_req);		break;	case FSF_STATUS_READ_SENSE_DATA_AVAIL:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_SENSE_DATA_AVAIL\n");		debug_text_event(adapter->erp_dbf, 3, "unsol_sense:");		ZFCP_LOG_INFO("unsolicited sense data received (adapter %s)\n",			      zfcp_get_busid_by_adapter(adapter));                ZFCP_HEX_DUMP(ZFCP_LOG_LEVEL_NORMAL, (char *) status_buffer,                              sizeof(struct fsf_status_read_buffer));		break;	case FSF_STATUS_READ_BIT_ERROR_THRESHOLD:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_BIT_ERROR_THRESHOLD\n");		debug_text_event(adapter->erp_dbf, 3, "unsol_bit_err:");		ZFCP_LOG_NORMAL("Bit error threshold data received:\n");		ZFCP_HEX_DUMP(ZFCP_LOG_LEVEL_NORMAL,			      (char *) status_buffer,			      sizeof (struct fsf_status_read_buffer));		break;	case FSF_STATUS_READ_LINK_DOWN:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_LINK_DOWN\n");		debug_text_event(adapter->erp_dbf, 0, "unsol_link_down:");		ZFCP_LOG_INFO("Local link to adapter %s is down\n",			      zfcp_get_busid_by_adapter(adapter));		atomic_set_mask(ZFCP_STATUS_ADAPTER_LINK_UNPLUGGED,				&adapter->status);		zfcp_erp_adapter_failed(adapter);		break;	case FSF_STATUS_READ_LINK_UP:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_LINK_UP\n");		debug_text_event(adapter->erp_dbf, 2, "unsol_link_up:");		ZFCP_LOG_INFO("Local link to adapter %s was replugged. "			      "Restarting operations on this adapter\n",			      zfcp_get_busid_by_adapter(adapter));		/* All ports should be marked as ready to run again */		zfcp_erp_modify_adapter_status(adapter,					       ZFCP_STATUS_COMMON_RUNNING,					       ZFCP_SET);		zfcp_erp_adapter_reopen(adapter,					ZFCP_STATUS_ADAPTER_LINK_UNPLUGGED					| ZFCP_STATUS_COMMON_ERP_FAILED);		break;	case FSF_STATUS_READ_CFDC_UPDATED:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_CFDC_UPDATED\n");		debug_text_event(adapter->erp_dbf, 2, "unsol_cfdc_update:");		ZFCP_LOG_INFO("CFDC has been updated on the adapter %s\n",			      zfcp_get_busid_by_adapter(adapter));		zfcp_erp_adapter_access_changed(adapter);		break;	case FSF_STATUS_READ_CFDC_HARDENED:		ZFCP_LOG_FLAGS(1, "FSF_STATUS_READ_CFDC_HARDENED\n");		debug_text_event(adapter->erp_dbf, 2, "unsol_cfdc_harden:");		switch (status_buffer->status_subtype) {		case FSF_STATUS_READ_SUB_CFDC_HARDENED_ON_SE:			ZFCP_LOG_INFO("CFDC of adapter %s saved on SE\n",				      zfcp_get_busid_by_adapter(adapter));			break;		case FSF_STATUS_READ_SUB_CFDC_HARDENED_ON_SE2:			ZFCP_LOG_INFO("CFDC of adapter %s has been copied "				      "to the secondary SE\n",				zfcp_get_busid_by_adapter(adapter));			break;		default:			ZFCP_LOG_INFO("CFDC of adapter %s has been hardened\n",				      zfcp_get_busid_by_adapter(adapter));		}		break;	default:		debug_text_event(adapter->erp_dbf, 0, "unsol_unknown:");		debug_exception(adapter->erp_dbf, 0,				&status_buffer->status_type, sizeof (u32));		ZFCP_LOG_NORMAL("bug: An unsolicited status packet of unknown "				"type was received (debug info 0x%x)\n",				status_buffer->status_type);		ZFCP_LOG_DEBUG("Dump of status_read_buffer %p:\n",			       status_buffer);		ZFCP_HEX_DUMP(ZFCP_LOG_LEVEL_DEBUG,			      (char *) status_buffer,			      sizeof (struct fsf_status_read_buffer));		break;	}	mempool_free(status_buffer, adapter->pool.data_status_read);	zfcp_fsf_req_cleanup(fsf_req);	/*	 * recycle buffer and start new request repeat until outbound	 * queue is empty or adapter shutdown is requested	 */	/*	 * FIXME(qdio):	 * we may wait in the req_create for 5s during shutdown, so	 * qdio_cleanup will have to wait at least that long before returning	 * with failure to allow us a proper cleanup under all circumstances	 */	/*	 * FIXME:	 * allocation failure possible? (Is this code needed?)	 */	retval = zfcp_fsf_status_read(adapter, 0);	if (retval < 0) {		ZFCP_LOG_INFO("Failed to create unsolicited status read "			      "request for the adapter %s.\n",			      zfcp_get_busid_by_adapter(adapter));		/* temporary fix to avoid status read buffer shortage */		adapter->status_read_failed++;		if ((ZFCP_STATUS_READS_RECOM - adapter->status_read_failed)		    < ZFCP_STATUS_READ_FAILED_THRESHOLD) {			ZFCP_LOG_INFO("restart adapter %s due to status read "				      "buffer shortage\n",				      zfcp_get_busid_by_adapter(adapter));			zfcp_erp_adapter_reopen(adapter, 0);		}	} out:	return retval;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/6bc9dace767f1fffdf975b3398b3c4e37cd5ae18/zfcp_fsf.c/clean/drivers/s390/scsi/zfcp_fsf.c