svn commit: r365186 - head/sys/dev/ocs_fc

Mateusz Guzik mjg at FreeBSD.org
Tue Sep 1 22:02:16 UTC 2020


Author: mjg
Date: Tue Sep  1 22:02:12 2020
New Revision: 365186
URL: https://svnweb.freebsd.org/changeset/base/365186

Log:
  ocs_fc: clean up empty lines in .c and .h files

Modified:
  head/sys/dev/ocs_fc/ocs.h
  head/sys/dev/ocs_fc/ocs_cam.c
  head/sys/dev/ocs_fc/ocs_cam.h
  head/sys/dev/ocs_fc/ocs_common.h
  head/sys/dev/ocs_fc/ocs_ddump.c
  head/sys/dev/ocs_fc/ocs_device.c
  head/sys/dev/ocs_fc/ocs_device.h
  head/sys/dev/ocs_fc/ocs_domain.c
  head/sys/dev/ocs_fc/ocs_drv_fc.h
  head/sys/dev/ocs_fc/ocs_els.c
  head/sys/dev/ocs_fc/ocs_fabric.c
  head/sys/dev/ocs_fc/ocs_fabric.h
  head/sys/dev/ocs_fc/ocs_fcp.h
  head/sys/dev/ocs_fc/ocs_hw.c
  head/sys/dev/ocs_fc/ocs_hw.h
  head/sys/dev/ocs_fc/ocs_hw_queues.c
  head/sys/dev/ocs_fc/ocs_hw_queues.h
  head/sys/dev/ocs_fc/ocs_io.c
  head/sys/dev/ocs_fc/ocs_io.h
  head/sys/dev/ocs_fc/ocs_ioctl.c
  head/sys/dev/ocs_fc/ocs_ioctl.h
  head/sys/dev/ocs_fc/ocs_list.h
  head/sys/dev/ocs_fc/ocs_mgmt.c
  head/sys/dev/ocs_fc/ocs_mgmt.h
  head/sys/dev/ocs_fc/ocs_node.c
  head/sys/dev/ocs_fc/ocs_node.h
  head/sys/dev/ocs_fc/ocs_os.c
  head/sys/dev/ocs_fc/ocs_os.h
  head/sys/dev/ocs_fc/ocs_pci.c
  head/sys/dev/ocs_fc/ocs_scsi.c
  head/sys/dev/ocs_fc/ocs_scsi.h
  head/sys/dev/ocs_fc/ocs_sport.c
  head/sys/dev/ocs_fc/ocs_sport.h
  head/sys/dev/ocs_fc/ocs_stats.h
  head/sys/dev/ocs_fc/ocs_unsol.c
  head/sys/dev/ocs_fc/ocs_utils.c
  head/sys/dev/ocs_fc/ocs_utils.h
  head/sys/dev/ocs_fc/ocs_vpd.h
  head/sys/dev/ocs_fc/ocs_xport.c
  head/sys/dev/ocs_fc/ocs_xport.h
  head/sys/dev/ocs_fc/sli4.c
  head/sys/dev/ocs_fc/sli4.h

Modified: head/sys/dev/ocs_fc/ocs.h
==============================================================================
--- head/sys/dev/ocs_fc/ocs.h	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs.h	Tue Sep  1 22:02:12 2020	(r365186)
@@ -36,7 +36,6 @@
  * OCS bsd driver common include file
  */
 
-
 #if !defined(__OCS_H__)
 #define __OCS_H__
 
@@ -103,7 +102,6 @@ typedef struct ocs_fcport_s {
  */
 
 struct ocs_softc {
-
 	device_t		dev;
 	struct cdev		*cdev;
 
@@ -197,7 +195,6 @@ struct ocs_softc {
 	uint32_t		config_tgt:1,	/**< Configured to support target mode */
 				config_ini:1;	/**< Configured to support initiator mode */
 
-
 	uint32_t nodedb_mask;			/**< Node debugging mask */
 
 	char			modeldesc[64];
@@ -218,7 +215,7 @@ struct ocs_softc {
 
 	bool			attached;
 	struct mtx		dbg_lock;
-	
+
 	struct cam_devq		*devq;
 	ocs_fcport		*fcports;
 

Modified: head/sys/dev/ocs_fc/ocs_cam.c
==============================================================================
--- head/sys/dev/ocs_fc/ocs_cam.c	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_cam.c	Tue Sep  1 22:02:12 2020	(r365186)
@@ -132,7 +132,7 @@ ocs_attach_port(ocs_t *ocs, int chan)
 		cam_sim_free(sim, FALSE);
 		return 1;
 	}
-	
+
 	fcp->ocs = ocs;
 	fcp->sim  = sim;
 	fcp->path = path;
@@ -171,7 +171,7 @@ ocs_detach_port(ocs_t *ocs, int32_t chan)
 			fcp->sim = NULL;
 		mtx_unlock(&ocs->sim_lock);
 	}
-	
+
 	return 0;
 }
 
@@ -199,7 +199,7 @@ ocs_cam_attach(ocs_t *ocs)
 			goto detach_port;
 		}
 	}
-	
+
 	ocs->io_high_watermark = max_io;
 	ocs->io_in_use = 0;
 	return 0;
@@ -323,7 +323,6 @@ ocs_scsi_tgt_del_domain(ocs_domain_t *domain)
 {
 }
 
-
 /**
  * @ingroup scsi_api_target
  * @brief accept new sli port (sport) notification
@@ -493,7 +492,6 @@ ocs_scsi_del_initiator(ocs_node_t *node, ocs_scsi_del_
 	adc->arrived = 0;
 	xpt_async(AC_CONTRACT, fcp->path, &ac);
 
-
 	if (reason == OCS_SCSI_INITIATOR_MISSING) {
 		return OCS_SCSI_CALL_COMPLETE;
 	}
@@ -566,7 +564,6 @@ int32_t ocs_scsi_recv_cmd(ocs_io_t *io, uint64_t lun, 
 	}
 
 	if (atio) {
-
 		STAILQ_REMOVE_HEAD(&trsrc->atio, sim_links.stqe);
 
 		atio->ccb_h.status = CAM_CDB_RECVD;
@@ -699,7 +696,6 @@ int32_t ocs_scsi_recv_tmf(ocs_io_t *tmfio, uint64_t lu
 		goto ocs_scsi_recv_tmf_out;
 	}
 
-
 	tmfio->tgt_io.app = abortio;
 
 	STAILQ_REMOVE_HEAD(&trsrc->inot, sim_links.stqe);
@@ -773,7 +769,7 @@ int32_t ocs_scsi_recv_tmf(ocs_io_t *tmfio, uint64_t lu
 		abortio->tgt_io.flags |= OCS_CAM_IO_F_ABORT_DEV;
 		rc = ocs_scsi_tgt_abort_io(abortio, ocs_io_abort_cb, tmfio);
 	}
-	
+
 ocs_scsi_recv_tmf_out:
 	return rc;
 }
@@ -813,7 +809,6 @@ ocs_scsi_ini_del_device(ocs_t *ocs)
 	return 0;
 }
 
-
 /**
  * @ingroup scsi_api_initiator
  * @brief accept new domain notification
@@ -959,7 +954,7 @@ ocs_tgt_find(ocs_fcport *fcp, ocs_node_t *node)
 {
 	ocs_fc_target_t *tgt = NULL;
 	uint32_t i;
-	
+
 	for (i = 0; i < OCS_MAX_TARGETS; i++) {
 		tgt = &fcp->tgt[i];
 
@@ -970,7 +965,7 @@ ocs_tgt_find(ocs_fcport *fcp, ocs_node_t *node)
 			return i;
 		}
 	}
-	
+
 	return -1;
 }
 
@@ -996,12 +991,12 @@ uint32_t
 ocs_update_tgt(ocs_node_t *node, ocs_fcport *fcp, uint32_t tgt_id)
 {
 	ocs_fc_target_t *tgt = NULL;
-	
+
 	tgt = &fcp->tgt[tgt_id];
 
 	tgt->node_id = node->instance_index;
 	tgt->state = OCS_TGT_STATE_VALID;
-	
+
 	tgt->port_id = node->rnode.fc_id;
 	tgt->wwpn = ocs_node_get_wwpn(node);
 	tgt->wwnn = ocs_node_get_wwnn(node);
@@ -1052,7 +1047,7 @@ ocs_scsi_new_target(ocs_node_t *node)
 	}
 
 	i = ocs_tgt_find(fcp, node);
-	
+
 	if (i < 0) {
 		ocs_add_new_tgt(node, fcp);
 		return 0;
@@ -1071,7 +1066,7 @@ ocs_delete_target(ocs_t *ocs, ocs_fcport *fcp, int tgt
 		device_printf(ocs->dev, "%s: calling with NULL sim\n", __func__); 
 		return;
 	}
-	
+
 	if (CAM_REQ_CMP == xpt_create_path(&cpath, NULL, cam_sim_path(fcp->sim),
 				tgt, CAM_LUN_WILDCARD)) {
 		xpt_async(AC_LOST_DEVICE, cpath, NULL);
@@ -1189,14 +1184,13 @@ ocs_scsi_del_target(ocs_node_t *node, ocs_scsi_del_tar
 	if(!ocs->attached) {
 		ocs_delete_target(ocs, fcp, tgt_id);
 	} else {
-	
 		tgt->state = OCS_TGT_STATE_LOST;
 		tgt->gone_timer = 30;
 		if (!callout_active(&fcp->ldt)) {
 			callout_reset(&fcp->ldt, hz, ocs_ldt, fcp);
 		}
 	}
-	
+
 	return 0;
 }
 
@@ -1742,7 +1736,6 @@ ocs_target_io(struct ocs_softc *ocs, union ccb *ccb)
 					" are 0 \n", __func__);
 		ocs_set_ccb_status(ccb, CAM_REQ_INVALID);
 		rc = 1;
-
 	}
 
 	if (rc) {
@@ -1917,7 +1910,7 @@ ocs_fcp_change_role(struct ocs_softc *ocs, ocs_fcport 
 		
 		return 0;
 	}
-	
+
 	if ((fcp->role != KNOB_ROLE_NONE)){
 		fcp->role = new_role;
 		vport->enable_ini = (new_role & KNOB_ROLE_INITIATOR)? 1:0;
@@ -1927,7 +1920,7 @@ ocs_fcp_change_role(struct ocs_softc *ocs, ocs_fcport 
 	}
 
 	fcp->role = new_role;
-	
+
 	vport->enable_ini = (new_role & KNOB_ROLE_INITIATOR)? 1:0;
 	vport->enable_tgt = (new_role & KNOB_ROLE_TARGET)? 1:0;
 
@@ -2617,7 +2610,7 @@ ocs_abort_atio(struct ocs_softc *ocs, union ccb *ccb)
 	aio->tgt_io.flags |= OCS_CAM_IO_F_ABORT_CAM;
 	ocs_target_io_free(aio);
 	ocs_set_ccb_status(ccb, CAM_REQ_CMP);
-	
+
 	return;
 }
 
@@ -2808,7 +2801,7 @@ ocs_get_crn(ocs_node_t *node, uint8_t *crn, uint64_t l
 	if (lcrn->lun != lun) {
 		return (1);
 	}	
-	
+
 	if (lcrn->crnseed == 0)
 		lcrn->crnseed = 1;
 
@@ -2821,7 +2814,7 @@ ocs_del_crn(ocs_node_t *node)
 {
 	uint32_t i;
 	struct ocs_lun_crn *lcrn = NULL;
-	
+
 	for(i = 0; i < OCS_MAX_LUN; i++) {
 		lcrn = node->ini_node.lun_crn[i];
 		if (lcrn) {

Modified: head/sys/dev/ocs_fc/ocs_cam.h
==============================================================================
--- head/sys/dev/ocs_fc/ocs_cam.h	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_cam.h	Tue Sep  1 22:02:12 2020	(r365186)
@@ -42,7 +42,6 @@
 
 #include <cam/scsi/scsi_message.h>
 
-
 #define ccb_ocs_ptr     spriv_ptr0
 #define ccb_io_ptr      spriv_ptr1
 
@@ -119,4 +118,3 @@ extern int32_t ocs_cam_attach(ocs_t *ocs);
 extern int32_t ocs_cam_detach(ocs_t *ocs);
 
 #endif /* __OCS_CAM_H__ */
-

Modified: head/sys/dev/ocs_fc/ocs_common.h
==============================================================================
--- head/sys/dev/ocs_fc/ocs_common.h	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_common.h	Tue Sep  1 22:02:12 2020	(r365186)
@@ -36,7 +36,6 @@
  * Contains declarations shared between the alex layer and HW/SLI4
  */
 
-
 #if !defined(__OCS_COMMON_H__)
 #define __OCS_COMMON_H__
 
@@ -154,7 +153,6 @@ typedef enum {
  * a separate SLI port object.
  */
 struct ocs_sli_port_s {
-
 	ocs_t *ocs;				/**< pointer to ocs */
 	uint32_t tgt_id;			/**< target id */
 	uint32_t index;				/**< ??? */
@@ -215,7 +213,6 @@ struct ocs_sli_port_s {
  * to connect to the domain of a FC or FCoE switch
  */
 struct ocs_domain_s {
-
 	ocs_t *ocs;				/**< pointer back to ocs */
 	uint32_t instance_index;		/**< unique instance index value */
 	char display_name[OCS_DISPLAY_NAME_LENGTH]; /**< Node display name */
@@ -302,7 +299,6 @@ struct ocs_remote_node_group_s {
 	 * Implementation specific fields allowed here
 	 */
 
-
 	uint32_t instance_index;		/*<< instance index */
 	ocs_node_group_dir_t *node_group_dir;	/*<< pointer to the node group directory */
 	ocs_list_link_t link;			/*<< linked list link */
@@ -325,7 +321,6 @@ typedef enum {
  *
  */
 struct ocs_node_s {
-
 	ocs_t *ocs;				/**< pointer back to ocs structure */
 	uint32_t instance_index;		/**< unique instance index value */
 	char display_name[OCS_DISPLAY_NAME_LENGTH]; /**< Node display name */
@@ -419,6 +414,5 @@ struct ocs_vport_spec_s {
 	void	*ini_data;			/**< initiator backend pointer */
 	ocs_sport_t *sport;			/**< Used to match record after attaching for update */
 };
-
 
 #endif /* __OCS_COMMON_H__*/

Modified: head/sys/dev/ocs_fc/ocs_ddump.c
==============================================================================
--- head/sys/dev/ocs_fc/ocs_ddump.c	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_ddump.c	Tue Sep  1 22:02:12 2020	(r365186)
@@ -118,7 +118,6 @@ ocs_ddump_sli4_queue(ocs_textbuf_t *textbuf, const cha
 	}
 }
 
-
 /**
  * @brief Generate SLI4 ddump
  *
@@ -153,7 +152,6 @@ ocs_ddump_sli_q_fields(ocs_textbuf_t *textbuf, sli4_t 
 	ocs_ddump_endsection(textbuf, q_desc, qtype);
 }
 
-
 /**
  * @brief Generate SLI4 ddump
  *
@@ -259,7 +257,6 @@ ocs_ddump_sli(ocs_textbuf_t *textbuf, sli4_t *sli4)
 	ocs_ddump_endsection(textbuf, "sli4", 0);
 }
 
-
 /**
  * @brief Dump HW IO
  *
@@ -334,7 +331,6 @@ ocs_ddump_queue_history(ocs_textbuf_t *textbuf, ocs_hw
 		ocs_q_hist_ftr_t ftr;
 		uint32_t mask;
 
-
 		/* footer's mask indicates what words were captured */
 		ftr.word = q_hist->q_hist[x];
 		mask = ftr.s.mask;
@@ -878,4 +874,3 @@ ocs_clear_saved_ddump(ocs_t *ocs)
 		return 1;
 	}
 }
-

Modified: head/sys/dev/ocs_fc/ocs_device.c
==============================================================================
--- head/sys/dev/ocs_fc/ocs_device.c	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_device.c	Tue Sep  1 22:02:12 2020	(r365186)
@@ -246,7 +246,6 @@ __ocs_d_common(const char *funcname, ocs_sm_ctx_t *ctx
 	ocs_assert(ocs, NULL);
 
 	switch(evt) {
-
 	/* Handle shutdown events */
 	case OCS_EVT_SHUTDOWN:
 		ocs_log_debug(ocs, "[%s] %-20s %-20s\n", node->display_name, funcname, ocs_sm_event_name(evt));
@@ -315,9 +314,6 @@ __ocs_d_wait_loop(ocs_sm_ctx_t *ctx, ocs_sm_event_t ev
 	return NULL;
 }
 
-
-
-
 /**
  * @ingroup device_sm
  * @brief state: wait for node resume event
@@ -384,7 +380,6 @@ __ocs_d_wait_del_ini_tgt(ocs_sm_ctx_t *ctx, ocs_sm_eve
 	return NULL;
 }
 
-
 /**
  * @ingroup device_sm
  * @brief state: Wait for node resume event.
@@ -455,8 +450,6 @@ __ocs_d_wait_del_node(ocs_sm_ctx_t *ctx, ocs_sm_event_
 	return NULL;
 }
 
-
-
 /**
  * @brief Save the OX_ID for sending LS_ACC sometime later.
  *
@@ -535,7 +528,6 @@ ocs_process_abts(ocs_io_t *io, fc_header_t *hdr)
 
 	/* If an IO was found, attempt to take a reference on it */
 	if (abortio != NULL && (ocs_ref_get_unless_zero(&abortio->ref) != 0)) {
-
 		/* Got a reference on the IO. Hold it until backend is notified below */
 		node_printf(node, "Abort request: ox_id [%04x] rx_id [%04x]\n",
 			    ox_id, rx_id);
@@ -677,7 +669,6 @@ __ocs_d_wait_logo_rsp(ocs_sm_ctx_t *ctx, ocs_sm_event_
 	return NULL;
 }
 
-
 /**
  * @ingroup device_sm
  * @brief Device node state machine: Wait for the PRLO response.
@@ -724,7 +715,6 @@ __ocs_d_wait_prlo_rsp(ocs_sm_ctx_t *ctx, ocs_sm_event_
 	return NULL;
 }
 
-
 /**
  * @brief Initialize device node.
  *
@@ -1654,13 +1644,12 @@ __ocs_d_device_ready(ocs_sm_ctx_t *ctx, ocs_sm_event_t
 		break;
 	}
 
-
 	case OCS_EVT_PDISC_RCVD: {
 		fc_header_t *hdr = cbdata->header->dma.virt;
 		ocs_send_plogi_acc(cbdata->io, ocs_be16toh(hdr->ox_id), NULL, NULL);
 		break;
 	}
-	
+
 	case OCS_EVT_PRLI_RCVD: {
 		/* T, I+T: remote initiator is slow to get started */
 		fc_header_t *hdr = cbdata->header->dma.virt;
@@ -1808,7 +1797,6 @@ __ocs_d_device_gone(ocs_sm_ctx_t *ctx, ocs_sm_event_t 
 		default:
 			rc = OCS_SCSI_CALL_COMPLETE;
 			break;
-
 		}
 
 		if ((rc == OCS_SCSI_CALL_COMPLETE) && (rc_2 == OCS_SCSI_CALL_COMPLETE)) {

Modified: head/sys/dev/ocs_fc/ocs_device.h
==============================================================================
--- head/sys/dev/ocs_fc/ocs_device.h	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_device.h	Tue Sep  1 22:02:12 2020	(r365186)
@@ -47,7 +47,6 @@
 #define OCS_FC_RQ_SIZE_DEFAULT			1024
 #endif
 
-
 /***************************************************************************
  * IO Configuration
  */
@@ -58,7 +57,6 @@
 #ifndef OCS_FC_MAX_SGL
 #define OCS_FC_MAX_SGL		128
 #endif
-
 
 /***************************************************************************
  * DIF Configuration

Modified: head/sys/dev/ocs_fc/ocs_domain.c
==============================================================================
--- head/sys/dev/ocs_fc/ocs_domain.c	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_domain.c	Tue Sep  1 22:02:12 2020	(r365186)
@@ -77,8 +77,6 @@ static ocs_mgmt_functions_t domain_mgmt_functions = {
 	.exec_handler = ocs_mgmt_domain_exec,
 };
 
-
-
 /**
  * @brief Accept domain callback events from the HW.
  *
@@ -174,7 +172,6 @@ ocs_domain_cb(void *arg, ocs_hw_domain_event_e event, 
 	return rc;
 }
 
-
 /**
  * @brief Find the domain, given its FCF_WWN.
  *
@@ -225,7 +222,6 @@ ocs_domain_alloc(ocs_t *ocs, uint64_t fcf_wwn)
 
 	domain = ocs_malloc(ocs, sizeof(*domain), OCS_M_NOWAIT | OCS_M_ZERO);
 	if (domain) {
-
 		domain->ocs = ocs;
 		domain->instance_index = ocs->domain_instance_count++;
 		domain->drvsm.app = domain;
@@ -258,7 +254,6 @@ ocs_domain_alloc(ocs_t *ocs, uint64_t fcf_wwn)
 		ocs_log_err(ocs, "domain allocation failed\n");
 	}
 
-
 	return domain;
 }
 
@@ -962,7 +957,6 @@ __ocs_domain_ready(ocs_sm_ctx_t *ctx, ocs_sm_event_t e
 
 	switch(evt) {
 	case OCS_EVT_ENTER: {
-
 		/* start any pending vports */
 		if (ocs_vport_start(domain)) {
 			ocs_log_debug(domain->ocs, "ocs_vport_start() did not start all vports\n");
@@ -1197,8 +1191,6 @@ __ocs_domain_wait_domain_lost(ocs_sm_ctx_t *ctx, ocs_s
 	return NULL;
 }
 
-
-
 /**
  * @brief Save the port's service parameters.
  *
@@ -1282,7 +1274,6 @@ ocs_domain_post_event(ocs_domain_t *domain, ocs_sm_eve
 	return rc;
 }
 
-
 /**
  * @brief Return the WWN as a uint64_t.
  *
@@ -1367,7 +1358,6 @@ ocs_ddump_domain(ocs_textbuf_t *textbuf, ocs_domain_t 
 	return retval;
 }
 
-
 void
 ocs_mgmt_domain_list(ocs_textbuf_t *textbuf, void *object)
 {
@@ -1390,8 +1380,6 @@ ocs_mgmt_domain_list(ocs_textbuf_t *textbuf, void *obj
 #endif
 
 	if (ocs_domain_lock_try(domain) == TRUE) {
-
-
 		/* If we get here, then we are holding the domain lock */
 		ocs_list_foreach(&domain->sport_list, sport) {
 			if ((sport->mgmt_functions) && (sport->mgmt_functions->get_list_handler)) {
@@ -1468,7 +1456,6 @@ ocs_mgmt_domain_get(ocs_textbuf_t *textbuf, char *pare
 				if (retval == 0) {
 					break;
 				}
-
 			}
 			ocs_domain_unlock(domain);
 		}
@@ -1507,7 +1494,6 @@ ocs_mgmt_domain_get_all(ocs_textbuf_t *textbuf, void *
 	}
 	ocs_domain_unlock(domain);
 
-
 	ocs_mgmt_end_unnumbered_section(textbuf, "domain");
 
 }
@@ -1524,11 +1510,9 @@ ocs_mgmt_domain_set(char *parent, char *name, char *va
 
 	/* If it doesn't start with my qualifier I don't know what to do with it */
 	if (ocs_strncmp(name, qualifier, strlen(qualifier)) == 0) {
-
 		/* See if it's a value I can supply */
 
 		/* if (ocs_strcmp(unqualified_name, "display_name") == 0) {
-
 		} else */
 		{
 			/* If I didn't know the value of this status pass the request to each of my children */
@@ -1541,7 +1525,6 @@ ocs_mgmt_domain_set(char *parent, char *name, char *va
 				if (retval == 0) {
 					break;
 				}
-
 			}
 			ocs_domain_unlock(domain);
 		}
@@ -1563,7 +1546,6 @@ ocs_mgmt_domain_exec(char *parent, char *action, void 
 
 	/* If it doesn't start with my qualifier I don't know what to do with it */
 	if (ocs_strncmp(action, qualifier, strlen(qualifier)) == 0) {
-
 		{
 			/* If I didn't know how to do this action pass the request to each of my children */
 			ocs_domain_lock(domain);
@@ -1575,7 +1557,6 @@ ocs_mgmt_domain_exec(char *parent, char *action, void 
 				if (retval == 0) {
 					break;
 				}
-
 			}
 			ocs_domain_unlock(domain);
 		}

Modified: head/sys/dev/ocs_fc/ocs_drv_fc.h
==============================================================================
--- head/sys/dev/ocs_fc/ocs_drv_fc.h	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_drv_fc.h	Tue Sep  1 22:02:12 2020	(r365186)
@@ -36,7 +36,6 @@
  * OCS linux driver common include file
  */
 
-
 #if !defined(__OCS_DRV_FC_H__)
 #define __OCS_DRV_FC_H__
 
@@ -52,7 +51,6 @@
 #include "ocs_stats.h"
 
 struct ocs_s {
-
 	ocs_os_t ocs_os;
 	char display_name[OCS_DISPLAY_NAME_LENGTH];
 	ocs_rlock_t lock;			/*>> Device wide lock */
@@ -207,6 +205,5 @@ extern int32_t ocs_start_event_processing(ocs_os_t *oc
 
 #include "ocs_ioctl.h"
 #include "ocs_elxu.h"
-
 
 #endif 

Modified: head/sys/dev/ocs_fc/ocs_els.c
==============================================================================
--- head/sys/dev/ocs_fc/ocs_els.c	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_els.c	Tue Sep  1 22:02:12 2020	(r365186)
@@ -68,7 +68,6 @@ static ocs_io_t *ocs_els_abort_io(ocs_io_t *els, int s
 static void _ocs_els_io_free(void *arg);
 static void ocs_els_delay_timer_cb(void *arg);
 
-
 /**
  * @ingroup els_api
  * @brief ELS state machine transition wrapper.
@@ -355,7 +354,6 @@ ocs_els_make_active(ocs_io_t *els)
 				ocs_unlock(&node->active_ios_lock);
 				return;
 			} else {
-
 				/* remove from pending list */
 				ocs_list_remove(&node->els_io_pend_list, els);
 				els->els_pend = 0;
@@ -506,7 +504,6 @@ ocs_els_req_cb(ocs_hw_io_t *hio, ocs_remote_node_t *rn
 		ocs_els_post_event(els, OCS_EVT_SRRS_ELS_REQ_RJT, &cbdata);
 		break;
 
-
 	case SLI4_FC_WCQE_STATUS_LOCAL_REJECT:
 		switch (ext_status) {
 		case SLI4_FC_LOCAL_REJECT_SEQUENCE_TIMEOUT:
@@ -647,7 +644,6 @@ ocs_send_plogi(ocs_node_t *node, uint32_t timeout_sec,
 		els->iparam.els.timeout = timeout_sec;
 
 		ocs_io_transition(els, __ocs_els_init, NULL);
-
 	}
 	return els;
 }
@@ -909,7 +905,6 @@ ocs_send_logo(ocs_node_t *node, uint32_t timeout_sec, 
 	fc_logo_payload_t *logo;
 	fc_plogi_payload_t *sparams;
 
-
 	ocs = node->ocs;
 
 	node_els_trace();
@@ -1305,7 +1300,7 @@ ocs_send_plogi_acc(ocs_io_t *io, uint32_t ox_id, els_c
 	ocs_memcpy(plogi, node->sport->service_params, sizeof(*plogi));
 	plogi->command_code = FC_ELS_CMD_ACC;
 	plogi->resv1 = 0;
-	
+
 	/* Set Application header support bit if requested */
 	if (req->common_service_parameters[1] & ocs_htobe32(1U << 24)) {
 		plogi->common_service_parameters[1] |= ocs_htobe32(1U << 24);
@@ -1724,7 +1719,6 @@ ocs_ns_send_rftid(ocs_node_t *node, uint32_t timeout_s
 	if (els == NULL) {
 		ocs_log_err(ocs, "IO alloc failed\n");
 	} else {
-
 		els->iparam.fc_ct.r_ctl = FC_RCTL_ELS;
 		els->iparam.fc_ct.type = FC_TYPE_GS;
 		els->iparam.fc_ct.df_ctl = 0;
@@ -1777,7 +1771,6 @@ ocs_ns_send_rffid(ocs_node_t *node, uint32_t timeout_s
 	if (els == NULL) {
 		ocs_log_err(ocs, "IO alloc failed\n");
 	} else {
-
 		els->iparam.fc_ct.r_ctl = FC_RCTL_ELS;
 		els->iparam.fc_ct.type = FC_TYPE_GS;
 		els->iparam.fc_ct.df_ctl = 0;
@@ -1808,7 +1801,6 @@ ocs_ns_send_rffid(ocs_node_t *node, uint32_t timeout_s
 	return els;
 }
 
-
 /**
  * @ingroup els_api
  * @brief Send a GIDPT CT request.
@@ -1839,7 +1831,6 @@ ocs_ns_send_gidpt(ocs_node_t *node, uint32_t timeout_s
 	if (els == NULL) {
 		ocs_log_err(ocs, "IO alloc failed\n");
 	} else {
-
 		els->iparam.fc_ct.r_ctl = FC_RCTL_ELS;
 		els->iparam.fc_ct.type = FC_TYPE_GS;
 		els->iparam.fc_ct.df_ctl = 0;
@@ -2102,7 +2093,6 @@ ocs_els_abort_io(ocs_io_t *els, int send_abts)
 	return abort_io;
 }
 
-
 /*
  * ELS IO State Machine
  */
@@ -2126,7 +2116,6 @@ ocs_els_abort_io(ocs_io_t *els, int send_abts)
 				__func__, ocs_sm_event_name(evt)); \
 	} while (0)
 
-
 /**
  * @brief Cleanup an ELS IO
  *
@@ -2160,7 +2149,6 @@ ocs_els_io_cleanup(ocs_io_t *els, ocs_sm_event_t node_
 	els->els_req_free = 1;
 }
 
-
 /**
  * @brief Common event handler for the ELS IO state machine.
  *
@@ -2650,7 +2638,6 @@ ocs_ddump_els(ocs_textbuf_t *textbuf, ocs_io_t *els)
 	ocs_ddump_endsection(textbuf, "els", -1);
 }
 
-
 /**
  * @brief return TRUE if given ELS list is empty (while taking proper locks)
  *
@@ -2743,7 +2730,6 @@ ocs_send_ct_rsp(ocs_io_t *io, uint32_t ox_id, fcct_iu_
 	}
 	return 0;
 }
-
 
 /**
  * @brief Handle delay retry timeout

Modified: head/sys/dev/ocs_fc/ocs_fabric.c
==============================================================================
--- head/sys/dev/ocs_fc/ocs_fabric.c	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_fabric.c	Tue Sep  1 22:02:12 2020	(r365186)
@@ -166,7 +166,6 @@ __ocs_fabric_flogi_wait_rsp(ocs_sm_ctx_t *ctx, ocs_sm_
 
 	switch(evt) {
 	case OCS_EVT_SRRS_ELS_REQ_OK: {
-
 		if (node_check_els_req(ctx, evt, arg, FC_ELS_CMD_FLOGI, __ocs_fabric_common, __func__)) {
 			return NULL;
 		}
@@ -317,7 +316,6 @@ __ocs_fabric_fdisc_wait_rsp(ocs_sm_ctx_t *ctx, ocs_sm_
 		ocs_sport_attach(node->sport, cbdata->ext_status);
 		ocs_node_transition(node, __ocs_fabric_wait_domain_attach, NULL);
 		break;
-
 	}
 
 	case OCS_EVT_SRRS_ELS_REQ_RJT:
@@ -791,7 +789,6 @@ __ocs_ns_gidpt_wait_rsp(ocs_sm_ctx_t *ctx, ocs_sm_even
 	return NULL;
 }
 
-
 /**
  * @ingroup ns_sm
  * @brief Name services node state machine: Idle state.
@@ -1513,7 +1510,6 @@ __ocs_p2p_wait_flogi_acc_cmpl(ocs_sm_ctx_t *ctx, ocs_s
 
 	return NULL;
 }
-
 
 /**
  * @ingroup p2p_sm

Modified: head/sys/dev/ocs_fc/ocs_fabric.h
==============================================================================
--- head/sys/dev/ocs_fc/ocs_fabric.h	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_fabric.h	Tue Sep  1 22:02:12 2020	(r365186)
@@ -36,7 +36,6 @@
  * Declarations for the interface exported by ocs_fabric
  */
 
-
 #if !defined(__OCS_FABRIC_H__)
 #define __OCS_FABRIC_H__
 extern void *__ocs_fabric_init(ocs_sm_ctx_t *ctx, ocs_sm_event_t evt, void *arg);

Modified: head/sys/dev/ocs_fc/ocs_fcp.h
==============================================================================
--- head/sys/dev/ocs_fc/ocs_fcp.h	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_fcp.h	Tue Sep  1 22:02:12 2020	(r365186)
@@ -95,7 +95,6 @@
 #define FC_GS_NAMESERVER_RSNN_NN	0x0239
 #define FC_GS_NAMESERVER_RSPN_ID	0x0218
 
-
 #define FC_GS_REVISION		0x03
 
 #define FC_GS_IO_PARAMS		{ .fc_ct.r_ctl = 0x02, \
@@ -115,7 +114,6 @@ typedef struct fc_vft_header_s {
 			hopct:8;
 } fc_vft_header_t;
 
-
 #if BYTE_ORDER == LITTLE_ENDIAN
 static inline uint32_t fc_be24toh(uint32_t x) { return (ocs_be32toh(x) >> 8); }
 #else
@@ -147,7 +145,6 @@ typedef struct fc_header_s {
 	uint32_t	parameter;
 } fc_header_t;
 
-
 /**
  * @brief FC header in little-endian order
  */
@@ -321,7 +318,6 @@ typedef struct fc_acc_payload_s {
 			resv1:24;
 } fc_acc_payload_t;
 
-
 typedef struct fc_ls_rjt_payload_s {
 	uint32_t	command_code:8,
 			resv1:24;
@@ -742,6 +738,5 @@ typedef struct fcp_xfer_rdy_iu_s {
 } fcp_xfer_rdy_iu_t;
 
 #define MAX_ACC_REJECT_PAYLOAD (sizeof(fc_ls_rjt_payload_t) > sizeof(fc_acc_payload_t) ? sizeof(fc_ls_rjt_payload_t) : sizeof(fc_acc_payload_t))
-
 
 #endif /* !_OCS_FCP_H */

Modified: head/sys/dev/ocs_fc/ocs_hw.c
==============================================================================
--- head/sys/dev/ocs_fc/ocs_hw.c	Tue Sep  1 22:01:53 2020	(r365185)
+++ head/sys/dev/ocs_fc/ocs_hw.c	Tue Sep  1 22:02:12 2020	(r365186)
@@ -126,7 +126,6 @@ static ocs_hw_rtn_e ocs_hw_config_sli_port_health_chec
 static int32_t ocs_hw_domain_add(ocs_hw_t *, ocs_domain_t *);
 static int32_t ocs_hw_domain_del(ocs_hw_t *, ocs_domain_t *);
 
-
 /* Port state machine */
 static void *__ocs_hw_port_alloc_init(ocs_sm_ctx_t *, ocs_sm_event_t, void *);
 static void *__ocs_hw_port_alloc_read_sparm64(ocs_sm_ctx_t *, ocs_sm_event_t, void *);
@@ -372,7 +371,6 @@ ocs_hw_setup(ocs_hw_t *hw, ocs_os_handle_t os, sli4_po
 	hw->config.auto_xfer_rdy_app_tag_valid =  OCS_HW_AUTO_XFER_RDY_APP_TAG_VALID_DEFAULT;
 	hw->config.auto_xfer_rdy_app_tag_value = OCS_HW_AUTO_XFER_RDY_APP_TAG_VALUE_DEFAULT;
 
-
 	if (sli_setup(&hw->sli, hw->os, port_type)) {
 		ocs_log_err(hw->os, "SLI setup failed\n");
 		return OCS_HW_RTN_ERROR;
@@ -482,7 +480,7 @@ ocs_hw_setup(ocs_hw_t *hw, ocs_os_handle_t os, sli4_po
 				OCS_HW_MAX_NUM_EQ);
 		return OCS_HW_RTN_ERROR;
 	}
-	
+
 	if (hw->config.n_cq > OCS_HW_MAX_NUM_CQ) {
 		ocs_log_crit(hw->os, "Max supported CQs = %d\n",
 				OCS_HW_MAX_NUM_CQ);
@@ -610,7 +608,7 @@ ocs_hw_init(ocs_hw_t *hw)
 	if (hw->config.n_rq == 1) {
 		hw->sli.config.features.flag.mrqp = FALSE;
 	}
-	
+
 	if (sli_init(&hw->sli)) {
 		ocs_log_err(hw->os, "SLI failed to initialize\n");
 		return OCS_HW_RTN_ERROR;
@@ -693,7 +691,7 @@ ocs_hw_init(ocs_hw_t *hw)
 			    hw->config.n_mq, q_count);
 		return OCS_HW_RTN_ERROR;
 	}
-	
+
 	q_count = MIN(sli_get_max_queue(&hw->sli, SLI_QTYPE_RQ),
 					OCS_HW_MAX_NUM_RQ);
 	if (hw->config.n_rq > q_count) {
@@ -723,7 +721,6 @@ ocs_hw_init(ocs_hw_t *hw)
 	ocs_log_debug(hw->os, "Max WQs %d, hash size = %d\n",
 			OCS_HW_MAX_NUM_WQ, OCS_HW_Q_HASH_SIZE);
 
-
 	rc = ocs_hw_init_queues(hw, hw->qtop);
 	if (rc != OCS_HW_RTN_SUCCESS) {
 		return rc;
@@ -816,7 +813,6 @@ ocs_hw_init(ocs_hw_t *hw)
 
 	/* Register a FCFI to allow unsolicited frames to be routed to the driver */
 	if (sli_get_medium(&hw->sli) == SLI_LINK_MEDIUM_FC) {
-
 		if (hw->hw_mrq_count) {
 			ocs_log_debug(hw->os, "using REG_FCFI MRQ\n");
 
@@ -874,7 +870,6 @@ ocs_hw_init(ocs_hw_t *hw)
 			}
 			hw->fcf_indicator = ((sli4_cmd_reg_fcfi_t *)buf)->fcfi;
 		}
-
 	}
 
 	/*
@@ -1180,7 +1175,6 @@ ocs_hw_teardown(ocs_hw_t *hw)
 	}
 
 	if (hw->state != OCS_HW_STATE_QUEUES_ALLOCATED) {
-
 		hw->state = OCS_HW_STATE_TEARDOWN_IN_PROGRESS;
 
 		ocs_hw_flush(hw);
@@ -1250,12 +1244,10 @@ ocs_hw_teardown(ocs_hw_t *hw)
 	ocs_lock_free(&hw->io_lock);
 	ocs_lock_free(&hw->io_abort_lock);
 
-
 	for (i = 0; i < hw->wq_count; i++) {
 		sli_queue_free(&hw->sli, &hw->wq[i], destroy_queues, free_memory);
 	}
 
-
 	for (i = 0; i < hw->rq_count; i++) {
 		sli_queue_free(&hw->sli, &hw->rq[i], destroy_queues, free_memory);
 	}
@@ -1443,7 +1435,6 @@ ocs_hw_reset(ocs_hw_t *hw, ocs_hw_reset_e reset)
 		/* Teardown the HW queue topology */
 		hw_queue_teardown(hw);
 	} else {
-
 		/* Free rq buffers */
 		ocs_hw_rx_free(hw);
 	}
@@ -1474,7 +1465,6 @@ ocs_hw_get_fw_timed_out(ocs_hw_t *hw)
 		sli_reg_read(&hw->sli, SLI4_REG_SLIPORT_ERROR2) == 0x10);
 }
 
-
 ocs_hw_rtn_e
 ocs_hw_get(ocs_hw_t *hw, ocs_hw_property_e prop, uint32_t *value)
 {
@@ -1803,8 +1793,6 @@ ocs_hw_get_ptr(ocs_hw_t *hw, ocs_hw_property_e prop)
 	return rc;
 }
 
-
-
 ocs_hw_rtn_e
 ocs_hw_set(ocs_hw_t *hw, ocs_hw_property_e prop, uint32_t value)
 {
@@ -2027,7 +2015,6 @@ ocs_hw_set(ocs_hw_t *hw, ocs_hw_property_e prop, uint3
 	return rc;
 }
 
-
 ocs_hw_rtn_e
 ocs_hw_set_ptr(ocs_hw_t *hw, ocs_hw_property_e prop, void *value)
 {
@@ -2218,7 +2205,6 @@ ocs_hw_eq_process(ocs_hw_t *hw, hw_eq_t *eq, uint32_t 
 			}
 		}
 
-
 		if (eq->queue->n_posted > (eq->queue->posted_limit)) {
 			sli_queue_arm(&hw->sli, eq->queue, FALSE);
 		}
@@ -2320,7 +2306,6 @@ ocs_hw_command(ocs_hw_t *hw, uint8_t *cmd, uint32_t op
 	}
 
 	if (OCS_CMD_POLL == opts) {
-
 		ocs_lock(&hw->cmd_lock);
 		if (hw->mq->length && !sli_queue_is_empty(&hw->sli, hw->mq)) {
 			/*
@@ -2682,7 +2667,6 @@ ocs_hw_port_control(ocs_hw_t *hw, ocs_hw_port_e ctrl, 
 			return OCS_HW_RTN_NO_MEMORY;
 		}
 
-
 		if (sli_cmd_init_link(&hw->sli, init_link, SLI4_BMBX_SIZE, speed, reset_alpa)) {
 			rc = ocs_hw_command(hw, init_link, OCS_CMD_NOWAIT,
 						ocs_hw_cb_port_control, NULL);
@@ -2725,7 +2709,6 @@ ocs_hw_port_control(ocs_hw_t *hw, ocs_hw_port_e ctrl, 
 	return rc;
 }
 
-
 /**
  * @ingroup port
  * @brief Free port resources.
@@ -3107,7 +3090,6 @@ ocs_hw_node_free_resources(ocs_hw_t *hw, ocs_remote_no
 	return rc;
 }
 
-
 /**
  * @ingroup node
  * @brief Free a remote node object.
@@ -4174,7 +4156,6 @@ ocs_hw_io_send(ocs_hw_t *hw, ocs_hw_io_type_e type, oc
 		 * data phase, it is marked for quarantine.
 		 */
 		if (hw->workaround.use_dif_sec_xri && (iparam->fcp_tgt.dif_oper != OCS_HW_DIF_OPER_DISABLED)) {
-
 			/*
 			 * If we have allocated a chained SGL for skyhawk, then
 			 * we can re-use this for the sec_hio.
@@ -5030,7 +5011,6 @@ ocs_hw_io_get_xid(ocs_hw_t *hw, ocs_hw_io_t *io)
 	return io->indicator;
 }
 
-
 typedef struct ocs_hw_fw_write_cb_arg {
 	ocs_hw_fw_cb_t cb;
 	void *arg;
@@ -5604,7 +5584,6 @@ ocs_hw_get_host_stats(ocs_hw_t *hw, uint8_t cc, ocs_hw
 	return rc;
 }
 
-
 /**
  * @brief Called when the READ_STATUS command completes.
  *
@@ -5649,7 +5628,6 @@ ocs_hw_cb_host_stat(ocs_hw_t *hw, int32_t status, uint
 	counts[OCS_HW_HOST_STAT_DROP_FRM_DUE_TO_NO_XRI_COUNT].counter = mbox_rsp->dropped_frames_due_to_no_xri_count;
 	counts[OCS_HW_HOST_STAT_EMPTY_XRI_POOL_COUNT].counter = mbox_rsp->empty_xri_pool_count;
 
-
 	if (cb_arg) {
 		if (cb_arg->cb) {
 			if ((status == 0) && mbox_rsp->hdr.status) {
@@ -6100,7 +6078,6 @@ ocs_hw_get_linkcfg_lancer(ocs_hw_t *hw, uint32_t opts,
 	return rc;
 }
 
-

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***


More information about the svn-src-all mailing list